i try to create an airplane shooting bullet at my mouse direction, i try to fix the issue but i clueless, Any help would be appreciated. Attached image is script for the main code.
here is the code for the bullet script:
extends CharacterBody2D
var speed = 300
var velocityy = Vector2(0,1)
func _physics_process(delta):
var collision_info = move_and_collide(velocityy.normalized() * delta * speed)
will do
because it looks like your script is attached to the CharacterBody2D of the bullet scene you have, but the CharacterBody2D is the child of the scene node, so you will need to get it like that