SA-MP Forums

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

Reply
 
Thread Tools Display Modes
Old 13/06/2013, 09:56 AM   #1
V1ceC1ty
Banned
 
Join Date: Oct 2008
Location: West Australia
Posts: 1,896
Reputation: 273
Default [RP] Vehicle GEAR Changes v0.2 [REALISTIC DRIVING]


Vehicle Gear changes v0.2

Information - This is quite a heavy RP feature you can add to your server which includes 6 Manual Gear changes and speedometer in a Textdraw. It's also great for video editing and NPC making, you can set your vehicle to a lower gear for a smooth ride!

[ame]http://www.youtube.com/watch?v=9bS59lmXdgw[/ame]

- How to use
• Players can use by default(KEY_YES) to change up a gear and (KEY_NO) to go down a gear.
• RED Coloured gears means you can not change up until it is GREEN
• You must reach the right speed to change to the next gear (#define GEAR1_SPEED 20)
Code:
Default gear speed changes:
Engine off -> Gear 1 = 0
Gear 1 -> Gear 2 = 20
Gear 2 -> Gear 3 = 40
Gear 3 -> Gear 4 = 60
Gear 4 -> Gear 5 = 75
Gear 5 -> Gear 6 = 95
• Not as good/fast cars may not be able to reach 6th Gear, like IRL some cars do not have 6 Gears.
• You can turn the engine off when you shift down past Gear 1 or on if you go into Gear 1
• Lower gears have lower speeds, in order to reach the vehicles top speed you must be in Gear 6.
• Players can drive slower wherever they want instead of tapping 'W', just put the car into the desired gear.
• Optional more hardcore gear control. Set to "true" to enable damage if your vehicles RPM is too high for the gear.

Installation -
• Upload vGears.amx to your server 'filterscripts' folder.
• Add 'vGears' to your server.cfg filterscripts line

Known/possible bugs -
• When you enter a vehicle for the first time, gears might not have an effect. To fix Press Y and then N.
This is because the engine might not be turning off correctly.

• Please report more if you can!

Updates -
Update v0.2:

•You now have the option to set gear damage. Having this on will damage the vehicle if they have the RPM too high. By default it is on "false" so set it to "true" if you would like this.
Code:
new bool:DefaultGearDamage = false;
•There is a define for how many times the vehicle can withstand too high RMP before it gets damaged. You can change this by setting it to a lower or higher number. After the default 10 times if they continue to use the gears wrong they will set the vehicle health -50 each time.
Code:
#define DAMAGE_COUNT 10
•I'm working on a better gear system much like real life; If you start in a high gear(e.g. 6) it will take a lot longer to accelerate to the vehicles top speed. I'm not exactly sure how I'm going to go about doing this yet but for now by default if you are in gear 2+ and your speed drops to 0, your gears will reset back to 1.

If you would like to remove this until I come up with an affective way of properly doing this you can remove the following at lines 421-426:
Code:
if(vGear[playerid] >= 2 && GetPlayerSpeed(playerid) == 0)
	{
 		vGear[playerid] = 1;
 		SetPlayerSpeedCap(playerid, 0.1);
		TextDrawSetString(Gear[playerid], "~r~1");
	}
Download -
v0.2 DIRECT DOWNLOAD
v0.2 PASTEBIN

v0.1 DIRECT DOWNLOAD
v0.1 PASTEBIN

Credits -
Speed limiter provided by Slice
http://forum.sa-mp.com/showthread.php?t=179089

NOTE: If anyone has a good Race server and is going to use it I'd be really interested in trying it out with a few other players!

Last edited by V1ceC1ty; 13/06/2013 at 06:10 PM.
V1ceC1ty is offline   Reply With Quote
Old 13/06/2013, 09:59 AM   #2
Jizz
Big Clucker
 
Join Date: May 2013
Location: Bekasi, Indonesia
Posts: 99
Reputation: 1
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

What a great FS. I'll test
__________________


skype: faridz.sirss
Jizz is offline   Reply With Quote
Old 13/06/2013, 10:37 AM   #3
Nightangle
Big Clucker
 
Nightangle's Avatar
 
Join Date: Jun 2012
Location: India
Posts: 148
Reputation: 16
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

Wow nice
__________________
"When you feel you're alone
cut off from this cruel world
Your instinct's telling you to run
Listen to your heart
Those angel voices , They'll sing to you
and they'll be your guide
.. back home
When life leaves us blind
Love keeps us kind''
-Linkin Park
Nightangle is offline   Reply With Quote
Old 13/06/2013, 11:02 AM   #4
Delta 4
Little Clucker
 
Join Date: Sep 2011
Location: Portugal
Posts: 47
Reputation: 1
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

i liked the FS a lot but on reversing, how does it work? didn´t see that neither on the video or on the info ^^
__________________
Multi-Language Server. Have Fun Servidor Multi-Idioma. Divirtam-se Serveur Multi-Langue. Amusez-vous!

Delta 4 is offline   Reply With Quote
Old 13/06/2013, 11:44 AM   #5
dEcooR
Banned
 
Join Date: Feb 2012
Location: Slovakia
Posts: 481
Reputation: 2
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

really realistitcs
dEcooR is offline   Reply With Quote
Old 13/06/2013, 12:41 PM   #6
V1ceC1ty
Banned
 
Join Date: Oct 2008
Location: West Australia
Posts: 1,896
Reputation: 273
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

Quote:
Originally Posted by Delta 4 View Post
i liked the FS a lot but on reversing, how does it work? didn´t see that neither on the video or on the info ^^
That's the only thing missing from it, and neutral of course. You can put it into 1st gear and reverse.

@Everyone else: Thanks.
V1ceC1ty is offline   Reply With Quote
Old 13/06/2013, 12:50 PM   #7
Avi57
Banned
 
Join Date: Mar 2012
Location: Punjab, India
Posts: 701
Reputation: 15
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

A W E S O M E
Avi57 is offline   Reply With Quote
Old 13/06/2013, 02:50 PM   #8
Jizz
Big Clucker
 
Join Date: May 2013
Location: Bekasi, Indonesia
Posts: 99
Reputation: 1
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

What button to gear up and gear down?
__________________


skype: faridz.sirss
Jizz is offline   Reply With Quote
Old 13/06/2013, 03:00 PM   #9
doreto
High-roller
 
doreto's Avatar
 
Join Date: Aug 2010
Posts: 1,667
Reputation: 118
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

Quote:
Originally Posted by Jizz View Post
What button to gear up and gear down?
Y - gear up
N- gear down
__________________
Quote:
Originally Posted by Kalcor View Post
This my site, so I get to decide what links are allowed. utube and 1e100 are no longer part of my web of trust.

The internet is more important to me than sa-mp. You don't get sa-mp without the internet.
Quote:
Originally Posted by [Twixx] View Post
That's kind of hypocritical of you to say. Sure you own the website, but it's not your personal blog or something - it's a community driven forum. The community should be the primary focus, not your personal agendas. Just like you don't get SA-MP without internet, you don't get SA-MP forums without community.

Just wiping out years worth of people's work and creations posted on that board because a bunch of people bypassed your Tube ban is absurd.
Quote:
Originally Posted by Mauzen View Post
"tube sucks cause they delete 6 years old videos for no reason!"

*deletes every single video ever posted here in 12 years*
doreto is offline   Reply With Quote
Old 13/06/2013, 03:12 PM   #10
Jizz
Big Clucker
 
Join Date: May 2013
Location: Bekasi, Indonesia
Posts: 99
Reputation: 1
Default Re: [RP] Vehicle GEAR Changes [REALISTIC DRIVING]

How to change the key button?
__________________


skype: faridz.sirss
Jizz 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
[Tutorial] How to make a driving vehicle NPC Sayaron Tutorials 9 16/07/2015 03:42 AM
[FilterScript] 3rd Person Vehicle Driving [0.3e] rati555 Filterscripts 49 24/03/2014 08:10 AM
NPC driving a vehicle(??) MrBorsh Scripting Help 1 01/09/2012 11:50 PM
[FilterScript] [::] Realistic Vehicle Explosion/Death Physics [::] iPLEOMAX Filterscripts 23 02/09/2011 12:38 PM
[FilterScript] How to let players pay for driving a vehicle? HireMe Filterscripts 1 19/09/2010 10:31 PM


All times are GMT. The time now is 05:42 AM.


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