public OnPlayerCommandText(playerid, cmdtext[]) CMD:cv (playerid, params[]) { new modelo, carro, cor1, cor2, Float:X, Float:Y, Float:Z, Float:Angle; if(sscanf(params, "ddd", modelo, cor1, cor2)) return SendClientMessage(playerid, -1, "Digite: /cv [ID] [cor1] [cor2]"); if(IsPlayerConnected(playerid)) { if(modelo >= 400 && modelo <= 611) { if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, -1, "Saia deste veнculo para criar outro."); GetPlayerPos(playerid, X, Y, Z); GetPlayerFacingAngle(playerid, Angle); carro = AddStaticVehicleEx(modelo, X, Y, Z, Angle, cor1, cor2, 5000); LinkVehicleToInterior(carro, GetPlayerInterior(playerid)); SetVehicleVirtualWorld(carro, GetPlayerVirtualWorld(playerid)); SendClientMessage(playerid, -1, "Veнculo criado com sucesso!"); PutPlayerInVehicle(playerid,carro,0); } else SendClientMessage(playerid, -1, "Valor invбlido, tente novamente! | ID's = 400-611"); } return 1; }
public OnGameModeInit() { SetGameModeText("hehe"); //carros AddStaticVehicleEx(411,1764.5000000,-1861.3000000,13.4000000,90.0000000,89,110,15); //Infernus AddStaticVehicleEx(411,1756.0000000,-1858.5996000,13.2000000,90.0000000,201,48,15); //Infernus //Objetos CreateObject(1218,1759.4000000,-1860.3000000,13.1000000,0.0000000,0.0000000,0.0000000); //object(barrel1) (1) return 1; }
public OnPlayerCommandText(playerid, cmdtext[]) CMD:cv (playerid, params[]) |