03.07.2014, 05:14
Preciso de ajudar de um tutorial de CMD porque os outros nгo sгo e dгo errado no GM
#include <a_samp>
#include <a_objects>
#include <core>
#include <float>
#include <dutils>
#include <dudb>
#include <udb>
#include <c_vehicleinfo>
#include <a_players>
#include <cpstream>
new PORTAO;
public OnGameModeInit()
{
PORTAO = CreateObject(980, *Codernadas AQUI!!!*);
return 1;
}
CMD:abrirportao(playerid, params)
{
MoveObject(PORTAO,-2137.48511, -80.79789, 37.15380, 3.0);
GameTextForPlayer(playerid, "~r~O Portao esta sendo aberto!", 5000, 3);
}
CMD:fecharportao(playerid, params)
{
MoveObject(PORTAO, -2126.98608, -81.15697, 37.44162, 3.0);
GameTextForPlayer(playerid, "~b~O PORTAO ESTA SENDO FECHADO!", 5000, 3);
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp("/abrirportao", cmdtext, true) == 0) {
MoveObject(PORTAO,-2137.48511, -80.79789, 37.15380, 3.0);
GameTextForPlayer(playerid,"~r~Abrindo Portгo", 50000, 3);
return 1;
}
if(strcmp("/fecharportao", cmdtext, true) == 0) {
MoveObject(PORTAO, -2126.98608, -81.15697, 37.44162, 9.0);
GameTextForPlayer(playerid,"~r~Fechando portao!", 5000, 3);
return 1;
}