Closed suloku closed 7 months ago
Help me understand Point 2 a little more. Do you mean actual tiles (squares of 8 x 8 pixels), or do you mean discrete spaces that NPCs stand in (composed of four tiles). If you mean the latter, that being stand-able spaces, I believe the max distance for the itemfinder is 5 because the distance is measured from the player's coordinates.
Nevermind. I see now. But I confirm that this is working correctly. I think the issue here is a misunderstanding in how the function treats diagonal distance. It does not do the Pythagorean theorem (and I am not even going to try on the GBC's processor). Instead, a diagonal is abstracted by adding the X distance to the Y distance. This results in a max distance of 9 looking like the following. It will produce 1 chime.
Oh, I see, so intended behavior is that being on a big distance won't show any arrows. I think that is a little missleading, so I'm gonna go with my version to show the arrows always if the item is on-screen, but thanks for the clarification.
This was the setup were I found out:
No, the intended behavior of your given image is that 1 chime with arrows will sound for the space in purple. I went and replicated your setup with the master branch, and I confirmed that it works in said manner. So maybe there's a code discrepancy between the main repo and your own local repo.
Either way, I incorporated item 1. Glad your fix is working for you on item 2.
Thank you, I'll check against master, see if I hsve some unnoticed mistake. I did incorporate the code on another project, but I already tried to make sure the code was correct, will check again.
There are two problems witht he current itemfinder:
Fix: