SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Filterscripts

Reply
 
Thread Tools Display Modes
Old 25/11/2015, 06:46 AM   #1
IceBilizard
Gangsta
 
Join Date: Feb 2012
Posts: 868
Reputation: 47
Default Dynamic Gate System

Dynamic Gates System

Introduction: Hello This is my seconds filterscript i was getting bored so i create this script well there are a-lot of scripts for create gate system but this is one is really easy you can create gates with simple command you can edit the gate open/close/speed/password in game any time its really easy.

Commands:
/creategate (It will open a dialog and show you a list of gates in last there is a option to add custom gate id you can put id of gate which you want).
/editgate (It will give you some options like: Open, Close, Speed, Password).
/destroygate (it will destroy a specific gate id).
/gate (It will open nearest gate else will give you message you are not near to any gate).
/nearestgate (It will show you the nearest gate id and object in 5.0 radius)
/gused (It will show all gates created in server).
/gotogate (it will teleport you to a specific id).


Video Tutorial:
https://vid.me/hEvo

Installation: Installation is not hard you have to put all files in correct directories which are given in package.

Download:
http://www.solidfiles.com/d/6305b5128a/
https://www.mediafire.com/?017gnvy8qoz8r3s
__________________


IceBilizard is offline   Reply With Quote
Old 25/11/2015, 03:27 PM   #2
Pottus
Godfather
 
Pottus's Avatar
 
Join Date: Jun 2012
Posts: 5,418
Reputation: 1240
Default Re: Dynamic Gate System

You used dini (bad practice) whatever but the real problem is that your script doesn't check if the player is actually editing a gate this will break any other filterscript that has OnPlayerEditDyanmicObject(). You also repeat code a shit load of times that does the same thing with different variables create one function with variable parameters and call it only once when required.
Pottus is offline   Reply With Quote
Old 26/11/2015, 06:47 AM   #3
IceBilizard
Gangsta
 
Join Date: Feb 2012
Posts: 868
Reputation: 47
Default Re: Dynamic Gate System

Quote:
Originally Posted by Pottus View Post
You used dini (bad practice) whatever but the real problem is that your script doesn't check if the player is actually editing a gate this will break any other filterscript that has OnPlayerEditDyanmicObject(). You also repeat code a shit load of times that does the same thing with different variables create one function with variable parameters and call it only once when required.
Thanks for your comment but i think you didn't check the script properly there are 2 variable to check player is editing a gate and if you are gonna edit another gate then 1st gate variables will be reset and i am using it with 4 scripts in my server there are no problem with it.
__________________


IceBilizard is offline   Reply With Quote
Old 26/11/2015, 10:14 AM   #4
Adornil
Banned
 
Join Date: Oct 2014
Location: Pakistan
Posts: 69
Reputation: 2
Default Re: Dynamic Gate System

Greate Job selvin!
Adornil is offline   Reply With Quote
Old 26/11/2015, 01:57 PM   #5
Pottus
Godfather
 
Pottus's Avatar
 
Join Date: Jun 2012
Posts: 5,418
Reputation: 1240
Default Re: Dynamic Gate System

There is no provisions at all in place look at the code.

Code:
public OnPlayerEditDynamicObject(playerid, objectid, response, Float:x, Float:y, Float:z, Float:rx, Float:ry, Float:rz)
{
	new idx = gGateEditID[playerid], string[128];
	if(response == EDIT_RESPONSE_UPDATE)
	{
		SetDynamicObjectPos(objectid, x, y, z);
		SetDynamicObjectRot(objectid, rx, ry, rz);
	}
Edit an object in a different script that uses OnPlayerEditDynamicObject() and this code will be called even if the object isn't a gate.
Pottus is offline   Reply With Quote
Old 14/12/2015, 10:52 AM   #6
ProDude
Little Clucker
 
Join Date: Dec 2015
Location: Bangladesh
Posts: 9
Reputation: 0
Default Re: Dynamic Gate System

Nice Job Selvin
ProDude is offline   Reply With Quote
Old 04/03/2016, 05:56 AM   #7
N0FeaR
High-roller
 
N0FeaR's Avatar
 
Join Date: Nov 2011
Location: Los Santos, Idlewood
Posts: 2,338
Reputation: 155
Default Re: Dynamic Gate System

Great job!
__________________
Check out this sh*t

N0FeaR is offline   Reply With Quote
Old 04/03/2016, 11:01 AM   #8
xXRevolverXx
Big Clucker
 
xXRevolverXx's Avatar
 
Join Date: Dec 2015
Location: Egypt
Posts: 79
Reputation: 14
Default Re: Dynamic Gate System

Gj xD
xXRevolverXx is offline   Reply With Quote
Old 04/03/2016, 11:31 AM   #9
markparker12
Huge Clucker
 
markparker12's Avatar
 
Join Date: Sep 2015
Posts: 152
Reputation: 25
Default Re: Dynamic Gate System

good job
__________________
Free/Paid Game Server Hosting/Web Hosting/SA-Mp HostedTab
Hiring mature, active loyal and skilled players!



My Works
markparker12 is offline   Reply With Quote
Old 06/05/2016, 01:32 PM   #10
zulfi
Little Clucker
 
Join Date: Apr 2016
Posts: 10
Reputation: 0
Default Re: Dynamic Gate System

Nice +rep and plx post the video in *******
zulfi is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
dynamic gate Jhony_Blaze Scripting Help 0 18/12/2014 05:12 PM
Cant save gate in dynamic gate system muky Scripting Help 2 11/05/2013 05:34 AM
[Tool/Web/Other] Dynamic Gate system coolguy711 Filterscripts 1 10/11/2012 05:54 AM


All times are GMT. The time now is 11:15 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.