-
Notifications
You must be signed in to change notification settings - Fork 553
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add an option to display the path travalled by the local player #2062
base: master
Are you sure you want to change the base?
Conversation
7d06a20
to
de9f05e
Compare
Okay, I don't really know much about the automap code, but this seems and works fine code-wise. But I feel like the way to not draw path lines when the player teleports is kinda flawed. It does not account for short distance teleports, like say a teleporter that just transports you to the other side of a wall, and so lines are drawn between teleport positions anyway. |
Cool. If I were you, I'd use |
I've set the distance threshold pretty high while testing. It can probably be decreased as even full-speed SR50 isn't quite close to this distance threshold (in terms of distance travelled per tick). Edit: I've reduced the distance threshold for teleport detection from 300 to 100 units. I've tested Doom 2 MAP12 with
There doesn't appear to be a built-in type for points with |
de9f05e
to
b0d4921
Compare
Yeah that works a lot better, by the way, if you wanna test something involving player speed, I'd suggest using the
That ain't happening, 65535x65535 map units is the maximum size limit for any Doom maps except for the ones in Sonic Robo Blast 2, where IIRC they doubled the map size limit |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is an interesting idea and I like it, but, I am not a fan of it doing a static distance check to see if it should break the lines.
Instead, what you should do is see if the delta distance between tics is greater than the player's velocity. This would be a much more reliable way to check for teleport shenanigans since - in some cases - velocity can be arbitrary. As a general rule, always whenever possible, avoid arbitrary static numbers, especially in a moddable engine.
This is useful to avoid getting lost on larger maps.
b0d4921
to
d853f9b
Compare
I've tried my hand at implementing this in a second commit (which also fixes a compilation warning related to signed type comparison). It works mostly OK from my testing. One issue is that bumping into a wall and backing up will cause the line to be missing one point: PS: Doom E2M4 is a good place to test this code, as it has a teleport near the starting area. |
Any more progress or info on this PR? |
This is useful to avoid getting lost on larger maps. This is inspired by a feature from Doom Retro.
The following situations have been tested:
Future ideas:
kill count / number of monsters in map
), so you know how recent a certain portion of the path is. This could also be based on game time, but I think it'd be preferable for existing path points to keep their color.Preview
Normal mode
Overlay mode