Skip to content

DemandLoad

Changed in 0.3.0

Loads a type's artwork when each scenario starts, from a loose file or any archive.

Structure shape

Specification — Structure shape
Applies to
BuildingType
File
art.ini
Section
[<Image ID>]Image ID: Image= value; ObjectType ID when omitted
Value
boolean
When omitted
no

With DemandLoad=yes, a structure type’s main shape is loaded when a scenario starts or a saved game is loaded, rather than with the rules, and stays loaded until the next scenario or saved game is loaded. The file is the main-shape filename, resolved for the scenario theater, and can be loose or in any archive. A shape the game cannot find is not drawn.

The flag covers only the main shape. The construction animation has its own setting, DemandLoadBuildup. The deploying, door, under-door, bib and special Z overlay shapes are always loaded with the rules.

Animation demand loading

Specification — Animation demand loading
Applies to
AnimType
File
art.ini
Section
[<ObjectType ID>]
Value
boolean
When omitted
no

The animation’s shape file is loaded when a scenario starts or a saved game is loaded, rather than with the rest of the art, and stays loaded until the next scenario or saved game is loaded. The file can be loose or in any archive. Art that is not demand-loaded is read only from cached archives.

From the shape, the type takes its largest frame, on which a Crater, Scorch or Flamer animation acts. An End that is omitted, 0 or -1 plays the shape’s frame count. Every player in a network game loads the shape at the same point, so all of them use the same values. When the file is missing, the largest frame is frame 0, such an End counts zero stages, and the animation draws nothing.

The file name is the Image ID with a .SHP extension, or the AnimType ID when no image is set. Theater=yes uses the AnimType ID with the theater’s extension instead, and NewTheater=yes adjusts the ordinary name for the theater.

Overlay shape

Specification — Overlay shape
Applies to
OverlayType
File
art.ini
Section
[<Image ID>]Image ID: Image= value; ObjectType ID when omitted
Value
boolean
When omitted
no
art.ini
[BTIB01]
DemandLoad=yes

With DemandLoad=yes, the overlay’s shape is loaded when a scenario starts or a saved game is loaded, rather than with the rest of the rules, and stays loaded until the next scenario or saved game is loaded. The file can be loose or in any archive.

A demand-loaded shape is a separate copy for each overlay type. Two overlay types with the same Image ID each load their own copy.

The file name is formed the same way as for any overlay. An ordinary overlay loads its Image ID with a .SHP extension. Theater=yes uses the theater’s extension instead, and NewTheater=yes rewrites the .SHP name for the theater.

History

  1. Changed0.2.0Release candidate

    Keep demand-loaded artwork under its owner's lifetime — buildingtype

  2. Changed0.2.0Release candidate

    Keep demand-loaded artwork under its owner's lifetime — animtype

  3. Changed0.2.0Release candidate

    Keep demand-loaded artwork under its owner's lifetime — overlaytype

  4. Changed0.3.0In development

    Load uncached art when each scenario starts — animtype

  5. Changed0.3.0In development

    Load uncached art when each scenario starts — buildingtype

  6. Changed0.3.0In development

    Load uncached art when each scenario starts — overlaytype