Hello All,
I am modifying an existing mod and one of the things I wish to add is rail jumping and also the ability to jump
with the lightning gun. Does anyone know how this is accomplished in mods like insta? Do I need to add something
in g_missiles for the rail gun?
Any help with this would be much appreciated.
Rail Jumping with Quake III
Re: Rail Jumping with Quake III
G_Damage in G_Combat.c might be a good starting point (its where the knockback is performed)
Re: Rail Jumping with Quake III
Hi Kaz,
I noticed the knockback var in these method and also g_RadiusDamage has the following
But these two methods are only called for weapons that fire missiles like the BFG and RL. I can't work out
how to incorporate a call to these methods from the LG or RG weapon_fire methods. I've had the game crash
on me with some previous attempts
I was hoping to find the source for instaunlagged online somewhere but no look as yet. I would imagine the change
is quite simple but I am not great with C and I am only learning the code base for now.
Thanks for the reply.
I noticed the knockback var in these method and also g_RadiusDamage has the following
Code: Select all
// push the center of mass higher than the origin so players
// get knocked into the air more
dir[2] += 24;
G_Damage (ent, NULL, attacker, dir, origin, (int)points, DAMAGE_RADIUS, mod);
how to incorporate a call to these methods from the LG or RG weapon_fire methods. I've had the game crash
on me with some previous attempts
I was hoping to find the source for instaunlagged online somewhere but no look as yet. I would imagine the change
is quite simple but I am not great with C and I am only learning the code base for now.
Thanks for the reply.
-
- Posts: 4022
- Joined: Sat Mar 12, 2005 6:24 pm
Re: Rail Jumping with Quake III
weapon_railgun_fire() in game/g_weapon.c is the function you want. If the trace stopped within, say, 64 units, hitting a surface, apply knockback.