Skip to content

Translucency

How faded an animation or a particle is drawn, as a percentage, at the detail settings that honor it.

Animation fade

Specification — Animation fade
Applies to
AnimType
File
art.ini
Section
[<ObjectType ID>]
Value
integer
When omitted
0

Only three values fade the animation: 25 draws it a quarter faded, 50 half faded and 75 three quarters faded. Any other value above 0, such as 76, draws it solid. 0 or a negative value sets no fade.

The value is ignored while Translucent=yes, which fades the animation by stage instead.

The fade applies only at the detail settings that TranslucencyDetailLevel allows.

For an animation that a structure runs, a value above 0 replaces the structure’s fade while the structure cloaks and uncloaks, so the animation keeps its own level throughout. An animation that sets no fade follows the structure instead: a quarter faded as the cloak begins, then half faded.

Once the structure has cloaked completely, an animation with a value above 0 is no longer drawn. This holds even for a player who can still see the structure faintly, such as its owner. An animation that sets no fade stays half faded for that player, and disappears only for a player from whom the structure is hidden.

art.ini
[MYBANG16] ; a blast ring, drawn half faded at any detail setting
Image=MYBANG16
Translucency=50
UseNormalLight=yes
Report=EXPNEW11

Particle fade

Specification — Particle fade
Applies to
ParticleType
File
rules.ini
Section
[<ObjectType ID>]
Value
integer
When omitted
0

Translucency sets how faded a particle of this type is when it is created. The game draws only three fade levels, and the value must land on one of them:

ValueParticle is drawn
25a quarter faded
50half faded
75 through 127three quarters faded
any other value, including 0solid

Each particle keeps its level in one signed byte, so the value wraps around every 256. 128 through 255 wrap below zero and draw solid, while 281 acts as 25 and 306 as 50.

Fading is drawn only at the High detail setting. At Medium detail every particle is drawn solid. At Low detail, Smoke and Spark particles are not drawn at all and the rest are drawn solid.

Spark and Railgun particles are drawn as single pixels with no artwork, and they ignore this setting.

The level can change after the particle is created:

  • A Fire particle switches to 25 when its animation state reaches Translucent25State, and to 50 when it reaches Translucent50State.
  • A smoke system adds 25 to each particle it emits once its spawn interval has grown past SpawnTranslucencyCutoff.
  • When a smoke system replaces an expiring particle with its NextParticle pair, each successor starts at its parent’s current level and ignores its own type’s Translucency. Five times in six, 25 is added to that level.

Those steps can push a level past 127. It then wraps, and the particle is drawn solid again. A particle that starts at 25 wraps after five generations of successors that each add a step.

rules.ini
[MYSMOKEPUFF] ; a ParticleType registered in [Particles]
Image=SGRYSMK1
BehavesLike=Smoke
Translucency=25 ; a quarter faded when created
MaxEC=80
EndStateAI=20