Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Distance Checking
#1
Distance Checking

This is a locked, single-post thread from Creation Asylum. Archived here to prevent its loss.
No support is given. If you are the owner of the thread, please contact administration.


I have updated this method, which now only ever uses up to 3 arguments. What it does is simple: use it as a script call in an event to get the distance between two objects. Some examples:
[ruby]$game_variables[1] = get_distance()[/ruby]This line in a Call Script will set Variable 1 to the distance between the player and the event that called it, rounding to the nearest whole number. Best used within the Script command in an event.
[ruby]get_distance(-1, 3) > 7[/ruby]This line will return true if Event ID 3 is more than 7 tiles distant from the player. Best used within a conditional, inside any event on the same map as the Event ID 3 you want to compare against.

The Script

Screenshots
None needed.

FAQ
Do I need one?

Compatibility Issues
None known yet.
}




Users browsing this thread: