1
0
Fork 0
mirror of https://github.com/ninjamuffin99/Funkin.git synced 2024-11-08 15:56:04 +00:00
Funkin/source/PauseSubState.hx
2020-10-26 02:16:05 -07:00

36 lines
691 B
Haxe

package;
import Controls.Control;
import flixel.FlxG;
import flixel.FlxSprite;
import flixel.FlxSubState;
import flixel.input.keyboard.FlxKey;
import flixel.util.FlxColor;
class PauseSubState extends FlxSubState
{
public function new()
{
super();
var bg:FlxSprite = new FlxSprite().makeGraphic(FlxG.width, FlxG.height, FlxColor.BLACK);
bg.alpha = 0.6;
bg.scrollFactor.set();
add(bg);
bg.cameras = [FlxG.cameras.list[1]];
}
override function update(elapsed:Float)
{
super.update(elapsed);
if (FlxG.keys.justPressed.J)
{
PlayerSettings.player1.controls.replaceBinding(Control.LEFT, Keys, FlxKey.J, null);
}
if (FlxG.keys.justPressed.ENTER)
close();
}
}