17.03.2010, 15:46
I found a fix for this.
Since I use pGun1-12 as my server sided weapons, I made it so when someone lays a C4, their pGun12 gets set to 40 (which is detonator). Instead of using
I used
And it worked!
I advise you make some sort of "HasDetonator' variable and put in HasDetonator[playerid] = 1; when you give them one so it could work, then use:
EDIT: But you could still punch to detonate the bomb if your HasBomb is set to 1. No big deal to me
Since I use pGun1-12 as my server sided weapons, I made it so when someone lays a C4, their pGun12 gets set to 40 (which is detonator). Instead of using
Код:
if(GetPlayerWeapon(playerid) == 40)
{
//explosion shit here
}
Код:
if(PlayerInfo[playerid][pGun12]) //<--- which is only for detonators, no other guns use this slot
{
//explosion shit here
}
I advise you make some sort of "HasDetonator' variable and put in HasDetonator[playerid] = 1; when you give them one so it could work, then use:
Код:
if(HasDetonator[playerid])
{
//explosion shit here
}

