2020-03-27 00:54:57 +00:00
|
|
|
package flow
|
|
|
|
|
|
|
|
func (f *Flow) linkBridge() {
|
2020-04-11 00:13:28 +01:00
|
|
|
// FIXME: sometimes these doors are frozen, depending on ship state, but we
|
|
|
|
// don't implement that yet.
|
2020-03-27 00:54:57 +00:00
|
|
|
|
2020-04-11 01:01:05 +01:00
|
|
|
f.onClick(bridge, "2.1", f.setDriver(briefing)) // Mission briefing clickable
|
|
|
|
f.onClick(bridge, "2.2", f.setDriver(choices)) // Options door hotspot
|
|
|
|
f.onClick(bridge, "2.4", f.playNextScenario(bridge)) // Enter combat door hotspot
|
|
|
|
f.setFreeze(bridge, "2.6", true) // TODO: Vehicle configure door hotspot
|
|
|
|
f.onClick(bridge, "2.8", f.setDriver(arrange)) // Squads configure door hotspot
|
2020-03-27 02:07:28 +00:00
|
|
|
|
|
|
|
// link children
|
2020-03-27 02:16:54 +00:00
|
|
|
f.linkBriefing()
|
2020-03-27 02:07:28 +00:00
|
|
|
f.linkChoices()
|
2020-04-11 01:01:05 +01:00
|
|
|
f.linkMainGame()
|
2020-03-27 02:07:28 +00:00
|
|
|
f.linkArrange()
|
|
|
|
}
|
|
|
|
|
2020-03-27 02:16:54 +00:00
|
|
|
func (f *Flow) linkBriefing() {
|
|
|
|
f.onClick(briefing, "3.1", f.setDriver(bridge))
|
|
|
|
}
|
|
|
|
|
2020-03-27 02:07:28 +00:00
|
|
|
func (f *Flow) linkChoices() {
|
|
|
|
f.onClick(choices, "2.1", f.setDriver(loadGame)) // Load another game button
|
|
|
|
f.onClick(choices, "2.2", f.setDriver(saveGame)) // Save this game button
|
|
|
|
f.onClick(choices, "2.3", f.setReturningDriver(choices, options)) // More options button
|
|
|
|
|
|
|
|
// FIXME: wipe out game state when this goes through
|
|
|
|
f.onClick(choices, "2.4", f.setDriver(main)) // Restart button
|
|
|
|
|
|
|
|
f.onClick(choices, "2.5", f.setDriver(credits)) // Credits button
|
|
|
|
f.onClick(choices, "2.6", f.setExit) // Quit button
|
|
|
|
f.onClick(choices, "2.7", f.setDriver(bridge)) // Back button
|
|
|
|
}
|
|
|
|
|
|
|
|
func (f *Flow) linkArrange() {
|
|
|
|
// FIXME: we should be operating on game data in here
|
|
|
|
f.onClick(arrange, "8.1", f.setDriver(bridge)) // Return to bridge ("cathedral")
|
|
|
|
f.onClick(arrange, "8.3", f.setDriver(configureUltEquip)) // Configure squads
|
|
|
|
|
|
|
|
f.linkConfigureUltEquip()
|
|
|
|
}
|
|
|
|
|
|
|
|
func (f *Flow) linkConfigureUltEquip() {
|
|
|
|
// FIXME: we should be modifying loadouts of selected squad members here
|
|
|
|
|
|
|
|
f.onClick(configureUltEquip, "8.1", f.setDriver(bridge)) // Return to bridge
|
2020-03-27 00:54:57 +00:00
|
|
|
}
|