[HELP] Gate - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [HELP] Gate (
/showthread.php?tid=215422)
[HELP] Gate -
NotoriousMOB - 23.01.2011
pawn Код:
if (PlayerToPoint(15, playerid,1141.29589844,-1210.58032227,19.53727722))
{
MoveObject(Utgate1,1141.29589844,-1210.58032227,19.53727722, 1.5);
SetTimer("GateClose14", 7000, 0);
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "* %s takes his/her remote and opens Gangs gate.", sendername);
ProxDetector(30.0, playerid, string,
COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
if (PlayerToPoint(15, playerid,1141.45190430,-1202.71337891,19.56865692))
{
MoveObject(Utgate2,1141.45190430,-1202.71337891,19.56865692, 1.5);
SetTimer("GateClose15", 7000, 0);
Trying to make it move like this :
1) Closed
2) Opend
You know like it opens each way
can't make it work im changing this:
pawn Код:
MoveObject(Utgate1,1141.29589844,-1210.58032227,19.53727722, 1.5);
// Here i been trying to change in the number "1210" in the coord to make it go the right way
pawn Код:
MoveObject(Utgate2,1141.45190430,-1202.71337891,19.56865692, 1.5);
// Here i been trying to change in the number "1202" in the coord to make it go the right way
Tho i tried so much now i need some help to give me the right coord number for it so it will move perfectly each way hope someone can understand me Thanks.
SOLVED!!!!
Re: [HELP] Gate -
Kwarde - 23.01.2011
Just make with an object editor 2 gates. One opened and 1 closed.
When adding to your script, only use CreateObject for the closed gate. From the opened gate, you need the X,Y,Z for the MoveObject
Did you want that?