Skip to content

Conversation

@Geokureli
Copy link
Owner

@Geokureli Geokureli commented Jan 20, 2025

Fixes #8

Adds repeat and waitAndRepeat to FlxControls and FlxAnalogSet

Examples

  • controls.repeat(0.1).SHOOT: Always true when shoot is just pressed, otherwise true every 0.1s when held
  • controls.waitAndRepeat(0.5, 0.1).SHOOT: Always true when shoot is just pressed, otherwise true every 0.1s after being held for 0.5s
  • controls.MOVE.repeat(0.1).right: Always true when just moved to the right, otherwise true every 0.1s when held
  • controls.MOVE.waitAndRepeat(0.5, 0.1).right: Always true just moved to the right, otherwise true every 0.1s after being held for 0.5s

Misc

fixed a bug where FlxDeviceID.ALL analog sticks apparently never worked because of FlxActions ignoring it

@Geokureli Geokureli merged commit 00fbab6 into master Jan 20, 2025
12 checks passed
@Geokureli Geokureli deleted the custom-repeat branch January 20, 2025 15:11
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.

Allow custom holdRepeat settings

2 participants