PMove: Pressing jump will now make you jump off the ladder, like in HL and
some other games.
This commit is contained in:
parent
a62aee6e15
commit
59ee0bd359
2 changed files with 8 additions and 4 deletions
|
@ -25,11 +25,7 @@ This entity was introduced in Half-Life (1998).
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class
|
class
|
||||||
#ifdef CLIENT
|
|
||||||
func_ladder:CBaseEntity
|
|
||||||
#else
|
|
||||||
func_ladder:CBaseTrigger
|
func_ladder:CBaseTrigger
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
void(void) func_ladder;
|
void(void) func_ladder;
|
||||||
|
|
||||||
|
|
|
@ -208,6 +208,14 @@ PMoveCustom_AccelLadder(float move_time, float premove, vector wish_dir, float w
|
||||||
} else {
|
} else {
|
||||||
self.velocity = [0,0,0];
|
self.velocity = [0,0,0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (input_buttons & INPUT_BUTTON2) {
|
||||||
|
makevectors([0, input_angles[1], 0]);
|
||||||
|
self.velocity = v_forward * -250;
|
||||||
|
self.velocity += v_up * 100;
|
||||||
|
self.flags &= ~FL_ONGROUND;
|
||||||
|
self.flags &= ~FL_JUMPRELEASED;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
Loading…
Reference in a new issue