2023-11-28 00:46:05 +02:00
|
|
|
extends RefCounted
|
2023-11-27 01:23:19 +02:00
|
|
|
|
|
|
|
enum Type {
|
|
|
|
CONTROLLER_LEFT,
|
|
|
|
CONTROLLER_RIGHT,
|
|
|
|
HAND_LEFT,
|
|
|
|
HAND_RIGHT,
|
|
|
|
}
|
|
|
|
|
|
|
|
enum EventType {
|
|
|
|
GRIP,
|
|
|
|
TRIGGER,
|
|
|
|
}
|
|
|
|
|
|
|
|
signal on_press(type: EventType)
|
|
|
|
signal on_release(type: EventType)
|
|
|
|
|
|
|
|
var node: Node3D
|
|
|
|
var type: Type
|
|
|
|
|
|
|
|
func is_right() -> bool:
|
|
|
|
return type == Type.CONTROLLER_RIGHT || type == Type.HAND_RIGHT
|