chore: fix debug warnings

This commit is contained in:
installer
2025-01-22 18:33:23 +01:00
parent 84035f36f4
commit 3ef5356560
4 changed files with 3 additions and 3 deletions

View File

@@ -28,7 +28,6 @@ func _ready() -> void:
for _n in range(4, 15): for _n in range(4, 15):
var star = $Stars/base.duplicate(); var star = $Stars/base.duplicate();
$Stars.add_child(star); $Stars.add_child(star);
star.autoplay = "true";
star.global_position = Vector2( star.global_position = Vector2(
rng.randi_range(0, window_size[0]), rng.randi_range(0, window_size[0]),
rng.randi_range(0, window_size[1]), rng.randi_range(0, window_size[1]),

View File

@@ -29,6 +29,7 @@ func _process(delta) -> void:
func _on_body_entered(_body: Node2D) -> void: func _on_body_entered(_body: Node2D) -> void:
if can_collide: if can_collide:
collision.emit(); collision.emit();
queue_free();
func _on_area_entered(area: Area2D) -> void: func _on_area_entered(area: Area2D) -> void:
area.queue_free(); area.queue_free();

View File

@@ -5,7 +5,7 @@ extends CharacterBody2D
var cooldown := 0.0; var cooldown := 0.0;
var last_direction := Vector2(0., 0.); var last_direction := Vector2(0., 0.);
@export var last_direction_coef := 1.2; @export var last_direction_coef := 2;
@export var max_last_direction := -1.5; @export var max_last_direction := -1.5;
signal laser(pos: Vector2); signal laser(pos: Vector2);

View File

@@ -34,7 +34,7 @@ func _on_score_timer_timeout() -> void:
else: else:
Global.meteor_base_timer -= 0.05; Global.meteor_base_timer -= 0.05;
Global.score += 1; Global.score += 1;
if Global.score / 50 > Global.ship_level: if int(Global.score / 50.0) > Global.ship_level:
Global.ship_level += 1; Global.ship_level += 1;
if Global.ship_level % 2 == 0: if Global.ship_level % 2 == 0:
Global.player_base_speed += 50; Global.player_base_speed += 50;