gamepad input on every menu (i think)
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# @install: lix --silent download "gh://github.com/kiss-lang/kiss-flixel#6bfcf84328e5ced6dfc92cf140a97326cc592208" into kiss-flixel/0.0.0/github/6bfcf84328e5ced6dfc92cf140a97326cc592208
|
||||
# @install: lix --silent download "gh://github.com/kiss-lang/kiss-flixel#bc5213d4d3335f46c0a83aba05f1ecb4be6bf4e0" into kiss-flixel/0.0.0/github/bc5213d4d3335f46c0a83aba05f1ecb4be6bf4e0
|
||||
-lib flixel
|
||||
-lib flixel-addons
|
||||
-lib flixel-ui
|
||||
@@ -6,5 +6,5 @@
|
||||
-lib kiss-tools
|
||||
-lib lime
|
||||
-lib openfl
|
||||
-cp ${HAXE_LIBCACHE}/kiss-flixel/0.0.0/github/6bfcf84328e5ced6dfc92cf140a97326cc592208/src/
|
||||
-cp ${HAXE_LIBCACHE}/kiss-flixel/0.0.0/github/bc5213d4d3335f46c0a83aba05f1ecb4be6bf4e0/src/
|
||||
-D kiss-flixel=0.0.0
|
||||
@@ -32,7 +32,7 @@ import kiss_flixel.SimpleWindow;
|
||||
import kiss_flixel.DebugLayer;
|
||||
import haxe.ds.Option;
|
||||
import kiss_tools.KeyShortcutHandler;
|
||||
import kiss_tools.FlxKeyShortcutHandler;
|
||||
import kiss_flixel.FlxKeyShortcutHandler;
|
||||
using flixel.util.FlxSpriteUtil;
|
||||
import openfl.display.BitmapData;
|
||||
import openfl.display.BitmapDataChannel;
|
||||
|
||||
@@ -108,8 +108,9 @@
|
||||
(resume)
|
||||
}]
|
||||
|
||||
(set pauseMenu (new SimpleWindow "HISTORY" FlxColor.BLACK FlxColor.WHITE 0.6 0.9 true null null null ->:Void (_resume null)))
|
||||
(pauseMenu.enableVerticalScrolling "up" "down")
|
||||
(set pauseMenu (new SimpleWindow "HISTORY" FlxColor.BLACK FlxColor.WHITE 0.6 0.9 true null null null "up" "down" ->:Void (_resume null)))
|
||||
(pauseMenu.enableVerticalScrolling)
|
||||
(pauseMenu.enableGamepadInput true)
|
||||
(pauseMenu.makeText "")
|
||||
(doFor element history
|
||||
(case element
|
||||
@@ -209,7 +210,11 @@
|
||||
true
|
||||
""
|
||||
"left"
|
||||
"right")))
|
||||
"right"
|
||||
"up"
|
||||
"down"
|
||||
"enter"))
|
||||
(pauseMenu.enableGamepadInput true))
|
||||
|
||||
(method :Void enterString [:String prompt :String->Void submit]
|
||||
(set pauseMenu
|
||||
|
||||
@@ -11,7 +11,7 @@ import hollywoo.Director;
|
||||
import hollywoo.Movie;
|
||||
import hollywoo_flixel.ActorFlxSprite;
|
||||
import kiss_flixel.SpriteTools;
|
||||
import kiss_tools.FlxKeyShortcutHandler;
|
||||
import kiss_flixel.FlxKeyShortcutHandler;
|
||||
import kiss_tools.JsonMap;
|
||||
import hollywoo.HFloat;
|
||||
import openfl.Assets;
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
(callPrivate tween "update" tweenElapsed)
|
||||
(when tween.finished
|
||||
(callPrivate tween "finish")))))
|
||||
(.update (cast (director.shortcutHandler) kiss_tools.FlxKeyShortcutHandler<Dynamic>)))
|
||||
(.update (cast (director.shortcutHandler) kiss_flixel.FlxKeyShortcutHandler<Dynamic>)))
|
||||
|
||||
(prop &mut :FlxSprite _canvas null)
|
||||
(method :FlxSprite canvas []
|
||||
@@ -182,6 +182,9 @@
|
||||
(dictSet presetPositions (pos.stringify) true)))
|
||||
|
||||
(preload
|
||||
(.enableGamepadInput
|
||||
(cast (director.shortcutHandler) kiss_flixel.FlxKeyShortcutHandler<Dynamic>)
|
||||
[=>flixel.input.gamepad.FlxGamepadInputID.START "escape"])
|
||||
(set FlxDirector.anonProps 0)
|
||||
(set FlxG.sound.volume FlxDirector.masterVolume)
|
||||
(unless uiCamera
|
||||
|
||||
Reference in New Issue
Block a user