[Include] gBug - Prevent 'the G bug' - prevents players teleporting into passenger seat
#1

There is a bug in SA:MP where if you press G to enter a vehicle as a passenger and the driver drives away, you run after them and after 3 seconds you get teleported in regardless of how far away the vehicle is. This include fixes that.

[ame]http://www.youtube.com/watch?v=N-Gt4n8Yx9k[/ame]

Tested hundreds of times, seems flawless.

Download:
http://pastebin.com/KxU52Y1k
You will need the y_hooks include which is part of YSI, this can be downloaded here: https://sampforum.blast.hk/showthread.php?pid=1696956#pid1696956

All you need to do is include it in your gamemode. Nothing else is required.

Let me know if you find any problems with it!

Thanks.
Reply
#2

0:38 will now haunt my dreams
Reply
#3

Get on irc! Ontopic: This is excellent!
Reply
#4

Thank you
intersting if it blocks hackers to get into vehicle from a distance.
Reply
#5

LOL @ 0:38 xD
Btw, good job.. for sure I will use it.
Reply
#6

Is it has been fixed in the current version? Isn't it?
Reply
#7

Seems like the anti gbug in CrazyBob.Nice work.
Reply
#8

Quote:
Originally Posted by Jansish
View Post
0:38 will now haunt my dreams
xD

Quote:
Originally Posted by xkirill
View Post
Thank you
intersting if it blocks hackers to get into vehicle from a distance.
It won't, no. It uses OnPlayerEnterVehicle to detect when they run to a vehicle, GetPlayerSpecialAction and velocities.

Quote:
Originally Posted by Riddick94
View Post
Is it has been fixed in the current version? Isn't it?
Nope, it must be a GTA: SA bug.

Quote:
Originally Posted by Logitech90
View Post
Seems like the anti gbug in CrazyBob.Nice work.
Yeah I was 'inspired' by that.
Reply
#9

Can you make it for trying to jack player too?
Reply
#10

I was originally going to do that also, but couldn't replicate that. If you could show me a video of how it's done I will look in to it.

I assume you mean when they are jacking you but you don't see it, and you get teleported out with the 'carjacked!' gametext that is coded in to SA:MP.
Reply
#11

Quote:
Originally Posted by MP2
View Post
I was originally going to do that also, but couldn't replicate that. If you could show me a video of how it's done I will look in to it.

I assume you mean when they are jacking you but you don't see it, and you get teleported out with the 'carjacked!' gametext that is coded in to SA:MP.
Yes you described it.
Reply
#12

But how do you do it?
Reply
#13

I think when you press enter near the car you start to jack the player while the driver drives off and is still jackable.

or you can press enter if you're away from the car you'll run to the car and after 5 seconds of running sometimes it causes the gametext and jacks driver.
Reply
#14

I needed that include long to fix this bug on my server!

Thanks for the include 'gBug'
Reply
#15

You're welcome, thanks.
Reply
#16

VERY Nice Job..!
Reply
#17

Why so f*ing complex?
OnPlayerEnterVehicle - start timer - if after 3 secs they are not in vehicle reset animation, combine with GetPlayerKeys if they suddenly cancel entrance.
Reply
#18

Because of lag, both by players and server. It's not that complex.

Also it's not when they ENTER the vehicle after 3 seconds, it's when they START to GET IN the vehicle, as in STEP IN. If that doesn't happen in 3 seconds they're teleported in.
If their special action is SPECIAL_ACTION_ENTER_VEHICLE (or whatever it was) plus their velocity is all 0, they are stepping in.
Reply
#19

nice work mike, this is excellent
Reply
#20

I didn't notice this bug since now. Nice fix and idea.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)