Armazon/scripts/camera_rumble.gd

13 lines
331 B
GDScript

extends Node
signal grab()
signal nuclear_blast()
@onready var rumble: float = 0
@onready var holding: bool = false
func get_mouse_pos() -> Vector3:
var cam: Camera3D = get_viewport().get_camera_3d()
var mousePos: Vector2 = get_viewport().get_mouse_position()
return cam.project_position(mousePos, cam.global_position.z - 1)