1.6 KiB
1.6 KiB
System Conventions
Battle
- Fighters live in
BATTLE.fighterMap: Dictionary[BattlePosition, BattleFighter] BattleFighteris pure data (no Node);BattleFighterSceneis the 3D visual- Battle flow is driven by
BattleCutsceneAction.playerDecisionCallablewhich loops viaCUTSCENE_ADD_END - New moves → add static preset in battle/fighter/BattleMove.gd, add
perform()logic in battle/action/BattleMove.gd
Entities (Overworld)
See Overworld for the full reference (scene structure, interaction types, camera, map transitions).
- All interactable world objects extend
Entity(CharacterBody3D) - Interaction type set via
@export var interactType:InteractType - Interaction routing lives in
EntityInteractableArea.onInteract()— add newInteractTypevalues there - NPC conversation entities: set
interactType = CONVERSATION, assigndialogueResource(a.dialoguefile) anddialogueTitle(section to start from, default"start")
Items
- Register new items in item/Item.gd — add to
Idenum and callitemDefine() - Item ID order in the enum must match insertion order into
ITEM_DATA
UI
See UI for the full reference (VNTextbox, ClosableMenu, pause/debug/settings menus, AdvancedRichText, adding new menus).
UI.TEXTBOX.setTextAndWait(text)— show dialogue and await player dismiss (useawait)- Movement is blocked automatically when
UI.TEXTBOXis visible (EntityMovement._canMove()checks this) - Menus extend
ClosableMenufor open/close/toggle +closed/openedsignals