Skip to content

guide_timer

Source: base/tealdef/mission/guide_system/guides/guide_timer.d.tl

Notes

Guide task triggered after a delay that depends on its importance.

GuideTimer

record global base/tealdef/mission/guide_system/guides/guide_timer.d.tl:3

global record GuideTimer is MissionInterface.TaskScript<GuideTimer.State, GuideTimer.Params>

Load: local guide_timer = ug_require "::/mission/guide_system/guides/guide_timer.tl"

Notes

Guide task triggered after a delay given by its importance, when no other guide is pending and the last task completed at least a minute ago. Completes early when a listed construction is proposed or shouldSkipGuide returns true.

GuideTimer.Importance

enum base/tealdef/mission/guide_system/guides/guide_timer.d.tl:4

enum Importance

Notes

Delay class of a timer guide.

Used in the base game: 1 time in 1 file

base/content/mission/mission/guide_system/guides/guide_timer.tl:22

local importanceDelays<total> : {GuideTimer.Importance : Delay} = {

Value Description
"Now" No delay.
"VeryHigh" 1 minute after spawn.
"High" 5 minutes after spawn.
"Medium" 15 minutes after spawn.
"Low" 1.5 hours after spawn.

GuideTimer.Params

record base/tealdef/mission/guide_system/guides/guide_timer.d.tl:12

record Params

Notes

Params of a timer guide.

Used in the base game: 9 times in 3 files

base/content/mission/mission/guide_system/guides/guide_timer.tl:2

local type P = GuideTimer.Params
base/content/mission/mission/guide_system/main/guide_system_story.tl:27
} as GuideTimer.Params,
mods/release/urbangames_campaign_mission_07/content/guide_system/guide_system/guide_system_story.tl:10
} as GuideTimer.Params,

Fields

Name Type Description
importance Importance Delay class (GUI time).
constructionFileCandidates {ResName : boolean} Construction or model files; proposing one of them completes the guide (the player already knows how).

Functions

shouldSkipGuide(state : MissionInterface.TaskContext<State, Params>) : boolean base/tealdef/mission/guide_system/guides/guide_timer.d.tl:15

Notes

Completes the guide without showing it when it returns true.

Parameter Type Description
state MissionInterface.TaskContext<State, Params> Context of the guide task.

Returns boolean: true to skip the guide.

GuideTimer.State

record base/tealdef/mission/guide_system/guides/guide_timer.d.tl:17

record State is IGuideState

Notes

Guide state.

Used in the base game: 2 times in 2 files

base/content/mission/mission/guide_system/guides/guide_timer.tl:1

local type S = GuideTimer.State
base/content/mission/mission/guide_system/main/guide_system_story.tl:41
shouldSkipGuide = function(_ctx : MissionInterface.TaskContext<GuideTimer.State, GuideTimer.Params>) : boolean