♻️REFACTOR: Mejoras en la viabilidad para desarrollo
This commit is contained in:
1 parent
5aba6c7b47
commit
fd0118d964
98 files changed
+5985
-3024
No files matched your search
@@ -2,8 +2,8 @@ extends SceneTree
|
||||
|
||||
const PICKUP_SCENE: PackedScene = preload("res://pickups/pickup.tscn")
|
||||
|
||||
## Full Godot integration test. Requires the real engine and imported SVGs.
|
||||
## Run: godot --headless --path . --script res://tests/test_pickup_runtime.gd
|
||||
## Prueba de integracion en Godot. Requiere el motor real y los SVG importados.
|
||||
## Ejecutar: godot --headless --path . --script res://tests/test_pickup_runtime.gd
|
||||
|
||||
|
||||
func _initialize() -> void:
|
||||
@@ -26,7 +26,7 @@ func _run() -> void:
|
||||
_fail("No se esta ejecutando level_01.gd")
|
||||
return
|
||||
|
||||
# The pre-placed control pickup must work even without any enemy death.
|
||||
# El objeto de control colocado en la escena debe funcionar sin muertes enemigas.
|
||||
var control: Pickup = level.get_node("ControlPickup") as Pickup
|
||||
if control == null or control.pickup_data == null or control.pickup_data.id != &"lab_control":
|
||||
_fail("El pickup de control no se instancio")
|
||||
@@ -41,8 +41,8 @@ func _run() -> void:
|
||||
_fail("Un objeto fijo debe ser recogible desde el primer instante")
|
||||
return
|
||||
|
||||
# Test a real collision, not a direct call to collect_pickup(). This used
|
||||
# to fail when monitoring was disabled while the player ran past the item.
|
||||
# Probar una colision real, no una llamada directa a collect_pickup(). Antes
|
||||
# fallaba al pasar corriendo junto al objeto con la deteccion desactivada.
|
||||
var player: CharacterBody2D = level.get_node("Player") as CharacterBody2D
|
||||
player.global_position = control.global_position
|
||||
await physics_frame
|
||||
@@ -58,8 +58,8 @@ func _run() -> void:
|
||||
_fail("El objeto de control no debe contar entre los 17 drops")
|
||||
return
|
||||
|
||||
# Touch a dropped speed item while the 0.75-second collection delay is
|
||||
# running, then move away as if running through it. It must not be lost.
|
||||
# Tocar un objeto de velocidad durante los 0,75 segundos de espera para
|
||||
# recogerlo y alejarse como al pasar corriendo. No debe perderse la recogida.
|
||||
var base_speed: float = float(player.call("get_move_speed"))
|
||||
var speed_drop: Pickup = PICKUP_SCENE.instantiate() as Pickup
|
||||
speed_drop.pickup_data = load("res://pickups/data/coffee.tres") as PickupData
|
||||
@@ -79,7 +79,7 @@ func _run() -> void:
|
||||
_fail("El Tostado del Averno no ha aumentado la velocidad un 25%%")
|
||||
return
|
||||
|
||||
# The multiplier must affect actual horizontal movement, not just a label.
|
||||
# El multiplicador debe afectar al movimiento real, no solo a una etiqueta.
|
||||
Input.action_press("move_right")
|
||||
await create_timer(0.3).timeout
|
||||
Input.action_release("move_right")
|
||||
@@ -90,8 +90,8 @@ func _run() -> void:
|
||||
player.global_position = Vector2(170, 557)
|
||||
await create_timer(0.15).timeout
|
||||
|
||||
# A full-health heal should stay on the floor, then get collected without
|
||||
# requiring a second body_entered signal when HP decreases in place.
|
||||
# Una cura con la vida llena debe seguir en el suelo y recogerse al perder
|
||||
# vida sin exigir una segunda senal body_entered ni salir del solapamiento.
|
||||
var heal_pickup: Pickup = PICKUP_SCENE.instantiate() as Pickup
|
||||
heal_pickup.pickup_data = load("res://pickups/data/beer.tres") as PickupData
|
||||
heal_pickup.position = player.position
|
||||
@@ -122,8 +122,8 @@ func _run() -> void:
|
||||
return
|
||||
expected_ids[data.id] = true
|
||||
|
||||
# Simulate a missed signal for station 01. The polling of is_dead must
|
||||
# still register its KO and create the guaranteed drop.
|
||||
# Simular la perdida de una senal de la estacion 01. Consultar is_dead debe
|
||||
# permitir registrar la derrota y crear la recompensa garantizada.
|
||||
var lab_callback: Callable = Callable(level, "_on_station_enemy_died")
|
||||
enemies[0].disconnect(&"died", lab_callback)
|
||||
for enemy in enemies:
|
||||
|
||||
Reference in new issue
Block a user