_files/image002.jpg)
Temp Invincibility During Respawn
|
posted 09-07-98 1:38 PM CT (US) ============================================================= Anyway, several
people have asked how to add some invincibility during a respawn. I wanted to
do that myself to my code so I looked into it and found that all you have o
do is add 1 simple stinking little line to the respawn() function and you're
done! So, here it is: ============ Anyway, inside of
the following function: void respawn(edict_t
*self) { // Do this to add 3
seconds worth of invincibility. ============= The gaming engine
will keep the player invincible to any kind of damage until the level's frame
numbering system (like level.time) catches up with the player's
invinciblility framenumber.. Okay, now that's
EASY! And, when you're
done respawning, go kill all those bastards!! regards, |
|
|
posted 09-07-98 5:50 PM CT (US) Still in
"p_client.c" go to the "void ClientBeginDeathmatch (edict_t
*ent)" and at the end of this function put this line in, just after
"ClientEndServerFrame(ent);",
"ent->client->invincible_framenum = level.framenum + 30;".
That will make u and the other players invincible at spawn. The one above
covers respawn. cr0tan |