26.12.2010, 15:38
hi,
i run a minigame server and ive got a problem thats killing me
Sometime theres a moneyrush mission and after a player has started the moneyrush (enter a certain checkpoint)
a moneybag pickup will appear somewhere.
I also create some info sign pickups u cant pickup but i also wrote them under //OnPlayerPickUpPickUp because as soon as a player touches it a dialog appearas where u can buy weapons.
But my problem is, that the 2 different actions the 2 pickups shall do mixes up!!
If i enter the info sign pickup, the weapons buy dialog shows up but i also get the 2000$ from the moneyrush pickup.
But i dont know why cause this are 2 different pickups!!?
Pls help me, this is very important and i need to fix this fast!
pls help me
i run a minigame server and ive got a problem thats killing me
Sometime theres a moneyrush mission and after a player has started the moneyrush (enter a certain checkpoint)
a moneybag pickup will appear somewhere.
I also create some info sign pickups u cant pickup but i also wrote them under //OnPlayerPickUpPickUp because as soon as a player touches it a dialog appearas where u can buy weapons.
But my problem is, that the 2 different actions the 2 pickups shall do mixes up!!
If i enter the info sign pickup, the weapons buy dialog shows up but i also get the 2000$ from the moneyrush pickup.
But i dont know why cause this are 2 different pickups!!?
Pls help me, this is very important and i need to fix this fast!
pawn Код:
//OnGameModeInit
CreateDynamicPickup(1239,1,-2280.8867,-1659.8271,483.0706);//i use incognitos streamer btw.
//OnPlayerEnterCheckpoint
moneybag = CreatePickup(1550,2,x,y,z,0);
//OnPlayerPickUpPickUp
//info buy pickup
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerInRangeOfPoint(i,2,-617.0662,1970.6304,2.6061))
{
ShowPlayerDialog(i, Weaponsdialogue, DIALOG_STYLE_LIST, "Weapon", "Body Armour - 500$\nKatana - 5500$\nChainsaw - 2500$\n9mm Pistol - 2000$\nDesert Eagle - 4000$\nShotgun - 4500$\nCombat Shotgun - 8000$\nShawn off Shotgun - 12000$\nTec9 - 15000$\nMicro SMG - 15000$\nMP5 - 15000$\nAK47 - 15500$\nM4 - 15500$\nCountry Rifle - 16500$\nSniper Rifle - 20000$\nGrenade - 25000$\nMolotov Cocktail - 25000$\nRocket Launcher - 40000$\nMinigun - 40000$\nFlamethrower - 35000$", "Buy", "Cancel");
}
}
//moneybag pickup
if(pickupid == moneybag)
GivePlayerMoney(playerid,2000);
//and also a code that ends the currrent round and changes the map