11.05.2010, 20:59
No topo tens que fazer:
Depois se estбs a fazer no gamemode tens que fazer isto que se segue no OnGameModeInit, caso seja num filterscript usas o OnFilterScriptInit:
E no OnPlayerPickUpPickup:
Tinhas te esquecido a abrir a cheveta '{' de cada cena. O return 1 aн й opcional, a callback nгo tem nenhum em especнfico, por isso salvo erro em cada 'if bla bla bla' nгo й preciso nenhum return.
pawn Код:
new pickup_A1;
new pickup_A2;
new pickup_A3;
pawn Код:
pickup_A1 = CreatePickup(1275, 1, 253.3719,78.0132,1003.6406);//Pickup Skin
pickup_A2 = CreatePickup(1275, 1, 254.7950,78.3707,1003.6406);//Pickup Skin
pickup_A3 = CreatePickup(1275, 1, 255.2836,76.5384,1003.6406);//Pickup Skin
pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
if (pickupid == pickup_A1)
{
SendClientMessage(playerid, Verde, "Skin de Cop 2");
SetPlayerSkin(playerid,281);
GivePlayerWeapon(playerid, 27, 9999);
GivePlayerWeapon(playerid, 29, 9999);
GivePlayerWeapon(playerid, 24, 9999);
GivePlayerWeapon(playerid, 31, 9999);
GivePlayerWeapon(playerid, 17, 9999);
GivePlayerWeapon(playerid, 34, 9999);
GivePlayerWeapon(playerid, 39, 9999);
}
if (pickupid == pickup_A2)
{
SendClientMessage(playerid, Verde, "Skin de Cop 3");
SetPlayerSkin(playerid,282);
GivePlayerWeapon(playerid, 27, 9999);
GivePlayerWeapon(playerid, 29, 9999);
GivePlayerWeapon(playerid, 24, 9999);
GivePlayerWeapon(playerid, 31, 9999);
GivePlayerWeapon(playerid, 17, 9999);
GivePlayerWeapon(playerid, 34, 9999);
GivePlayerWeapon(playerid, 39, 9999);
}
if (pickupid == pickup_A3)
{
SendClientMessage(playerid, Verde, "Skin de Cop 4");
SetPlayerSkin(playerid,284);
GivePlayerWeapon(playerid, 27, 9999);
GivePlayerWeapon(playerid, 29, 9999);
GivePlayerWeapon(playerid, 24, 9999);
GivePlayerWeapon(playerid, 31, 9999);
GivePlayerWeapon(playerid, 17, 9999);
GivePlayerWeapon(playerid, 34, 9999);
GivePlayerWeapon(playerid, 39, 9999);
}
return 1;
}