PHP Code:
#include <amxmodx>
#include <fun>
#include <fakemeta_util>
new bool:BoughtSpeed[33]; //make this bool true when they buy the speed
new speeds_time[33];
public plugin_init()
{
register_event("CurWeapon", "event_curweapon", "be", "1=1")
register_clcmd("buy", "buy_speed")
}
public event_curweapon(id)
{
if( !is_user_alive(id) )
{
return PLUGIN_HANDLED;
}
if( BoughtSpeed[id] )
{
set_user_maxspeed( id, speedyouwant )
}
return PLUGIN_HANDLED;
}
public buy_speed(id)
{
client_print(id,print_chat,"Buy speeds")
speeds_time[id] = 20;
set_task(1.0, "speeds_buy", 56465+id, "", 0, "b");
}
public speeds_buy(taskid);
{
new id = taskid-56465;
if(speed_time[id] > 0)
{
set_hudmessage(0, 170, 255, 0.44, 0.75, 0, 6.0, 1.0);
ShowSyncHudMsg(id,gSyncMessage,"Speeds %d", speed_time[id]);
speed_time[id]--;
}
else
{
????
remove_task(taskid);
}
}
Errors ;/
Can someone fix this?