SA-MP Forums Archive
Best way to make enter and exit points - 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: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Best way to make enter and exit points (/showthread.php?tid=538951)



Best way to make enter and exit points - Jimmy0wns - 25.09.2014

Hi! I've recently been looking for a way that loads checkpoints when the server starts using the database. Basically it loads the enter point and exit point of a certain building. It's quite hard to explain but once you enter the enter point (outside the building), you get in front of the exit point (inside the building) where you can also leave using the exit point which bring you back outside or near the enter point.


Re: Best way to make enter and exit points - davve95 - 25.09.2014

If I understand right. It sounds like enter and exit are to close each other. Have happened to me when I used pickups.


Re: Best way to make enter and exit points - Vince - 25.09.2014

If you are also saving the angle then you can use a variation of GetXYInFrontOfPlayer to offset their position. Instead of using GetPlayerFacingAngle, you use the angle that you saved in the database to calculate the new position.


Re: Best way to make enter and exit points - Jimmy0wns - 25.09.2014

Hopefully this example will help:
1. There's a checkpoint outside which brings you inside the cluckin' bell.
2. You get on the checkpoint and you're not inside the cluckin' bell's interior.
3. There's a checkpoint inside which brings you outside the cluckin' bell again.


Re: Best way to make enter and exit points - Jimmy0wns - 28.09.2014

Anyone?!


Re: Best way to make enter and exit points - Jimmy0wns - 29.09.2014

Anyone?!


Re: Best way to make enter and exit points - Vince - 29.09.2014

Quote:
Originally Posted by Vince
Посмотреть сообщение
If you are also saving the angle then you can use a variation of GetXYInFrontOfPlayer to offset their position. Instead of using GetPlayerFacingAngle, you use the angle that you saved in the database to calculate the new position.
4 char.


Re: Best way to make enter and exit points - Pottus - 29.09.2014

Are you even going to at least try and post some code? No one here is going to code this for you dude.


Re: Best way to make enter and exit points - Jimmy0wns - 02.10.2014

Quote:
Originally Posted by Pottus
Посмотреть сообщение
Are you even going to at least try and post some code? No one here is going to code this for you dude.
I never mentioned anything at all about code or whatever you're trying to say, I asked for small examples and explanation on how to do it. Please get your facts straight before posting such a rediculous post without even knowing what I was asking for.

Thank you.