20.06.2014, 19:34
Hello guys now i will show you how to create a /open /close gates ..
First step you need to do is create your command ..
Now we need to create the gate (Use Mapping Editor )
When we create the gates now we need to define them..
Now we need to finish the command
tutorialgate - the gate
cordinates - where to move
speed - move speed on the gate ..
Now for the /close we do all the same but we change the cordinates ..
Example command :
First step you need to do is create your command ..
pawn Код:
if(!strcmp(cmdtext, "/open", true, 3))
{
When we create the gates now we need to define them..
pawn Код:
new tutorialgate; (put your gate name)
Then we add the gate
tutorialgate = CreateObject(cordinates and the gate .. )
pawn Код:
MoveObject(tutorialgate, cordinates, speed);
cordinates - where to move
speed - move speed on the gate ..
Now for the /close we do all the same but we change the cordinates ..
Example command :
pawn Код:
if(strcmp(cmd,"/open",true)==0)
{
MoveObject(tutorialgate, 250.59617614746, 63.366600036621, 997.8391113281, 9.000);
SendClientMessage(playerid, COLOR_YELLOW, "You have opened the gate .");
return 1;
}