Posts: 110
Threads: 18
Joined: Dec 2013
Reputation:
0
Hello there,
Recently, I was busy doing a fishing system, but when I reached the point to check if the player in range of water I wasn't able to do it.. so I started to search around in this forum and I didn't get a satisfied answer, I saw many functions that checks if the player is inside water only and not near it.. any idea how to create such a thing for a fishing system? thanks in advance!
Posts: 734
Threads: 8
Joined: Jun 2009
Nope, there isn't any function to check 'if player is NEAR water'. I recommend you make some predefined areas where the player can fish, otherwise you have to get all the SA shores coordinates to check if he's on the beach somewhere i.e.near water.
Posts: 110
Threads: 18
Joined: Dec 2013
Reputation:
0
Any other solution? something ready as I dont have time
Posts: 734
Threads: 8
Joined: Jun 2009
Not really, you can use IsPlayerInRangeOfPoint if you want to check if player is in certain range from coordinates.. It will take you some time as unfortunately there's no other way but to get it yourself..
Posts: 801
Threads: 29
Joined: May 2012
Reputation:
0
Maybe, you could create some areas with streamer and then check if the player is near them.
Posts: 426
Threads: 128
Joined: Aug 2013
Reputation:
0
you can create few zones in any zonemaker around water.
or try some with 0.0 Z position.
Posts: 3,304
Threads: 58
Joined: Sep 2008
Reputation:
0
Look up the coordinates for water zones in your ../GTA San Andreas/data/water.dat (and/or water1.dat) files, that will tell you where water is occurring in San Andreas. From then on you can figure out if the player is near/above/in the water.
Posts: 110
Threads: 18
Joined: Dec 2013
Reputation:
0
Thank you very much, but a quick question, do you guys prefer using the plugin of mapandreas or the include by `RyDeR`? and is it true that both use a lot of memory? please explain thanks.
Posts: 1,826
Threads: 52
Joined: Feb 2012
Reputation:
0
I think that plugins are made for efficient results, so I will go with the plugin. Correct me if I am wrong.