Skip to content

Fades out and deletes materialize_overlay and secondary_overlay upon skipTurn #2708

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

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

Conversation

nibrandn
Copy link

@nibrandn nibrandn commented Apr 26, 2025

This PR addresses issue #2688, where using Scavenger's Escort Service -> skipTurn left the previewCreature sprites for both Scavenger and the target behind. It can be noted that Scavenger's ghost disappeared when its player generated a new one by hovering over a new move tile during their turn, but the enemy's ghost would not.

Changes:
Added minimal logic in skipTurn() of Game.ts to fade out and replace both materialize_overlay and secondary_overlay with a null value.

Escort.mov

Effect:
Both ghosts disappear upon skipTurn. Shouldn't be any adverse effects, as the game simply generates new materialize_overlay/secondary_overlay whenever previewCreature is called and the value is not found.

Tested on Google Chrome

No need for tokens
#2688

Copy link

vercel bot commented Apr 26, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
ancientbeast ✅ Ready (Inspect) Visit Preview Apr 26, 2025 1:56am

@DreadKnight
Copy link
Member

@nibrandn I've tested this and it works, but I think the best approach is to change the mechanics a bit if possibly (hopefully simplifying stuff while keeping everything more consistent), so that the preview vanishes once the cursor is not over one of the valid targeting location, like in case for movement and movement related abilities (such as Uncle Fungus' Frogger Jump). Let me know what you think 🐻

@nibrandn
Copy link
Author

@DreadKnight That makes sense to me, I just assumed the preview lingering regardless of whether the cursor was hovering or not was a feature for user accessibility. Maybe we could implement it as just another turn for movement, limited to the x and y directions?

@DreadKnight
Copy link
Member

@DreadKnight That makes sense to me, I just assumed the preview lingering regardless of whether the cursor was hovering or not was a feature for user accessibility. Maybe we could implement it as just another turn for movement, limited to the x and y directions?

@nibrandn That was my thought, no lingering, ideally code being reused.

@nibrandn
Copy link
Author

@DreadKnight Do you want me to take a look at that? I'm currently starting my finals season for school, so I'm not sure when I'll have time to dive into it.

@DreadKnight
Copy link
Member

@DreadKnight Do you want me to take a look at that? I'm currently starting my finals season for school, so I'm not sure when I'll have time to dive into it.

Alright, good luck with the finals!
I guess you can poke at it after 🐻

@DreadKnight DreadKnight marked this pull request as draft May 14, 2025 11:15
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.

2 participants