Improved outline shader

This commit is contained in:
2024-01-17 21:48:35 +01:00
parent 6934f2936b
commit 7eba25c83b
8 changed files with 200 additions and 54 deletions

View File

@ -2,15 +2,18 @@ extends Camera3D
@export var center: Node3D
@export var follow_speed: float
@export var shake_strength: float
var noise = FastNoiseLite.new()
func _ready():
Global.camera = self
func _process(delta):
if Global.player == null:
return
center.position = lerp(center.position, Global.player.position, follow_speed * delta)
# @export var shake_strength: float
# var noise = FastNoiseLite.new()
# func shake(time):
# var trauma_sq := 1.0
# var h_offset := noise.get_noise_2d(time, 0) * trauma_sq * shake_strength