Hello,
I've finished a CS mod called NBAJam where people can play basketball. Players can dribble the ball by throwing it to the ground and jumping over it (ball hop).
The problem is that when I transfered the plugin from my local dedicated server to a public one I noticed that sometimes (maybe 1 in each 6 dribbles) the player isn't able to jump over the ball.
I've stolen the jump code from a bunnyhop plugin:
PHP Code:
if ( !(flags & FL_ONGROUND) )
return PLUGIN_CONTINUE
static iOwner; iOwner = pev( g_iBall, pev_iuser1 );
new Float:velocity[3]
entity_get_vector(id, EV_VEC_velocity, velocity)
velocity[2] += 250.0
entity_set_vector(id, EV_VEC_velocity, velocity)
entity_set_int(id, EV_INT_gaitsequence, 6) // Play the Jump Animation
I don't know if this is a lag problem but please help me to solve it. If you didn't understand what I wrote please PM me and I'll give you my server IP so you can test it yourself. Thanks.
__________________