Skip to content

Rate

An animation's playback rate in frames per minute, or a mission's servicing delay in fractions of a minute.

Playback rate

Specification — Playback rate
Applies to
AnimType
File
art.ini
Section
[<ObjectType ID>]
Value
integer
When omitted
900The wait is one game frame, so the animation advances every game frame.
Parse behavior

Read as frames per minute; -1, the read default, is treated as absent, positive values store TICKS_PER_MINUTE / value as the frame delay, and zero or below stores no delay.

Rate= sets the animation’s playback speed in animation frames per minute of game time. The game converts it to a wait between frames of 900 divided by the rate, rounded down to whole game frames. Rate=900 advances one frame every game frame, and Rate=450 one frame every second game frame.

Because the wait is rounded down, a rate that does not divide 900 evenly plays faster than written. Rate=200 waits four game frames, which plays at 225 frames per minute.

RandomRate, when set, replaces this rate with a random one. Normalized=yes rescales the wait for the game speed.

Mission servicing delay

Specification — Mission servicing delay
Applies to
mission behavior
File
rules.ini
Section
[<Mission name>]
Value
floating point
When omitted
.016
Parse behavior

AARate in the same section falls back to this value when absent or zero.

Rate= sets how often an object on this mission runs the mission’s logic again. The value is a fraction of a minute of game time. The game multiplies it by 900 and drops any fraction to get the interval in game frames, so the default .016 gives 14 frames. The game stores the value with limited precision, so a value meant to land on a whole frame count can come out one frame lower: .030 gives 26 frames, not 27. Many missions add a random 0 to 2 frames to each interval.

Each mission reads its own Rate=, from its section such as [Guard] or [Repair].

rules.ini
[Guard]
Rate=.050 ; 45 frames between passes

Work that a mission counts in passes slows down or speeds up with this setting. The visible case is the armory, whose promotion count advances once per [Repair] pass; see Hospitals and armories.

AARate in the same section is the interval an armed structure on guard uses instead. When AARate is absent or 0, it takes this value.

See also — repair