FreezingMoon / AncientBeast

The Turn Based Strategy Game/eSport. Master your beasts! 🐺
https://AncientBeast.com
GNU Affero General Public License v3.0
1.67k stars 585 forks source link

bounce the Skip Turn icon [bounty: 6 XTR] #2535

Closed DreadKnight closed 3 months ago

DreadKnight commented 9 months ago

When the active unit is out of actions (there's the "Skip turn" text above it), the right side "Skip Turn" icon should bounce left and right a bit, in similar fashion to hove the unit's health indicator bounces on hover or #1976.

tix980 commented 9 months ago

Hello there, this is such a cool project, I'm new to contributing to open source projects and would like to get involved with this one. Could you assign it to me :)?

DreadKnight commented 9 months ago

Hello there, this is such a cool project, I'm new to contributing to open source projects and would like to get involved with this one. Could you assign it to me :)?

Heya @tix980 ! Glad you like it so far 🥳 I've assigned you to the issue, 2 weeks soft deadline ⏳️ There's a contribution guide in the repo to help get you started 🐻

tix980 commented 9 months ago

Thank you so much :)! I will make sure to read the contribution guide before getting started.

DreadKnight commented 8 months ago

@tix980 Heya! Any progress with this one?

tix980 commented 8 months ago

Hey dreadKnight! I am sorry about the late responses. It is taking longer than I thought, I will try my best to complete it in a week.

JingSiong commented 7 months ago

Hey! Is this issue still available? Can I work on this?

DreadKnight commented 7 months ago

Heya! Yeah, go for it. Will assign once at my desk. 2 weeks soft deadline.

On Sat, Apr 13, 2024, 9:53 PM JingSiong @.***> wrote:

Hey! Is this issue still available? Can I work on this?

— Reply to this email directly, view it on GitHub https://github.com/FreezingMoon/AncientBeast/issues/2535#issuecomment-2053730432, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAEPNX6SGWEVXUVGLDZ6HGTY5F5JTAVCNFSM6AAAAABDDGVPCSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANJTG4ZTANBTGI . You are receiving this because you authored the thread.Message ID: @.***>

prateeksingh19 commented 3 months ago

Hey, how do we like the bounce animation to go on the icon, can someone give me some reference or an idea, so that i can work on it? Maybe we can rotate the glass upside down or something else?

DreadKnight commented 3 months ago

@prateeksingh19 Heya! The rotation sounds cool, but probably a bit problematic given backgrounds and such, not to mention the gravity (sand should be falling), anyway, will keep it in mind for the future.

Right not what we need is having the icon bounce a little horizontally to the left and then get back; then repeat all that.

prateeksingh19 commented 3 months ago

ok, got it. lemme have a look at it, i'll try to do it. thanks

DreadKnight commented 3 months ago

@prateeksingh19 Alright, assigned. 2 weeks soft deadline. This issue is related to #1976 btw, so they could reuse some code.

prateeksingh19 commented 3 months ago

Hi @DreadKnight, added the bounce effect. Can you have a quick look on it and if it's to your liking i'm more than happy to create a PR to close this. Thank You.

https://github.com/user-attachments/assets/95d6c702-39bc-4ebc-ab51-5ea5b1e53bdc

DreadKnight commented 3 months ago

Hi @DreadKnight, added the bounce effect. Can you have a quick look on it and if it's to your liking i'm more than happy to create a PR to close this. Thank You.

https://github.com/user-attachments/assets/95d6c702-39bc-4ebc-ab51-5ea5b1e53bdc

Hello! The bounce is supposed to happen when unit is out of actions, not on icon hover if that's the case in the video as far as I can tell.

prateeksingh19 commented 3 months ago

Ok, got it. Sorry didn't read the issue carefully. So, to be on the same side, we want the bounce of skip button to happen when the unit is out of actions only or also when the skip button is clicked??

DreadKnight commented 3 months ago

Ok, got it. Sorry didn't read the issue carefully. So, to be on the same side, we want the bounce of skip button to happen when the unit is out of actions only or also when the skip button is clicked??

Noticed 😆 Just when out of actions. I think it's bad practice to have buttons move around when under your cursor. I really dislike what Apple does on iOS with all those icons zooming and moving around under your cursor while you're trying to click something, even if it looks rather cool.

prateeksingh19 commented 3 months ago

https://github.com/user-attachments/assets/3c05c109-bf54-4ac9-98fc-841919ae19cf

Is this fine??? At first skip, its manual skip so no bounce as asked but in the second skip, the unit is out of actions. Also, we want the skip button on the right to bounce or the skip button which appears on top of the unit after its out of actions. Sorry, I'm asking too much questions !!!!

DreadKnight commented 3 months ago

https://github.com/user-attachments/assets/3c05c109-bf54-4ac9-98fc-841919ae19cf

Is this fine??? At first skip, its manual skip so no bounce as asked but in the second skip, the unit is out of actions. Also, we want the skip button on the right to bounce or the skip button which appears on top of the unit after its out of actions. Sorry, I'm asking too much questions !!!!

The one from the UI on the right. In the video you didn't allowed too much time for the bouncing to show well. I forgot about the one showing above the unit, might as well deprecated this issue, but will want to test it in practice none the less.

I see the blue Dark Priest moving in the video at super slow speed that's odd.

prateeksingh19 commented 3 months ago

unknown_replay_2024_2.mp4

Is this fine??? At first skip, its manual skip so no bounce as asked but in the second skip, the unit is out of actions. Also, we want the skip button on the right to bounce or the skip button which appears on top of the unit after its out of actions. Sorry, I'm asking too much questions !!!!

The one from the UI on the right. In the video you didn't allowed too much time for the bouncing to show well. I forgot about the one showing above the unit, might as well deprecated this issue, but will want to test it in practice none the less.

I see the blue Dark Priest moving in the video at super slow speed that's odd.

I'll increase the time of the bounce animation, for now it's set to 1s thats why its not visible that much, will increase it to 2-3s. I'll try doing for the icon above the unit as well. if you are sure you want it.

For the moving speed of blue dark priest, i haven't touched any other code than the animation. Also, it seems same to me as the speed in the deployed version of the game.

DreadKnight commented 3 months ago

unknown_replay_2024_2.mp4

Is this fine??? At first skip, its manual skip so no bounce as asked but in the second skip, the unit is out of actions. Also, we want the skip button on the right to bounce or the skip button which appears on top of the unit after its out of actions. Sorry, I'm asking too much questions !!!!

The one from the UI on the right. In the video you didn't allowed too much time for the bouncing to show well. I forgot about the one showing above the unit, might as well deprecated this issue, but will want to test it in practice none the less.

I see the blue Dark Priest moving in the video at super slow speed that's odd.

I'll increase the time of the bounce animation, for now it's set to 1s thats why its not visible that much, will increase it to 2-3s. I'll try doing for the icon above the unit as well. if you are sure you want it.

For the moving speed of blue dark priest, i haven't touched any other code than the animation. Also, it seems same to me as the speed in the deployed version of the game.

The bounce wasn't visible much because it wasn't filmed much. Speed seemed right.

Not sure about bouncing the one above the unit as well atm. Might make different issue later on if needed.

Speed of Dark Priest might be a sifferent issue, will check it against other deployments and compare.

prateeksingh19 commented 3 months ago

Here you go, Video Link. Sorry for the dull screen, there is some issue with my monitor.

DreadKnight commented 3 months ago

Here you go, Video Link. Sorry for the dull screen, there is some issue with my monitor.

Looks ok, will check it out myself after you open a PR with it.

Damn, those units and the tooltipd above units are like in slow motion. What's the refresh rate on your monitor?

prateeksingh19 commented 3 months ago

Ok, will open a PR in some time. for the refresh rate, its 240.

DreadKnight commented 3 months ago

Ok, will open a PR in some time. for the refresh rate, its 240.

Alright, lookin forward to it.

Will check soon if this Phaser 2.x CE version has some issues with that. I think I've seen screwed up movement speeds and such for others as well before.