22.09.2010, 20:11
pawn Код:
new mygate //at the top of the script
mygate = CreateDynamicObject(969, 2720.3772,-2409.7523,12.6,0, 0.0000, 90); //this on gamemode init this is the default position where you will need to close
if(!strcmp(cmdtext, "/opendoor", true))
{
MoveDynamicObject(mygate, 239.774,111.511,1000.61, 1.7500); // you need to get the cordinates of the opened position to work
SendClientMessage(playerid, COLOR_BLUE,"Gate opened!!");
return 1;
}
if(!strcmp(cmdtext, "/opendoor", true))
{
MoveDynamicObject(mygate, 239.774,111.511,1000.61, 1.7500); // you need to get the closed cordinates
SendClientMessage(playerid, COLOR_BLUE,"Gate closed");
return 1;
}