How jglasse/zd works
Zylon Defenders is an iOS space-combat game inspired by Star Raiders: players configure a run, navigate a galaxy, and defend Zylon stations in real-time ship combat. The main game controller coordinates the SceneKit game loop and galaxy updates; separate modules represent the map, ships, weapons, and controls. The README also describes Kohai’s spoken commentary and a MultiPeer companion controller. Some subsystems are documented but their wiring is not shown in the excerpts, so those links are omitted or marked unverified.
Main entry points: ZylonGameViewController.swift Game Controller · GalaxyMapModel.swift Galaxy State · SectorObject.swift Sector Objects · MainMenuViewController.swift Main Menu
Components 21
Menus and Navigation
Galaxy and Sectors
- Galaxy State
zylons/GalaxyMapModel.swift - Sector State
zylons/SectorGrid.swift - Classic Map
zylons/ClassicMap.swift - Galaxy Display
zylons/GalaxyMapDisplay.swift - Map Blips
zylons/GalaxyBlip.swift
Ship Combat
- Game Controller
zylons/ZylonGameViewController.swift - Player Ship
zylons/ZylonShip.swift - Humon Ships
zylons/HumonShip.swift - Zylon Stations
zylons/ZylonStation.swift - Torpedoes
zylons/Torpedo.swift - Sector Objects
zylons/SectorObject.swift
Controls and Feedback
- Scanner
zylons/Scanner.swift - Joystick
zylons/JoyStickView.swift - HUD
zylons/HUD.swift - Kohai Copilot
zylons/Kohai.swift - Sound Playback
zylons/SoundEngine.swift
Companion Control
- Helm Controller
helm/MCController.swift
Other components
- Player
- Second Device
Connections 23
- Player → Main Menu: opens
README.md - Main Menu → Game Controller: presents
zylons/MainMenuViewController.swift - Player → Joystick: steers
README.md - Game Controller → Galaxy State: updates troops
zylons/ZylonGameViewController.swift - Galaxy State → Sector State: stores sectors
zylons/GalaxyMapModel.swift - Classic Map → Galaxy State: renders map
zylons/ClassicMap.swift - Galaxy Display → Galaxy State: reads state
zylons/GalaxyMapDisplay.swift - Galaxy Display → Map Blips: uses blips
zylons/GalaxyMapDisplay.swift - Game Controller → Humon Ships: coordinates combat
zylons/ZylonGameViewController.swift - Game Controller → Player Ship: coordinates combat
zylons/ZylonGameViewController.swift - Game Controller → Zylon Stations: manages stations
zylons/ZylonGameViewController.swift - Humon Ships → Torpedoes: fires
zylons/HumonShip.swift - Humon Ships → Sector Objects: inherits
zylons/HumonShip.swift - Player Ship → Sector Objects: inherits
zylons/ZylonShip.swift - Torpedoes → Sector Objects: inherits
zylons/Torpedo.swift - Scanner → Sector Objects: scans
zylons/Scanner.swift - Game Controller → Joystick: accepts input
zylons/ZylonGameViewController.swift - Game Controller → HUD: updates display
zylons/HUD.swift - Game Controller → Kohai Copilot: uses copilot
README.md - Kohai Copilot → Sound Playback: plays commentary
- Second Device → Helm Controller: sends controls
README.md - Helm Controller → Game Controller: remotely controls
README.md - Main Menu → Prologue: offers prologue
README.md