26.02.2011, 23:02
I'm trying to script in RC-XD's like on Black op's they work fine but I'm wanting to make it to where players have to buy them this is what i have so far
new rcxd;
OnPlayerConnect
then I added it to the shop menu when the player selects it it will
and for the command
but for some reason players without buying the rcxds can use them why is this?
new rcxd;
OnPlayerConnect
Код:
rcxd=0;
Код:
rcxd=1;
Код:
if (strcmp("/rcxd", cmdtext, true, 10) == 0) { if(rcxd=1) { new LVehicleID; new Float:X,Float:Y,Float:Z; GetPlayerPos(playerid, X,Y,Z); LVehicleID = CreateVehicle(441, X+3,Y,Z, 0, -1, 50, -1); PutPlayerInVehicle(playerid,LVehicleID,0); SetVehicleVirtualWorld(LVehicleID, GetPlayerVirtualWorld(playerid)); LinkVehicleToInterior(LVehicleID, GetPlayerInterior(playerid)); RCXD2 = 1; new playername[MAX_PLAYER_NAME]; new string[128]; GetPlayerName(playerid,playername,sizeof(playername)); format(string,sizeof(string),"~r~%s ~y~>>> RC-XD in bound!", playername); GameTextForAll(string,2500,3); SendClientMessage(playerid,0xFFFF00AA,"Use LMB[FIRE] Key to explode the RC-XD!!!"); return 1; } else { SendClientMessage(playerid, COLOR_YELLOW, "You dont have a RC-XD!"); return 1; }