Forest Logo
search
package_2

action

By @luj-s

Roblox

Mirrored

Action is an input window library for Roblox fighting games.

API

new : (Sequence : string, f : () -> (...any), Cooldown : number?, FixedWindowSize : number?, WindowSizeMultiplier : number?) : (Enabled : boolean) -> ()

Creates a new Action, that runs function f when the given keys, separated by Action.SequenceDelimiter, in Sequence get pressed before the given time, with FixedWindowSize or WindowSizeMultiplier, given that [Cooldown] seconds have passed since the Action was triggered. Returns a function that when called enables or disables the Action, based on Enabled.

Configuration

SequenceDelimiter : string

Default: "+"

The string that separates characters in Action Sequences.

Defaults

The below configurations define default values, that get used when not passed as an argument in Action.new.

EnableByDefault : boolean

Default: true

Whether Actions are enabled by default.

DefaultCooldown : number

Default: 0.1

Default time in seconds before the same Action can be triggered again.

DefaultWindowSizeMultiplier : number

Default: 0.05

Default number that gets multiplied by the quantity of keys in an Action's Sequence to define its WindowSize. If you want the WindowSize of an Action not to be based on how many keys its Sequence has, but instead on an arbitrary number, you can pass to Action.new the FixedWindowSize argument, which doesn't have a default value since it's highly dependant for each Action.

Package Details

Install command (Click to copy)


Version

0.1.3

License

GPL-3.0

error

Legal risk for closed-source games

infoStrong copyleft: shipping this in your game plausibly requires releasing your game's entire source under GPL-3.0. Not recommended for closed-source projects.

infoThe package archive does not include its license text; the license is declared in its manifest metadata.

Automated license review — not legal advice.