Class Fz2D.Plugins.Touch.TouchControl
| Defined in: | src/plugins/touch/touch_control.coffee |
Overview
Public: Touch Control
Subclasses
Fz2D.Plugins.Touch.TouchControlJoystick, Fz2D.Plugins.Touch.TouchControlJoystickButton
Instance Method Summary
- ::constructor(w, h, config) Constructor.
- ::draw(ctx) Draws touch control on every frame.
- ::moved(touch, input) Fired on move.
- ::pressed(touch, input) Fired on press.
- ::released(touch, input) Fired on release.
- ::update(timer, input) Updates touch control on every frame.
Constructor Details
::constructor(w, h, config) Source
Public: Constructor.
w - width of game
h - height of game
config - configuration hash
Instance Method Details
::draw(ctx) Source
Public: Draws touch control on every frame.
ctx - Fz2D.Canvas
::moved(touch, input) Source
Public: Fired on move.
touch - Hash
input - Fz2D.Input
::pressed(touch, input) Source
Public: Fired on press.
touch - Hash
input - Fz2D.Input
::released(touch, input) Source
Public: Fired on release.
input - Fz2D.Input
::update(timer, input) Source
Public: Updates touch control on every frame.
timer - Fz2D.Timer
input - Fz2D.Input