rename gauntlet→candy_survival + rewrite Candy Survival per boss design
- Rename enum GAUNTLET→CANDY_SURVIVAL, all gauntlet_*→candy_survival_* - Rename files: gauntlet_manager→candy_survival_manager, candy_cannon→candy_survival_npc, gauntlet.tscn→candy_survival.tscn - Rewrite candy_survival_manager.gd: blueprints, candy stack, Mekton delivery, Sugar Rush, knock/ghost charges, sticky-as-wall - Update player_movement_manager.gd: smack→knock system, ghost integration - All Candy Survival issues (#54-57, #65-70) retitled per boss design - Shared managers (goals_cycle, goal, player_race, playerboard, turn) untouched
This commit is contained in:
@@ -24,7 +24,7 @@ albedo_color = Color(0.4973, 0.6, 0.12599999, 1)
|
||||
material = SubResource("StandardMaterial3D_86fyc")
|
||||
size = Vector2(50, 50)
|
||||
|
||||
[node name="Gauntlet" type="Node3D" unique_id=1063002869]
|
||||
[node name="Candy Survival" type="Node3D" unique_id=1063002869]
|
||||
|
||||
[node name="PlaceholderFloor" type="MeshInstance3D" parent="." unique_id=932640085]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 10, 0, 10)
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
[ext_resource type="FontFile" uid="uid://xnjx058n4tsw" path="res://assets/fonts/Nougat-ExtraBlack.ttf" id="1_font"]
|
||||
|
||||
[node name="GauntletHUD" type="CanvasLayer"]
|
||||
[node name="CandySurvivalHUD" type="CanvasLayer"]
|
||||
layer = 5
|
||||
visible = false
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_scene format=3 uid="uid://ddy2r7xto80gq"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://du7cne5070ia0" path="res://scripts/controllers/candy_cannon_controller.gd" id="1_canon"]
|
||||
[ext_resource type="Script" uid="uid://du7cne5070ia0" path="res://scripts/controllers/candy_survival_npc_controller.gd" id="1_canon"]
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_base"]
|
||||
albedo_color = Color(0.15, 0.15, 0.2, 1)
|
||||
@@ -43,7 +43,7 @@ inner_radius = 0.95
|
||||
outer_radius = 1.15
|
||||
rings = 32
|
||||
|
||||
[node name="CandyCannon" type="Node3D" unique_id=1515964905]
|
||||
[node name="CandySurvivalNPC" type="Node3D" unique_id=1515964905]
|
||||
script = ExtResource("1_canon")
|
||||
|
||||
[node name="Base" type="MeshInstance3D" parent="." unique_id=867716100]
|
||||
+1
-1
@@ -86,7 +86,7 @@ var sng_go_option: OptionButton
|
||||
var sng_stop_option: OptionButton
|
||||
var sng_goals_option: OptionButton
|
||||
|
||||
# Gauntlet settings
|
||||
# Candy Survival settings
|
||||
@onready var players_container = $LobbyPanel/PlayersContainer
|
||||
@onready var players_container2 = $LobbyPanel/PlayersContainer2
|
||||
@onready var player_slots: Array[Control] = []
|
||||
|
||||
+23
-23
@@ -14,7 +14,7 @@ var stop_n_go_manager
|
||||
var stop_n_go_winner_id: int = -1 # Track who finished first in Stop n Go mode
|
||||
var is_match_ended: bool = false
|
||||
var obstacle_manager
|
||||
var gauntlet_manager
|
||||
var candy_survival_manager
|
||||
var vfx_manager
|
||||
|
||||
# Minimal local state
|
||||
@@ -144,9 +144,9 @@ func _apply_arena_background():
|
||||
texture_path = "res://assets/graphics/level_bg/placeholder_classic.jpg" # Fallback texture
|
||||
_instantiate_3d_arena("res://scenes/arena/freemode.tscn")
|
||||
_hide_ground_tiles()
|
||||
"Gauntlet Arena":
|
||||
"Candy Survival Arena":
|
||||
texture_path = "res://assets/graphics/level_bg/placeholder_classic.jpg"
|
||||
_instantiate_3d_arena("res://scenes/arena/gauntlet.tscn")
|
||||
_instantiate_3d_arena("res://scenes/arena/candy_survival.tscn")
|
||||
_hide_ground_tiles()
|
||||
"Classic", _:
|
||||
texture_path = "res://assets/graphics/level_bg/placeholder_classic.jpg"
|
||||
@@ -234,12 +234,12 @@ func _init_managers():
|
||||
# No direct initialize() yet, but we'll call start_game_mode later
|
||||
|
||||
|
||||
# Gauntlet manager for Candy Pump Survival mode
|
||||
if LobbyManager.game_mode == "Candy Pump Survival":
|
||||
gauntlet_manager = load("res://scripts/managers/gauntlet_manager.gd").new()
|
||||
gauntlet_manager.name = "GauntletManager"
|
||||
add_child(gauntlet_manager)
|
||||
gauntlet_manager.initialize(self, $EnhancedGridMap)
|
||||
# Candy Survival manager
|
||||
if LobbyManager.game_mode == "Candy Survival":
|
||||
candy_survival_manager = load("res://scripts/managers/candy_survival_manager.gd").new()
|
||||
candy_survival_manager.name = "CandySurvivalManager"
|
||||
add_child(candy_survival_manager)
|
||||
candy_survival_manager.initialize(self, $EnhancedGridMap)
|
||||
|
||||
# Screen shake manager for impact feedback
|
||||
screen_shake_manager = load("res://scripts/managers/screen_shake.gd").new()
|
||||
@@ -601,8 +601,8 @@ func _setup_host_game():
|
||||
# Spawning and arena setup
|
||||
if LobbyManager.game_mode == "Stop n Go" and stop_n_go_manager:
|
||||
stop_n_go_manager._setup_arena()
|
||||
elif LobbyManager.game_mode == "Candy Pump Survival" and gauntlet_manager:
|
||||
gauntlet_manager._setup_arena()
|
||||
elif LobbyManager.game_mode == "Candy Survival" and candy_survival_manager:
|
||||
candy_survival_manager._setup_arena()
|
||||
else:
|
||||
# Randomize grid first to ensure Floor 0 is walkable for pre-calculation
|
||||
randomize_game_grid()
|
||||
@@ -705,9 +705,9 @@ func _setup_client_game():
|
||||
add_player_character(i, true)
|
||||
print("Client: Pre-spawned potential bot ", i)
|
||||
|
||||
# Initialize arena locally for Candy Pump Survival
|
||||
if LobbyManager.game_mode == "Candy Pump Survival" and gauntlet_manager:
|
||||
gauntlet_manager._apply_arena_setup()
|
||||
# Initialize arena locally for Candy Survival
|
||||
if LobbyManager.game_mode == "Candy Survival" and candy_survival_manager:
|
||||
candy_survival_manager._apply_arena_setup()
|
||||
|
||||
# Ensure local player setup (UI, controls) is verified
|
||||
var player_character = get_node_or_null(str(my_id))
|
||||
@@ -804,13 +804,13 @@ func _start_game():
|
||||
stop_n_go_manager.setup_mission_tiles()
|
||||
stop_n_go_manager.spawn_initial_powerups() # Ensure power-ups exist before 1,2,3 Go
|
||||
|
||||
# Gauntlet: Spawn mission tiles across 20x20 arena BEFORE countdown
|
||||
if LobbyManager.game_mode == "Candy Pump Survival" and gauntlet_manager:
|
||||
gauntlet_manager.setup_mission_tiles()
|
||||
# Candy Survival: Spawn mission tiles BEFORE countdown
|
||||
if LobbyManager.game_mode == "Candy Survival" and candy_survival_manager:
|
||||
candy_survival_manager.setup_mission_tiles()
|
||||
|
||||
# Spawn Static Tektons and random tiles BEFORE countdown (Free Mode Only)
|
||||
# Exclude for Stop n Go and Candy Pump Survival
|
||||
if LobbyManager.game_mode != "Stop n Go" and LobbyManager.game_mode != "Candy Pump Survival":
|
||||
# Exclude for Stop n Go and Candy Survival
|
||||
if LobbyManager.game_mode != "Stop n Go" and LobbyManager.game_mode != "Candy Survival":
|
||||
spawn_static_tektons()
|
||||
|
||||
# STOP N GO: Rotate players to face East BEFORE countdown
|
||||
@@ -838,9 +838,9 @@ func _start_game():
|
||||
if goals_cycle_manager:
|
||||
var match_duration = LobbyManager.get_match_duration()
|
||||
goals_cycle_manager.start_match(float(match_duration), false) # No cycles for Stop n Go
|
||||
elif LobbyManager.game_mode == "Candy Pump Survival":
|
||||
if gauntlet_manager:
|
||||
gauntlet_manager.start_game_mode()
|
||||
elif LobbyManager.game_mode == "Candy Survival":
|
||||
if candy_survival_manager:
|
||||
candy_survival_manager.start_game_mode()
|
||||
|
||||
if goals_cycle_manager:
|
||||
var match_duration = LobbyManager.get_match_duration()
|
||||
@@ -1763,7 +1763,7 @@ func randomize_item_at_position(grid_position: Vector2i):
|
||||
|
||||
if is_ground:
|
||||
var get_mode_specific_tile = func():
|
||||
if LobbyManager.game_mode != "Stop n Go" and LobbyManager.game_mode != "Candy Pump Survival":
|
||||
if LobbyManager.game_mode != "Stop n Go" and LobbyManager.game_mode != "Candy Survival":
|
||||
# 60% Chance for Common (7-10), 40% for PowerUp
|
||||
if randf() <= 0.6:
|
||||
return [7, 8, 9, 10].pick_random()
|
||||
|
||||
+4
-4
@@ -1140,11 +1140,11 @@ func _find_valid_drop_position() -> Vector2i:
|
||||
var item_cell = Vector3i(pos.x, 1, pos.y)
|
||||
if enhanced_gridmap.get_cell_item(item_cell) == -1:
|
||||
if not is_position_occupied(pos):
|
||||
# Gauntlet Mode explicit overrides
|
||||
# Candy Survival explicit overrides
|
||||
var gm = null
|
||||
var main_gauntlet = get_tree().root.get_node_or_null("Main")
|
||||
if main_gauntlet and main_gauntlet.get("gauntlet_manager"):
|
||||
gm = main_gauntlet.gauntlet_manager
|
||||
var main_candy_survival = get_tree().root.get_node_or_null("Main")
|
||||
if main_candy_survival and main_candy_survival.get("candy_survival_manager"):
|
||||
gm = main_candy_survival.candy_survival_manager
|
||||
if gm and gm.is_active:
|
||||
if pos.x == 0 or pos.x == gm.ARENA_COLUMNS - 1 or pos.y == 0 or pos.y == gm.ARENA_ROWS - 1:
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user