X Y Z Coordinates - 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)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: X Y Z Coordinates (
/showthread.php?tid=260793)
X Y Z Coordinates -
Trucido - 10.06.2011
I have a problem, I've been trying to figure out the X Y Z Coordinate for the position of in-front of a player, any help would be much appreciated, thank you.
- Ki||
Re: X Y Z Coordinates -
Trucido - 10.06.2011
Will this work for anything? - I have read the code, but don't understand how this will work with other objects.
Re: X Y Z Coordinates -
Trucido - 10.06.2011
Uh- does the code work for objects, such as guns, for example, if I had a AK-47, and I did /dropgun, would it show in-front of me if I had this code implemented?
Re: X Y Z Coordinates -
Sergei - 10.06.2011
Quote:
Originally Posted by Ki||
Uh- does the code work for objects, such as guns, for example, if I had a AK-47, and I did /dropgun, would it show in-front of me if I had this code implemented?
|
People can drop guns in objects you don't want to.
Re: X Y Z Coordinates -
randomkid88 - 10.06.2011
Yes, it will work. For example in a /dropgun command, you would use GetXYPosInFrontOfPlayer to get the coords of the spot in front of them. Then create a pickup at that location.
Re: X Y Z Coordinates -
Trucido - 10.06.2011
Quote:
Originally Posted by randomkid88
Yes, it will work. For example in a /dropgun command, you would use GetXYPosInFrontOfPlayer to get the coords of the spot in front of them. Then create a pickup at that location.
|
Actually, I'm not looking forward to making a "pickup", I am actually making a command that allows you to see the actual gun laying on the ground.