Gate help
#1

Can someone help me with this gate.I have made a gate and that and scripted the CMD ,the gate works but I can open the gate from the other side of the map can someone help me please so I can only open it when I'm close to it , also I want to add the gate so only the LSPD can open it, and the lspd faction is ID 1.
Reply
#2

show the command
Reply
#3

This is the CMD for the gate

public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/close", cmdtext, true, 10) == 0)
{
MoveObject(base,2720.10571289,-2409.60424805,12.46093750, 3.0 );
SendClientMessage(playerid,messagecolor,"The Gate is now CLOSED!");

return 1;
}
if (strcmp("/open", cmdtext, true, 10) == 0)
{
MoveObject(base,2720.0986328125,-2401.1477050781,12.4609375, 3.0 );
SendClientMessage(playerid,messagecolor,"The Gate is now OPEN!");

return 1;
}
Reply
#4

Quote:
Originally Posted by Bob_Raw
Посмотреть сообщение
This is the CMD for the gate

public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/close", cmdtext, true, 10) == 0)
{
MoveObject(base,2720.10571289,-2409.60424805,12.46093750, 3.0 );
SendClientMessage(playerid,messagecolor,"The Gate is now CLOSED!");

return 1;
}
if (strcmp("/open", cmdtext, true, 10) == 0)
{
MoveObject(base,2720.0986328125,-2401.1477050781,12.4609375, 3.0 );
SendClientMessage(playerid,messagecolor,"The Gate is now OPEN!");

return 1;
}
show me how you defined the "base"...
like:
base = CreateObject(....)
i just need the cords...
Reply
#5

Did you try the "Open Says Me" command?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)