Copy-paste is possible. I really
don't recomment using this code listed below. It's your choice. It's not safe. And redundant though.
Code:
// Still quirky, needs fixing. Does work though. Need to perfect the gravity i think.
// absolutely needs to be tested fully.
public spinner_effect(id)
{
new target = id
// <<<<<<< SLOWHACK LOOOOL DON'T SEND CLIENT_CMD >>>>>>>>>
if(entity_get_int(target, EV_INT_flags) & FL_ONGROUND)
{
new Float:Velocity[3]
entity_get_vector(target, EV_VEC_velocity, Velocity)
Velocity[0] = random_float(200.0, 500.0)
Velocity[1] = random_float(200.0, 500.0)
Velocity[2] = random_float(200.0, 500.0)
entity_set_vector(target, EV_VEC_velocity, Velocity)
}
entity_set_float(target, EV_FL_friction, 0.1)
entity_set_float(target, EV_FL_gravity, 0.000001)
}
// Sometimes client_Prethink doesnt work, I dont fucking know why. Not my coding problem.
public client_PreThink(id)
{
if(spinon[id])
{
spinner_effect(id)
}
}
public reset_round(id)
{
if (spinon[id])
{
entity_set_float(id, EV_FL_friction, 0.1)
new parm[1]
parm[0] = id
set_task(1.0,"spinner_round",id,parm)
}
return PLUGIN_CONTINUE
}
public spinner_round(parm[])
{
new id = parm[0]
spinner_effect(id)
}
__________________