Skip to content

AlphaImage

A shape file that brightens or darkens the map around the object.

Object light shape

Specification — Object light shape
Applies to
ObjectType and derived types
AircraftTypeBuildingTypeBulletTypeInfantryTypeOverlayTypeParticleSystemTypeParticleTypeSmudgeTypeTerrainTypeUnitTypeVoxelAnimType
File
rules.ini
Section
[<ObjectType ID>]
Value
string
When omitted
(empty)No light shape is loaded and the object contributes nothing to the lighting pass.

AlphaImage= names a shape that lights the map around each object of the type. The value is a filename without its extension: the engine loads <value>.SHP when it reads the type. A type that never names a shape gets no light, and an empty value in a later file does not remove a shape that an earlier file named. Unlike the object’s own artwork, the shape is named here directly and not through the Image ID.

rules.ini
[MYLAMP] ; a BuildingType
AlphaImage=MYGLOW ; MYGLOW.SHP lights the ground around the lamp

The shape is centered on the object and changes the brightness of everything drawn under it. Each pixel’s palette index sets the change at that spot: 127 leaves the brightness as it is, higher indexes brighten and lower ones darken.

The light is placed when the object enters the map, and removed when the object leaves it by being destroyed, sold, or loaded into a transport. The light is also removed when the object is captured or starts to cloak. An object that comes back onto the map gets a new light at its new position, and that is the only way a removed light returns.

An overlay or a smudge never gets a light, because it becomes part of its cell as it is placed.

Animation light shape

Specification — Animation light shape
Applies to
AnimType
File
art.ini
Section
[<ObjectType ID>]
Value
string
When omitted
(empty)No light shape is loaded and the animation contributes nothing to the lighting pass.

An animation’s light shape is named and drawn the same way as any other object type’s. The light is placed where the animation starts, and it stays there if the animation moves.

See also — Image