SA-MP Forums Archive
[Include] [INC] t-Auto Gates - 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: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+---- Forum: Includes (https://sampforum.blast.hk/forumdisplay.php?fid=83)
+---- Thread: [Include] [INC] t-Auto Gates (/showthread.php?tid=50322)

Pages: 1 2


[INC] t-Auto Gates - Toad - 10.09.2008

t-AutoGates by Toad
<> Script Type <>

- Include

<> Description <>

- With this include, you can create automatic gates with only one line in your script.

<> Installation <>

- Download the "t-Auto Gates.inc".
- Copy it in your /pawno/include folder.
- Open your gamemode and copy this line under "#include <a_samp>": "#include <t-Auto Gates>".

<> Commands & Function <>

- There is only one function you can use of this include:

> AddAutoGate(modelid,Float:cX,Float:cY,Float:cZ,Flo at:rX,Float:rY,Float:rZ,FloatX,FloatY,FloatZ ,namecanenter[24],open_distance)

modelid - objectid
cX - closedgate X coord
cY - closedgate Y coord
cZ - closedgate Z coord
rX - rotation X coord
rY - rotation Y coord
rZ - rotation Z coord
oX - opengate X coord
oY - opengate Y coord
oZ - opengate Z coord
namecanenter - Full or Part of the PlayerName of the Player/Clan that can enter
open_distance - radius, in which a player has to be that the gate opens

<> Example <>

- In front of the LVPD:
- AddAutoGate(980,2237.3050,2453.2110,11.421,0.0,0.0 ,90.00,2237.3050,2453.2110,1.421,"[MYCLAN]",50);

<> Download <>

-

Leave comments, please .


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Mr_Noob - 10.09.2008

This is nice and all, but surely we would need a download link of some sort?


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 10.09.2008

damn sorry i knew i forgot something
here it is


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - chesh - 10.09.2008

this looks really good dude, nice :P


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Castle - 10.09.2008

Ok, Thanks i wanted to do that...
Will help allot newbies and Rp servers


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Sr.Rafa - 11.09.2008

hi,
good idea, but for me have a problem.
in compilation have 1 waring:

: warning 213: tag mismatch

I go to my server, no connect, get a error in my GTA:SA


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Donuts - 11.09.2008

Quote:
Originally Posted by Sr.Rafa
hi,
good idea, but for me have a problem.
in compilation have 1 waring:

: warning 213: tag mismatch

I go to my server, no connect, get a error in my GTA:SA
In what line you get that error?


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 11.09.2008

for me, it has no error at all
maybe the error isnt from the include
have you done the line right??
AddAutoGate(.....); ? with 11 arguments?

i have added an example to my first post


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Unvisible11 - 12.09.2008

thx
but what is the rotation to make the gate like normal....
not like it will be like on the floor so it will be like a wall...


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 12.09.2008

u have to make the gate with an object editor
then u have the closedX - closedZ and the rotationX - rotationZ
mostly i make the open gate only lower than the closed what means :
openX = closedX openY = closedY openZ = closedZ-10

PS i made a lil error in my example, fixed now


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Unvisible11 - 12.09.2008

can you tell me the normal rotation's thate pepole do?and by the way
you know the modelid and rotation of the lspd garage gate? plz..


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 12.09.2008

to get the coords etc is what u have to do
im not here to search for the coords u have to make it with object editor


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Castle - 12.09.2008

Use MTA:Race Map Editor and then Compile it here:
http://gtamap.delux-host.com/old/
to PWN Format and you will receive the :
pawn Код:
CreateObject(ObjectID,Float:X,Float:Y,Float:Z,0,0,90,);
thats what i do... to get cords of objects but for interior you need BME Object Editor which allows you to edit the objects ingame.


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Martinss - 13.09.2008

I thought, that finally found the best gate include / script - but no - it does as the all other scripts. Gates opens only for player, that have alrgest ID. How to fix that it opens for all players?


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 13.09.2008

It does open for all players!! i tested it with 3 players, everyone could enter


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Martinss - 13.09.2008

Maybe you know where is problem? AddAutoGate - i need to put it ongamemodeinit, right?


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 13.09.2008

yes it goes at ongamemodeinit
why shouldnt it work for the other players??


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Martinss - 13.09.2008

Nevermind, already solved the problem. http://forum.sa-mp.com/index.php?topic=73348.0


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - ғαιιοцт - 13.09.2008

nice fs, and easy to use


Re: [INC] Automatic Gates by Toad (1 line - 1 gate) - Toad - 13.09.2008

damn its right!!!
it really only works for the highest ID
sorry u had got absolutely right
i made it right (i think) so thx