forked from nova/jmonkey-test
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
531 B
20 lines
531 B
package com.jme3
|
|
|
|
import com.jme3.input.controls.InputListener
|
|
import com.jme3.input.controls.Trigger
|
|
|
|
/**
|
|
* Created by Brandon Barker on 6/21/17.
|
|
*/
|
|
package object input {
|
|
|
|
implicit final class InputManagerWrap(private val uval: InputManager)
|
|
extends AnyVal {
|
|
def addMapping(action: Action, triggers: Trigger*): Unit =
|
|
uval.addMapping(action.name, triggers: _*)
|
|
def addListener(listener: InputListener, actions: Action*): Unit =
|
|
uval.addListener(listener, actions.map(act => act.name): _*)
|
|
|
|
}
|
|
|
|
}
|