I am trying to understand Godot Game engine, I am following a tutorial, and I wrote a breakout game. Here is the padding code:
extends KinematicBody2D
func _ready():
set_fixed_process(true)
func _fixed_process(delta):
var y = get_pos().y
var x = get_viewport().get_mouse_pos().x
set_pos(Vector2(x,y))
And I don't understand why I can't use the _fixed_process
function without the set_fixed_process
function, and what is it's use. What does the function do?