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

#8924 fix Hero Movement button #9085

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AlexSnowLeo
Copy link
Contributor

@AlexSnowLeo AlexSnowLeo commented Sep 5, 2024

Close this issue: #8924
Fixed check on Hero Movement button to delete hero path always regardless of the button status.

to delete hero path always
@oleg-derevenetz
Copy link
Collaborator

Despite the fact that it technically works, it doesn't look very elegant. First of all, this button is disabled, that is, from the user's point of view, it cannot be pressed. Also, since it is disabled, there is no press and release animation.

@AlexSnowLeo
Copy link
Contributor Author

Despite the fact that it technically works, it doesn't look very elegant. First of all, this button is disabled, that is, from the user's point of view, it cannot be pressed. Also, since it is disabled, there is no press and release animation.

Hi @oleg-derevenetz. In this case, I see two options:

  • button can be pressed in the disabled state
  • add another state for the hero movement button, which will show that there is a hero path, but there are no movement points;

Could you describe how you see the solution to this problem?

@oleg-derevenetz
Copy link
Collaborator

oleg-derevenetz commented Sep 5, 2024

I'd prefer to add a special state for this case, just like it's done for the "visit the object under the hero" action, but we need some artwork for this, which would somehow graphically indicate the possibility of canceling the current hero route.

@AlexSnowLeo
Copy link
Contributor Author

I'd prefer to add a special state for this case, just like it's done for the "visit the object under the hero" action, but we need some artwork for this, which would somehow graphically indicate the possibility of canceling the current hero route.

Do we need to wait for the icon design for this feature? Or is it possible to use some existing image?

@oleg-derevenetz
Copy link
Collaborator

Do we need to wait for the icon design for this feature? Or is it possible to use some existing image?

I am not aware of any existing image with the suitable style and meaning, so we need to come up with and draw it first.

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Sep 6, 2024

Do we need to wait for the icon design for this feature? Or is it possible to use some existing image?

I am not aware of any existing image with the suitable style and meaning, so we need to come up with and draw it first.

Do you have any instructions on how to do this? Or is it possible to ask for help from a certain person (interface designer)?
I could try to draw a new icon based on the current one, but how do I get the current one and add a new one to the game data?

@oleg-derevenetz
Copy link
Collaborator

Do you have any instructions on how to do this? Or is it possible to ask for help from a certain person (interface designer)?
I could try to draw a new icon based on the current one, but how do I get the current one and add a new one to the game data?

I see two options here:

  1. You can generate a new button image based on existing button image, like it's done in Add hero action button image #7979;
  2. You can draw a new button and add it to the resurrection.h2d, like it's done e.g. in Add Editor icon to the Main Menu #8599. You will need to use the h2dmgr tool (see the contents of src/tools) to add a JPG or PNG image to our data file. These tools are available for certain platforms as separate archives in the Releases section (e.g. here for Windows) or you can build them yourself.

I think the choice of option depends on the desired button image (it will also need to be thought up).

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Sep 6, 2024

I think the choice of option depends on the desired button image (it will also need to be thought up).

The idea is something like this. Show a red destination at the bottom, as in the additional icon with a horse on end.
002_

Maybe we should bring this up for discussion?

@oleg-derevenetz
Copy link
Collaborator

Maybe we should bring this up for discussion?

Hi @ihhub @zenseii @Districh-ru @Branikolog what do you think about the image? Any ideas?

@zenseii
Copy link
Collaborator

zenseii commented Sep 6, 2024

@oleg-derevenetz and @AlexSnowLeo. The concept in the picture is pretty much what I had in mind. Since we are making a pressable replacement for the disabled state of the button, in other words when there are no movement points left, maybe something like a horse that has been tethered to a short pole, to symbolize having parked for the day.

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Sep 7, 2024

@oleg-derevenetz and @AlexSnowLeo. The concept in the picture is pretty much what I had in mind. Since we are making a pressable replacement for the disabled state of the button, in other words when there are no movement points left, maybe something like a horse that has been tethered to a short pole, to symbolize having parked for the day.

Unfortunately, I am far from an artist. Maybe something like this? I will also attach the source code in the format paint.net.
002__
002.zip

How it's looks like in game:
image

@ihhub
Copy link
Owner

ihhub commented Sep 7, 2024

@AlexSnowLeo and @oleg-derevenetz , let's wait for @Districh-ru being available. He generated the original icon and he could suggest how to do it for the new one.

@ihhub ihhub added improvement New feature, request or improvement ui UI/GUI related stuff labels Sep 7, 2024
@oleg-derevenetz
Copy link
Collaborator

Unfortunately, I am far from an artist.

We are also not talented artists, so making changes that require new art is usually problematic. But in this case, I'm afraid we can't do without it if we want everything to look nice.

@Districh-ru
Copy link
Collaborator

Hi, @AlexSnowLeo, I've made the hero action button image by simply taking an action cursor and placing it on the button image with a small corrections.
Unfortunately we don't have any image or cursor for the clear path action. I can suggest to take the original images from ICN::ADVBTNS and ICN::ADVEBTNS.
You can use the clean button image made in lines 4046-4061 in agg_image.cpp, copy it to the IDs 18 and 19, copy a top part of the horse from IDs 2 and 3. Then draw the tail and legs.
It is a big "pixel-precision" work...
Good luck!
If you have any questions, please ask)

@AlexSnowLeo
Copy link
Contributor Author

Hi @Districh-ru. Yes, I have already considered this place in the code and tried to draw something suitable from the existing pictures of the game. But unfortunately there is no suitable picture (perhaps the image of the hero on a horse is suitable, but it is too colorful). Maybe there is not only another way to go? Make a mask of the image of a standing horse. And then apply it in the code along with the shadow on the button. The problem for me so far is only in shadow rendering. And let's still choose a concept, is this the one that @zenseii suggested - a horse standing on a leash?

@ihhub ihhub marked this pull request as draft September 21, 2024 04:29
@Districh-ru
Copy link
Collaborator

Hi, @AlexSnowLeo, sorry for the late reply.
Yes we can choose @zenseii's concept.
We can use the original button image, but redraw the legs and draw a pole.
If you have questions or issues making the image or its shadow - please write.

Hi, @Branikolog, what do you think about this image for the cancellation of move path?
002__

@zenseii
Copy link
Collaborator

zenseii commented Sep 21, 2024

@Branikolog, @Districh-ru and @AlexSnowLeo.

I have asked @FlorianBaba for his assistance/advice since he is a skilled pixel artist.

@AlexSnowLeo's graphic looks like what I imagined, but I realized it looks a bit too crammed and perhaps too detailed to easily understand what it represents at a distance. I believe with some fine-tuning we can improve it though this is outside of my abilities.

@FlorianBaba
Copy link
Contributor

FlorianBaba commented Sep 21, 2024

Hello there 👋

Indeed, I would love to participate.
I just need to think about it a bit to come up with a suitable icon.
But it shouldn't take me too long, I'll try to do it next week!

I'll keep you posted 👍

@FlorianBaba
Copy link
Contributor

Hi everyone 👋

I've spent some time thinking about a suitable icon, trying to respect the original style.
Here are 4 suggestions:

horse_icon_A A
horse_icon_B B
horse_icon_C C
horse_icon_D D

Just to share you my approach, I first tried @zenseii idea, which I thought was a good one. But I came to the same conclusion : i.e. that the icon is visually overloaded and not easily understandable.

Then I went back to @AlexSnowLeo original idea, using the destination cross of the route taken by the heroes on the map. I tried to make the cross more prominent by using a horse's head icon.

@zenseii
Copy link
Collaborator

zenseii commented Sep 26, 2024

@FlorianBaba

horse_icon_D D

I'll repeat some of the comments I wrote to @FlorianBaba in DM here. I think the icon D which is a development of @AlexSnowLeo's idea is the best because it keeps the same concept as the other two states of the button, which are the prancing and walking icons, and you can see the entire horse on those too. The idea of removing the trail before the cross is better imo because it couldn't be interpreted as representing a walkable path, due to the monochrome nature of these icons which some might interpret as referring to the green arrows.

It might give an impression of inconsistency if we change the icon to just show the head. As for the head being filled with one color, this might be seen as inconsistent with the general style of these icons which apart from the horse, have very thin lines outlining them and some amount of detail drawn within the object, like the knight's head having facial features etc.
image
The similar idea can be seen in other monochrome icons:
image
image image

The exceptions are the horse and the view world button, however they are generally smaller icons than the horse head icons.

Meanwhile, on @FlorianBaba's Discord server there was a discussion about this and some good ideas were given. One was to have a horse standing still and with the head bent down. In my opinion this would fit in well with the logical group: prancing; walking; standing still.

@FlorianBaba
Copy link
Contributor

FlorianBaba commented Sep 26, 2024

We talked it over with @zenseii and thought it would be interesting to add a new suggestion, the one he mentioned in his previous message.

horse_icon_E E

It's up to you to choose now ^^

@Branikolog
Copy link
Collaborator

Branikolog commented Sep 27, 2024

Hello everyone!
Thanks for making so many choices. :)

I personally prefer D from an implementation quality state.

horse_icon_D D

Not perfect one, though.

Logically, I expect something like @AlexSnowLeo proposed. Just a standing horse. We already have galloping and dancing icons, so new standing one feels appropriate. I'm only concerning about the horse design. Needs to be more polished and better proportioned. I also not sure about cross or ! mark. It looks too tiny. I prefer an icon being more simple: without multiple small details.

002__

I personally thought about placing just a cross, which is used for path destination, on this button :
image

It can look simple and really easy to distinguish from other icons.

But the standing horse feels kind of uniform design. 👍 It just needs to be more proportional, and players should always be able to easily distinguish it from the other two button states, especially the galloping one.

@zenseii
Copy link
Collaborator

zenseii commented Sep 27, 2024

@FlorianBaba

We talked it over with @zenseii and thought it would be interesting to add a new suggestion, the one he mentioned in his previous message.

horse_icon_E E

It's up to you to choose now ^^

Very nice! This is the idea I had. The reason to have the head bent is to distinguish it more from the galloping horse. I have some small comments. The horse looks a bit rounder around the stomach so maybe we could make it leaner?

I believe there's something about the ears we can adjust. I'm not an equine expert but should their ears point down when they bend their head down?

The tail looks like it has become a bit shorter, but I'm not sure there's enough space to make something that distinguishes it more?

@Branikolog, I also considered having only the cross, but I believe it will look incoherent if the button switches states between Galloping horse, Prancing horse and a cross. This is why I'm in favor of the horse standing still.

@FlorianBaba
Copy link
Contributor

FlorianBaba commented Sep 28, 2024

@zenseii I've tried to take your feedback into account for the E version.
It's not easy on very small icons, because each added pixel completely changes the perception 😅

So :

  • The tail is lengthened and revised
  • A few pixels have been removed to make the horse less plump.

horse_icon_Ev2 E v2

Your feedback on the ears made me smile, because I had asked myself the same question as you the first time.
But after checking, the ears point upwards when the horses are grazing.

horse1
horse2

@Branikolog
Copy link
Collaborator

@zenseii

@Branikolog, I also considered having only the cross, but I believe it will look incoherent if the button switches states between Galloping horse, Prancing horse and a cross. This is why I'm in favor of the horse standing still.

I agree with this. The only thing I was concerning about is that two icons with a horse standing horizontally could be not distinguishable especially on tiny mobile screens. We should come up with a design which allow player to easily notice and understand the difference between these button states.

  • The tail is lengthened and revised
  • A few pixels have been removed to make the horse less plump.

horse_icon_Ev2 E v2

I have few suggestions on polishing this design even more, but I'm still hesitating about the concept. :)
The proposed icon brings me in mind a conception of resting, rather than cancelling. Such icon could fit hero "sleep" mode better in my opinion. :)

Since we work on hero path cancelling, just standing still horse logically fits more in my opinion. So, how do you guys think of placing just standing horse for this icon? Or we can go even further and draw horse during "braking" process :).
Something like that:

horse stop2

@zenseii
Copy link
Collaborator

zenseii commented Sep 28, 2024

@FlorianBaba

@zenseii I've tried to take your feedback into account for the E version. It's not easy on very small icons, because each added pixel completely changes the perception 😅

Yes, I understand this and your work is very appreciated 👍It looks better now. I'm not a horse expert myself either but I try to give meaningful feedback.

the ears point upwards when the horses are grazing.

You're right and I checked myself now too. To me it appears like the ears are always at a ~perpendicular angle to the head like I've shown in the images below. Could we try to make the horse icon's ear angle a bit less acute? I'm asking this because for some reason to me the head looks sharp like a wolf's head.

After looking at several images of horses grazing, I noticed that they always stand with one of the front legs a bit ahead of the other like I'm showing in the bottom picture, probably to be able to bend the head lower.

Another thing I think we could improve is to have a less deep curve of the horse's back as it seems a bit too much, not as much as a camel but slightly too much. I'm referring to the triangle shown in the bottom picture. This is what I'm observing from several pictures and not just that one.

image

image

@Branikolog

Since we work on hero path cancelling, just standing still horse logically fits more in my opinion. So, how do you guys think of placing just standing horse for this icon? Or we can go even further and draw horse during "braking" process :).
Something like that:

image

I can see what you mean here. A horse breaking to me brings to mind the action you do when you interrupt a horse from moving along a path, which you do by pressing any button.

I'm also sensing that we are not entirely on the same track regarding the functioning of the button. With the implementation of this PR, you will have to press this new button for 3 seconds to cancel the path. A single short press of that button will do nothing until we figure out some meaningful thing for that to do. Perhaps I misunderstood.

The proposed icon brings me in mind a conception of resting, rather than cancelling. Such icon could fit hero "sleep" mode better in my opinion. :)

I had not thought about this, but I believe a sleep button would be better if it takes a completely different motive than a horse since the sleep function is something quite different from continuing a path or cancelling a path.

However, your idea about sleeping and trying to differentiate this icon as much as possible made me think about having an icon of a horse laying down:

image

This would distinguish the states even further and indicate to the player that the horse/army is now out of movement points. However, for now this is a digression and I would still much more like to see a grazing horse than this.

@LeHerosInconnu
Copy link

Hello everyone,

Here's a proposal with just a few lines to symbolize a sense of movement (in the case of the predefined path displayed on the adventure map), without altering the original graphics too much.
In order of preference.

First:
0002 01

Second:
0002 02

Third:
0002 03

@FlorianBaba
Copy link
Contributor

FlorianBaba commented Oct 2, 2024

Hello again 👋

@zenseii and I have had a lot of discussions on the subject, and we've come to the conclusion that since the button will have 3 versions, it's better that the three illustrations look the same and that you can see the continuity when moving from one to the other.

So here's a new proposal :
horse_icon_F7

And a gif version to show you the consistency with the other versions of the button :
Version_3_revamp5

@zenseii
Copy link
Collaborator

zenseii commented Oct 2, 2024

@Branikolog,

about the last concept, I would like to add that to me it seems better that a button that is supposed to reflect some sort of "inaction" and no response when the user presses the button, is done better with a passive/inactive horse, as opposed to the more active breaking horse or the icon that @LeHerosInconnu showed. In my opinion, a user would be more likely to be confused about why a button does nothing when the icon shows some sort of action, compared to a button that shows a horse standing still.

@Branikolog
Copy link
Collaborator

@zenseii & @FlorianBaba
The last proposal seems good for me. I was afraid, that standing horse would be hard to distinguish, but because of completely different legs design it is quite legible and the overall design looks uniform. 👍
Indeed, standing still horse suits the idea of a hero without any selected objective. (And better, than grazing horse).

@zenseii
Copy link
Collaborator

zenseii commented Oct 2, 2024

@Districh-ru, I believe we should implement this new icon by generating it on the fly in the engine, rather than adding it to fheroes2 resources, because some parts are the same as the galloping horse. What do you think? Also feel free to give any feedback on the proposed icon.

We should push the changes adding the new icon to this PR.

@zenseii zenseii added this to the 1.1.3 milestone Oct 2, 2024
@Districh-ru
Copy link
Collaborator

@Districh-ru, I believe we should implement this new icon by generating it on the fly in the engine, rather than adding it to fheroes2 resources, because some parts are the same as the galloping horse. What do you think? Also feel free to give any feedback on the proposed icon.

We should push the changes adding the new icon to this PR.

I like the icon proposed by @FlorianBaba, thanks!

a) We can add only the changed parts to the engine resources and make a new icon by taking galloping horse and "Blitting" the changed part (the unchanged pixels will be transparent) on it during the ICN load.
b) Or we can also update the image on fly by erasing the changed part and drawing them using engine functions.

The second approach needs more careful icon "drawing" in the code. ... and it will make out agg_image.cpp bigger ...

Hi, @ihhub, which approach do you prefer?

@ihhub
Copy link
Owner

ihhub commented Oct 3, 2024

Hi @zenseii and @Districh-ru , if the image difference is small and easy to generate then we can go with storing it in fheroes2 resources. If the image generation is easier to do then we can go with image generation approach. The size of the code is not an issue.

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Oct 10, 2024

Hello again 👋

@zenseii and I have had a lot of discussions on the subject, and we've come to the conclusion that since the button will have 3 versions, it's better that the three illustrations look the same and that you can see the continuity when moving from one to the other.

So here's a new proposal
And a gif version to show you the consistency with the other versions of the button

@FlorianBaba Can you send me just a clean mask of a standing horse, without unnecessary details? I will try to encode this and apply a shadow using the game engine on the button substrate. ([email protected])

@zenseii
Copy link
Collaborator

zenseii commented Oct 10, 2024

@AlexSnowLeo, @ihhub and @Districh-ru

I believe the first thing to do is to check how much overlap there is between the standing and the galloping horse, perhaps make an image showing the non-common pixels on the galloping horse. This will help us understand what the best course of action is.

Imo image generation shouldn't be hard since some parts like the head can just be copy-pasted, as we do on the fly.

@AlexSnowLeo, the reason we are talking about just including the image differentials is due to copyright. The standing horse is derived from the galloping one and therefore we can't just take the entire standing horse and supply it with the engine.

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Oct 11, 2024

@AlexSnowLeo, the reason we are talking about just including the image differentials is due to copyright. The standing horse is derived from the galloping one and therefore we can't just take the entire standing horse and supply it with the engine.

@zenseii It is for this reason that I initially proposed to make only a modification of the current image. For example, add only the cross symbol of the path:
image

@FlorianBaba
Copy link
Contributor

FlorianBaba commented Oct 11, 2024

@FlorianBaba Can you send me just a clean mask of a standing horse, without unnecessary details? I will try to encode this and apply a shadow using the game engine on the button substrate. ([email protected])

Yes, no problem, I'll send you an e-mail later today 👍

EDIT: Done 😉

@AlexSnowLeo
Copy link
Contributor Author

AlexSnowLeo commented Oct 13, 2024

@AlexSnowLeo, the reason we are talking about just including the image differentials is due to copyright. The standing horse is derived from the galloping one and therefore we can't just take the entire standing horse and supply it with the engine.

@zenseii, @ihhub and @Districh-ru
I did a little demo in the image editor. How can the current prancing horse icon in the code be modified approximately. Please take a look. Nevertheless, the tail section requires more detailed rendering, although the legs can be copied :)

https://youtu.be/rfMVEBdVCu4

The resulting button image, without shadow:
изображение

@ihhub ihhub modified the milestones: 1.1.3, 1.1.4 Oct 23, 2024
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
8 participants