Where shoukd i put this co ordinate??
#1

#include <a_samp>
new gate;
forward gateTimer(playerid);

public OnFilterScriptInit()
{
gate = CreateObject(976, 211.22889709473, -1447.3885498047, 12.159649848938, 0, 0, 230.97595214844);
SetTimer("gateTimer", 1000, 1);
}


public gateTimer(playerid)
{
if(IsPlayerInRangeOfPoint(playerid, 10, 211.22889709473, -1447.3885498047, 12.15964984893)
{
MoveObject(gate, 205.57905578613, -1454.2342529297, 12.159649848938, 5);
}else{
MoveObject(gate, 211.22889709473, -1447.3885498047, 12.159649848938, 5);
}
}





i just use aGate Ganerator software

help!!!!
Reply
#2

What coord? Everythings done for you
Reply
#3

From what I understand, you do not know where put?

Try:
In your script top:
pawn Код:
#include <a_samp>

new gate;
forward gateTimer(playerid);
In "OnFilterScriptInit":
pawn Код:
gate = CreateObject(976, 211.22889709473, -1447.3885498047, 12.159649848938, 0, 0, 230.97595214844);
SetTimer("gateTimer", 1000, 1);
In any place of your script
pawn Код:
public gateTimer(playerid)
{
if(IsPlayerInRangeOfPoint(playerid, 10, 211.22889709473, -1447.3885498047, 12.159649848938))
{
MoveObject(gate, 205.57905578613, -1454.2342529297, 12.159649848938, 5);
}else{
MoveObject(gate, 211.22889709473, -1447.3885498047, 12.159649848938, 5);
}
}
Reply
#4

that automatic gate coordinate idk where to put i

//Gate variable and forward
new gate;
forward gateTimer(playerid);

//Object and timer at OnGameModeInit/OnFilterScriptInit
gate = CreateObject(976, 211.22889709473, -1447.3885498047, 12.159649848938, 0, 0, 230.97595214844);
SetTimer("gateTimer", 1000, 1);
//Add this callback where you want but not inside another callback!!
public gateTimer()
{
if(IsPlayerInRangeOfPoint(playerid, 10, 211.22889709473, -1447.3885498047, 12.15964984893)
{
MoveObject(gate, 205.57905578613, -1454.2342529297, 12.159649848938, 5);
}else{
MoveObject(gate, 211.22889709473, -1447.3885498047, 12.159649848938, 5);
}
}
Reply
#5

it has error

D:\server new\pawno\hm.pwn(161) : error 017: undefined symbol "IsPlayerInRangeOfPoint"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply
#6

You use SAMP version 0.3?
Reply
#7

Go complain to whoever wrote that gate generator. The code is wrong, I have to say this every time someone makes an automatic gate post. That will only work for playerid 0.
Reply
#8

i has 0.2 server
Reply
#9

omg is that any other app for gate or can u make a auto gate for me it co ordinat is

gate closed:CreateObject(976, 211.22889709473, -1447.3885498047, 12.159649848938, 0, 0, 230.97595214844);
gate opended:CreateObject(976, 205.57905578613, -1454.2342529297, 12.159649848938, 0, 0, 230.97106933594);


if u wanna make plz make it for 0.2

thx

Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)