24.01.2010, 10:07
I know what you want i think, i don't need money for such a simple piece of code.
This uses the dcmd system, so just add this line to the top of your script: dcmd def
This uses the dcmd system, so just add this line to the top of your script: dcmd def
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
dcmd(takeoff, 7, cmdtext);
return 0;
}
dcmd_takeoff(playerid, params[])
{
switch(GetVehicleModel(GetPlayerVehicleID(playerid)))
{
case 592, 577, 511, 512, 593, 520, 553, 476, 519, 460, 513:
{
new msg[128], name[24];
GetPlayerName(playerid, name, sizeof (name));
format(msg,sizeof(msg), "%s taking off", name);
SendClientMessageToAll(0xEEEE00FF, msg);
}
default: SendClientMessage(playerid,0xEEEE00FF, "You are not in a plane, you cannot take off");
}
}

