Inspired from Atesquik controls for PTP by atesquik, it's a bunch of mobile controls for GMS2
(also if you're gonna use this credit me somewhere, doesn't have to be in big text but still somewhere)
- Import YYMPS
- Add
obj_kenancontrolsto the first room in your game - Read documentation
kcon_add_element("element_id_here", new KConElementHere(...params...));kcon_save()
kcon_load()kcon_get("element_id_here")KConButton (_sprite: Sprite, _x: Real, _y: Real, _action: Function, _angle: Real, _vkey: KeyboardKey, _hold: Boolean)
Additional comments:
- _hold defines if it will call
_actionfor every frame the key is pressed, or if it will only run_actionon the frame it gets held down