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

Add swap army and swap artifacts to the heroes meeting screen #9387

Merged
merged 19 commits into from
Dec 30, 2024

Conversation

zenseii
Copy link
Collaborator

@zenseii zenseii commented Dec 28, 2024

This PR adds the swap army button and swap artifacts features to the heroes meeting screen.

Relates to #4084

image

Button design by @FlorianBaba and me.
swap button

Swap artifacts was added to make the screen design more consistent and it has been requested by the community according to @Branikolog.

Rotation of the arrow parts was done with this ( sin270 = -1 and cos270 = 0): https://en.m.wikipedia.org/wiki/Rotation_matrix

@zenseii zenseii added improvement New feature, request or improvement ui UI/GUI related stuff labels Dec 28, 2024
@zenseii zenseii added this to the 1.1.5 milestone Dec 28, 2024
@zenseii zenseii self-assigned this Dec 28, 2024
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Clang-Tidy found issue(s) with the introduced code (1/1)

src/fheroes2/agg/agg_image.cpp Outdated Show resolved Hide resolved
@zenseii zenseii marked this pull request as ready for review December 29, 2024 01:56
@zenseii zenseii changed the title Add swap army feature to heroes meeting Add swap army and artifacts features to the heroes meeting screen Dec 29, 2024
@Branikolog
Copy link
Collaborator

Hi, @zenseii
I've checked the PR.
Visually everything looks nice and absolutely naturally, as from design point.
I've noticed, that there's no pressed state for artifact swap button (there's no pressing animation for this only button).

Copy link
Collaborator

@oleg-derevenetz oleg-derevenetz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @zenseii I added an assertion to verify that hero will not get an empty army due to army exchange and also modernized some army-related code (while I'm here).

@zenseii
Copy link
Collaborator Author

zenseii commented Dec 29, 2024

Thanks, @oleg-derevenetz!

@zenseii zenseii changed the title Add swap army and artifacts features to the heroes meeting screen Add swap army and swap artifacts to the heroes meeting screen Dec 29, 2024
Copy link
Collaborator

@Districh-ru Districh-ru left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done, @zenseii!
I have one suggestion that can be addressed in a new PR:
We should add the right-click info to help players fully understand the mechanics of all arrow-buttons in this dialog.

@zenseii
Copy link
Collaborator Author

zenseii commented Dec 29, 2024

Well done, @zenseii! I have one suggestion that can be addressed in a new PR: We should add the right-click info to help players fully understand the mechanics of all arrow-buttons in this dialog.

Thanks, @Districh-ru! Yes, this is a good suggestion. We can make such a PR after this one.

@ihhub ihhub modified the milestones: 1.1.5, 1.1.6 Dec 30, 2024
@ihhub ihhub merged commit 16f988b into ihhub:master Dec 30, 2024
20 checks passed
@ihhub
Copy link
Owner

ihhub commented Dec 30, 2024

@zenseii , huge thanks for implementing this!

@zenseii zenseii deleted the swap-army-button branch December 30, 2024 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improvement New feature, request or improvement ui UI/GUI related stuff
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants