Drug Automats and increasing fire rate?
#5

It's possible, but it will also increase running speed. The effect lasts for ~20 seconds, unless you add another pickup on him.
You have to put a pickup with a drug modelid.
pawn Код:
new DrugPickup[MAX_PLAYERS];
stock IncraseFireRate(playerid)
{
    new Float:Coo[3];
    GetPlayerPos(playerid,Coo[0],Coo[1],Coo[2]);
    DrugPickup[playerid] = CreatePickup(1241 ,2,Coo[0],Coo[1],Coo[2]+1.0);
    SetTimerEx("RemoveDrugPickup",2000,false,"i",playerid);
}
forward RemoveDrugPickup(playerid);
public RemoveDrugPickup(playerid)
{
    DestroyPickup(DrugPickup[playerid]);
    DrugPickup[playerid]=-1;
    return 1;
}
public OnPlayerPickUpPickup(playerid, pickupid)
{
    if(pickupid==DrugPickup[playerid])
    {
        DestroyPickup(DrugPickup[playerid]);
        DrugPickup[playerid]=-1;
        return 1;
    }
}
This is what I'm currently using.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)