Improved airdeath scenes

Discuss programming in the QuakeC language.
Post Reply
Cobalt
Posts: 445
Joined: Wed Jun 10, 2009 2:58 am
Location: New England, USA
Contact:

Improved airdeath scenes

Post by Cobalt »

Electro and I want to work on some improvements to the bodyque routine that involve getting some more information about the physics of the player , and pass them onto the body image so that you get perhaps an avelocity poroprtional to the effect of a rocket explosion that kills a player in mid air. Anyone interested in collaborating?

If we start with your legacy type rocket explosion, there is I think a velocity passed over to the image so the shockwave physics effect is visible, but if you notice carefully, the deathframes for that kind of condition I think are picked from the same qc that creates any death scene. If I remember, the QC picks a random death scene no matter what?

So in this modification, we could perhaps do a traceline check if the player is (!droptofloor) at the time of the death, and depending on our traceline length, which determines how high up we are, we could assign an avelocity to the image that would correspond with gravitys acceleration effect and such....which I believe would also effect avelocity of the image.
Pretty much I think we need to check X,Y and Z velocities for whichevdeer is the greatest, and have a tendency to roll the avelocity in that direction on the model. Also picking a death frame that corresponds to that same angle, and reframing might come out neat too.

Electro said he is blanking out the player model in his mod when it dies, and doing its own seperate death with another eitity, which is a little different than how legacy qc does it, but
I like the idea of detecting this extra kind of death condition, switching ovder the players view to that of the new image, and not allowing him to respawn till the effect is finished.

EDIT: Just for my own notes, add in changes to the image's model angles (along with some pain sounds) for each time a touch is called and it has a velocity and is not on ground. Once velocity is zero, switch to a normal final death frame and angle.
Cobalt
Posts: 445
Joined: Wed Jun 10, 2009 2:58 am
Location: New England, USA
Contact:

Re: Improved airdeath scenes

Post by Cobalt »

Ok, guess not too many are interested in this effect. I learned that the playerdie() function determines a random deathscene like this:

Code: Select all

i = (1 + floor ((random () * 6)));
	if ((i == 1))
	{
		player_diea1 ();
	}
...and so fourth for all 6 possible death scenes. There is also code above this that checks for if the players weapon is the ax of hook, and we do
a ax type deathscene.

The problem with this code is if the player dies in mid air , usually from a rocket hit - he will go through a death scene in mid air, and if I recall, his velocity seems to get nullified while the death scene is performing, then after it finishes, the code executes copytobodyque() and the image created seems to have a positive velocity_z applied to it, or perhaps the saved last velocity of the player (target)....then it will drop to ground.
I thought about trying GYRO physics, but it does not exactly handle this area if I recall....and I dont think the author is still active else I would ask to collaborate this with him in his new version. So meanwhile I believe the first thing to start with is this player_die code which I believe is what you call ' macros '. From what I understand, calling one results in the rest being executed sequentially, I guess one per frame of engine time? This is where It gets tricky for me because maybe an explosion in mid air by a rocket may be better illustrated by slowing down the deathscene perhaps by using .frametime? Other issue is that if the player bumps into a wall during the deathscene, it may get flagged by the engine as FL_ONGROUND, so we would need to be careful and I guess use droptofloor() to know if the player entity has just landed on the ground, and has no velocity, then I guess call the bodyque() finally. Any thoughts on this....?
ceriux
Posts: 2230
Joined: Sat Sep 06, 2008 3:30 pm
Location: Indiana, USA

Re: Improved airdeath scenes

Post by ceriux »

i think if a rocket kills a player in mid air , it would be easier to just throw out gibs in random directions.
Cobalt
Posts: 445
Joined: Wed Jun 10, 2009 2:58 am
Location: New England, USA
Contact:

Re: Improved airdeath scenes

Post by Cobalt »

Easy is always easier..... :D I like doing things that are hard and challenging.

Actually splash damage can kill without gibbing.....so that is really the main instance I am seeking to work on. Last night I tried
carrying over some vectors to store a new velocity and avelocity in the t_damage () area....then I checked for deathtype = "rocket" just above the area of code I posted above. Takes a while to test during a game, so not sure if its working yet, but I did notice the gibs seem to have different trajectories then before if the rocket gibs them. I figure first get this piece working, then mess with the macro stuff to see maybe if we can make this look good by calculating some roll depending on the frame being set and check for other stuff like hitting a wall during the macros.

Should we change this topic to be: "The quake guy deserves a better death" ? :o
ceriux wrote:i think if a rocket kills a player in mid air , it would be easier to just throw out gibs in random directions.
toneddu2000
Posts: 1395
Joined: Tue Feb 24, 2009 4:39 pm
Location: Italy

Re: Improved airdeath scenes

Post by toneddu2000 »

Should we change this topic to be: "The quake guy deserves a better death" ?
IMO quake guy deserves a better model, first of all! :)
Meadow Fun!! - my first commercial game, made with FTEQW game engine
gnounc
Posts: 428
Joined: Mon Apr 06, 2009 6:26 am

Re: Improved airdeath scenes

Post by gnounc »

Funny thing....Electro has a better model.
Combustion cell would be a great excuse to dust that badboy off : )
Put some proper skeletal animations on him? Yeah?
Cobalt
Posts: 445
Joined: Wed Jun 10, 2009 2:58 am
Location: New England, USA
Contact:

Re: Improved airdeath scenes

Post by Cobalt »

True. Im using the legacy / low res model for the time being. I saw Primevil has a new skin for QW, but its 24 bit...and when it comes to modeling and skinning I am a beginner. Tried to import that skin via Quark, and it lets it happen but the colors are corrupted. I guess I need blender or the other pay app, I forget the name of right now. Aside from a new model, new frames for swimming, croutching, kneeling or whatever. I would give it a go but without good sw to help in the design it could take a long time.
toneddu2000 wrote:
Should we change this topic to be: "The quake guy deserves a better death" ?
IMO quake guy deserves a better model, first of all! :)
ceriux
Posts: 2230
Joined: Sat Sep 06, 2008 3:30 pm
Location: Indiana, USA

Re: Improved airdeath scenes

Post by ceriux »

well, i mean in rl i would expect even splash damage from an explosive would heavily damage a person, so i mean for if the player was killed by a rocket in mid air, he should gib, else maybe fly flailing his arms and wiggling his legs and maybe turning in the direction the bullet was traveling bouncing across the ground.
i had an idea about a month or two ago about changing the players skin to a burnt looking crisp maybe if he was fried by the lightning gun, maybe make him emit some grey and orange particles.
r00k
Posts: 1111
Joined: Sat Nov 13, 2004 10:39 pm

Re: Improved airdeath scenes

Post by r00k »

Normally in the Quake any health value less then -40 will create the gibbed player. So, if you want him to gib easier just change that value to something like -20. This is what I had to do to ensure that players gibbed to death in CAx, because when they die the dead player's pov would follow the person who killed him. It looked kinda funny to see the corpse rotate like some kinda '80s break dancer ;) You could alternately check if the on ground flag is OFF then force it to the animation that is just the player doing the belly flop. Either way, sometimes it's funny to see them doing a "spread eagle" as the blast is tossing them around like a rag doll.
Post Reply