also allow for rotation
This commit is contained in:
parent
2eb79e9840
commit
f9a4d8ad6b
|
@ -43,7 +43,7 @@ func _on_action_value(event: EventAction):
|
||||||
if event.name != "primary"||event.initiator != initiator:
|
if event.name != "primary"||event.initiator != initiator:
|
||||||
return
|
return
|
||||||
|
|
||||||
relative_transform = relative_transform.translated(Vector3(0, 0, -event.value.y * 0.05))
|
relative_transform = relative_transform.translated(Vector3(0, 0, -event.value.y * 0.05)).rotated_local(Vector3(0, 1, 0), event.value.x * 0.05)
|
||||||
|
|
||||||
func _on_grab_down(event: EventPointer):
|
func _on_grab_down(event: EventPointer):
|
||||||
if disabled:
|
if disabled:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user