Skip to content

Prevent soft-locking in RPGInterface demo (Fixes #267)#327

Closed
UncertainProd wants to merge 3 commits into
HaxeFlixel:devfrom
UncertainProd:rpg-interface-fix
Closed

Prevent soft-locking in RPGInterface demo (Fixes #267)#327
UncertainProd wants to merge 3 commits into
HaxeFlixel:devfrom
UncertainProd:rpg-interface-fix

Conversation

@UncertainProd

Copy link
Copy Markdown
Contributor

Fix for #267. For some reason, FlxUIPopup does not propagate CLICK_EVENT correctly to the parent state.

@Geokureli

Copy link
Copy Markdown
Member

is this a bug with FlxUIPopup that we should fix, or normal behavior that the demo does not account for?

@UncertainProd

UncertainProd commented Nov 28, 2023

Copy link
Copy Markdown
Contributor Author

Looking at FlxUIPopup, it looks like there's some code that forwards the CLICK_EVENT to the parent state only if one of the eventParams is either "affirm", "cancel" or "alt". But it looks like that never actually happens:
https://github.com/HaxeFlixel/flixel-ui/blob/81dd17d9b2626cb85ffa0be39becb44f8f062d94/flixel/addons/ui/FlxUIPopup.hx#L200

Edit: Searching around flixel-ui for the word "affirm" it looks like the above line is the only place where it's even mentioned so its probably a bug in flixel-ui. I made a PR for it here: HaxeFlixel/flixel-ui#259

@UncertainProd

Copy link
Copy Markdown
Contributor Author

Closing this in favor of HaxeFlixel/flixel-ui#259

@UncertainProd
UncertainProd deleted the rpg-interface-fix branch January 4, 2024 17:37
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