Skip to content
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

Automap Enhancements #6517

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

kphoenix137
Copy link
Collaborator

@kphoenix137 kphoenix137 commented Aug 26, 2023

Adds the following to the automap:

  • Important Objects
    • Orange
    • Diamond shape
    • Only in explored area
  • Town Portal
    • Blue
    • Cross shape
    • Shows even in unexplored area
  • Red Portal
    • Red
    • Cross shape
    • Only in explored area
  • Towners
    • White
    • Arrow (red X when dead - ala Slain Townsman)
  • Golems
    • Gray
    • Arrow
    • Shows even in unexplored area
  • Berserked Monsters
    • Yellow
    • Arrow
    • Shows even in unexplored area
  • Players
    • Arrow (Red X when dead)

Showcasing objects and portal on the automap:

Desktop.2023.08.26.-.19.36.22.02.mp4

Towners on automap:
image

Dead players turning red on automap:

Desktop.2023.08.27.-.00.38.31.06.mp4

Golem on automap:

Desktop.2023.08.27.-.00.34.02.05.mp4

Pentagram:

image

Transparency:

Desktop.2023.08.27.-.22.26.46.21.mp4

Fixes #6515

@AJenbo
Copy link
Member

AJenbo commented Aug 27, 2023

Please target new features to the development branch and not master until 1.5.1 has been released.

@AJenbo
Copy link
Member

AJenbo commented Aug 27, 2023

Probably use a white (or light gray) for towners so they don't look like lava monsters.
Bonus points for creating a cross shape for there indication.

I don't get why all the objects in laz chamber are on the map?

@kphoenix137
Copy link
Collaborator Author

kphoenix137 commented Aug 27, 2023

Same reason there are markers for every other quest object. Makes them easier to find. I can attest that I personally forgot how to complete the SP lazarus quest previously, because I didn't realize there was a teleporter at the spawn location. Map icons would have instantly helped me figure that out.

Source/automap.cpp Outdated Show resolved Hide resolved
@kphoenix137
Copy link
Collaborator Author

While observing Diablo 2 automap, I noticed that they used that cross shape for players, towners, and portals, and minions. For consistency, I'll be changing portals to use this cross shape, although do you think players and minions should also use the cross shape, or stick with the arrow? If we stick with the arrow, in a way I think towners should also use the arrow for consistency.

@AJenbo
Copy link
Member

AJenbo commented Aug 27, 2023

Keep the arrow for the player, maybe cross for the corpse?

@kphoenix137
Copy link
Collaborator Author

Keep the arrow for the player, maybe cross for the corpse?

What about this instead?

Desktop.2023.08.27.-.16.17.51.13.mp4

@kphoenix137
Copy link
Collaborator Author

kphoenix137 commented Aug 27, 2023

Also, I'm not sure how I feel about the cross shape, it's honestly massive, and there's no way to reduce the size of it without manually drawing pixels, and I'm not sure how nice it would play with automap scaling.

image

@AJenbo
Copy link
Member

AJenbo commented Aug 27, 2023

Did you not draw it manually with pixels?

@kphoenix137
Copy link
Collaborator Author

kphoenix137 commented Aug 27, 2023

Did you not draw it manually with pixels?

no. I drew lines. The automap also appears to have it's own specific grid and lines drawn are aligned to that grid.

@AJenbo AJenbo added this to the 1.6.0 milestone Aug 29, 2023
@kphoenix137
Copy link
Collaborator Author

I'm going to continue working on everything in this PR, and when it's satisfactory, I'll begin extracting specific things to their own PRs so the implementations can be made one by one in smaller increments. For now it feels more appropriate to keep everything in a single branch as some of the changes rely on other changes.

@kphoenix137 kphoenix137 marked this pull request as draft August 29, 2023 20:40
Change Towner color

Adjust colors

Fix river color and change towners to white

Crosses for towners

Add golem

Update automap.cpp

Draw Beserked

Draw X for dead players

Clean up code

Change rivers back to Item color

Readability

More cleanup

More cleanup

Pentragram

Fix pentagram shadow

Transparent Automap

Pentagram with no floats

Update automap.cpp

SetMapPixel and cleanup

Differentiate stairs
@julealgon
Copy link
Contributor

Just wanted to mention that that pentagram on the map looks really good, damn.

@kphoenix137
Copy link
Collaborator Author

kphoenix137 commented Aug 30, 2023

Just wanted to mention that that pentagram on the map looks really good, damn.

image (2).png

After I rebased to get the correct map offset, I noticed it fits perfectly. Couldn't ask for better than this! Courtesy of GPT 4.0

Screenshot_20230830_150050_Chrome.png

@kphoenix137
Copy link
Collaborator Author

Screenshot_20230830_150319_Chrome.png

@kphoenix137
Copy link
Collaborator Author

Desktop.2023.08.30.-.23.32.24.31.mp4

@kphoenix137 kphoenix137 changed the base branch from master to development August 31, 2023 03:53
@kphoenix137 kphoenix137 changed the title Detailed Automap Automap Enhancements Aug 31, 2023
@kphoenix137
Copy link
Collaborator Author

Just wanted to describe the minimap a bit here. I removed toggling transparency mode when toggling automap, and instead made transparency mandatory for the automap and used opaque pixels in the minimap. Toggling automap now goes between automap and minimap.

How it works is it draws a box on the top right of the screen. The size of box is as follows: height is your screen height divided by 4, and width is the height times 2. The map gets rendered only within the bounds of the box. The default zoom level depends on your screen resolution. Generally it tries to keep the same viewing distance from the player location regardless of screen resolution. For example, 480p will start the minimap at 25% zoom, where 960p will start the minimap at 50% zoom. (Keep in mind the mind the absolute dimensions of the box in 960p will be double that of 480p)

@FitzRoyX
Copy link

Just a few things to report if you weren't already aware:

  1. The preferred scale setting for each map type isn't saving between toggles, it just keeps resetting back to default.
  2. The white arrows for the towners are being drawn outside the minimap, and there is a false arrow on the northern edge of the map.
  3. Transparency doesn't seem to be getting fully applied to arrows.
  4. Mouse scroll wheel currently moves the map up and down while ctrl+scroll does scaling. I think scroll wheel should directly control scaling with no ctrl modifier, and map movement should be left to the directional keys.

@kphoenix137
Copy link
Collaborator Author

Just a few things to report if you weren't already aware:

  1. The preferred scale setting for each map type isn't saving between toggles, it just keeps resetting back to default.
  2. The white arrows for the towners are being drawn outside the minimap, and there is a false arrow on the northern edge of the map.
  3. Transparency doesn't seem to be getting fully applied to arrows.
  4. Mouse scroll wheel currently moves the map up and down while ctrl+scroll does scaling. I think scroll wheel should directly control scaling with no ctrl modifier, and map movement should be left to the directional keys.

1 is intentional.

I'm aware of 2 and 3, just need to find a good solution for it.

4 sounds like a good idea

@AJenbo
Copy link
Member

AJenbo commented Sep 1, 2023

4: it scrolls left and right if your mouse supports that

@kphoenix137
Copy link
Collaborator Author

I'll revert the change to reset the zoom level each time but I'll also have to add another global zoom variable specifically for the minimap

@kphoenix137
Copy link
Collaborator Author

4: it scrolls left and right if your mouse supports that

Good point, that might be an issue as we take away control from the player as they can no longer use left and right on the scroll wheel

@AJenbo
Copy link
Member

AJenbo commented Sep 2, 2023

Maybe it's just because i'm used to ctrl+scroll from firefox

@AJenbo AJenbo changed the base branch from development to master September 2, 2023 04:52
@kphoenix137
Copy link
Collaborator Author

Should we draw the pentagram on dlvl 16 as well?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request]: Revise automap with useful markers
5 participants