SA-MP Forums Archive
Problem with function - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Problem with function (/showthread.php?tid=608764)



Problem with function - Mijata - 04.06.2016

fixed


Re: Problem with function - CSLangdale - 04.06.2016

Maybe because it's setting the score and giving the money in the explosion timer so it's counting it as the player that gets hit by the explosion gets the score and money?

Not sure how you could fix it though as if it is that maybe you could create a variable for bomb creator or something so if bomb kills anyone it gives score and money to bomb creator...


Re: Problem with function - Mijata - 04.06.2016

Can u help me to create this


Re: Problem with function - blanic - 04.06.2016

https://sampforum.blast.hk/showthread.php?tid=608744


Re: Problem with function - Mijata - 04.06.2016

////


Re: Problem with function - Dayrion - 04.06.2016

Did you try this :
PHP код:
CMD:bombplant(playeridparams[])
{
    if(
IsPlayerInDynamicCP(playeridPlantbombCP) && (gTeam[playerid] == T1 && (BombPlanted == 0)))
    {
        
ApplyAnimation(playerid"BOMBER""BOM_Plant"4.000000); // Place Bomb
        
Bomb CreateDynamicObject(1654211.786711824.107066.43200,   -87.000000.000000.00000);
        
BombExplodeTimer SetTimerEx("BombExplodes"110000false"i"playerid);
        
GameTextForAll("~r~Bomb Has Been Planted!"40003);
        
BombPlanted 1;
    }
    else if(
IsPlayerInDynamicCP(playeridPlantbombCP) && (gTeam[playerid] == T1 && (BombPlanted != 0))) return SendClientMessage(playeridCOLOR_RED"The bomb is already planted!");
    return 
1;




Re: Problem with function - Mijata - 04.06.2016

Thanks rep+


Re: Problem with function - Dayrion - 04.06.2016

No problem. Good luck for your project.