Difference between revisions of "SMOKREF.DAT"

From UFOpaedia
Jump to navigation Jump to search
Line 2: Line 2:
 
400 records of 9 values of one byte each. Total of 3600 bytes.
 
400 records of 9 values of one byte each. Total of 3600 bytes.
  
Smoke always seems to be of the same density in game,
+
There are a total of 12 sprites available for displaying smoke. Any given patch will animate through 4 consecutive sprites. The first sprite is (int)(smokeref[3] / 6 + 8) in [[SMOKE.PCK]].
dispite there being enough graphics for three denisties.
+
 
Need to research more to see if thicker smoke is used -
+
That is to say, if the smoke is due to last for less then six turns, smoke sprites 0 to 3 will be used. If the smoke is due to last less the twelve but more then five turns, sprites 1 to 4 will be used, and so forth.
even a blaster bomb doesn't seem to do the job!
+
 
 +
This allows for nine different densities of displayable smoke. If the smoke is due to last fifty four or more turns, however, then rank badges will be included in the smoke animation. Values higher still will include bullet animations.
  
 
==Structure==
 
==Structure==
'''0:''' X position of smoke/fire.
+
'''0:''' Y position of smoke/fire.
  
'''1:''' Y position of smoke/fire.
+
'''1:''' X position of smoke/fire.
  
 
'''2:''' Z position of smoke/fire.
 
'''2:''' Z position of smoke/fire.
Line 25: Line 26:
 
  2 Smoke
 
  2 Smoke
  
'''7:''' Flags 1 sometimes. Smoke will not render if set to 0.
+
'''7:''' Flags 1 sometimes. Smoke will not render if set to 0. Possibly something to do with smoke spreading around.
  
 
'''8:''' Animation frame offset. Set at random, to break tile pattern in cloud of smoke. Ranges from 0 to 3.
 
'''8:''' Animation frame offset. Set at random, to break tile pattern in cloud of smoke. Ranges from 0 to 3.

Revision as of 03:07, 22 October 2006

General Information

400 records of 9 values of one byte each. Total of 3600 bytes.

There are a total of 12 sprites available for displaying smoke. Any given patch will animate through 4 consecutive sprites. The first sprite is (int)(smokeref[3] / 6 + 8) in SMOKE.PCK.

That is to say, if the smoke is due to last for less then six turns, smoke sprites 0 to 3 will be used. If the smoke is due to last less the twelve but more then five turns, sprites 1 to 4 will be used, and so forth.

This allows for nine different densities of displayable smoke. If the smoke is due to last fifty four or more turns, however, then rank badges will be included in the smoke animation. Values higher still will include bullet animations.

Structure

0: Y position of smoke/fire.

1: X position of smoke/fire.

2: Z position of smoke/fire.

3: Time smoke will last.

4: Time fire will last.

5: Un-used? Never seen it flag.

6: Fire or smoke?

0 Record unused
1 Fire
2 Smoke

7: Flags 1 sometimes. Smoke will not render if set to 0. Possibly something to do with smoke spreading around.

8: Animation frame offset. Set at random, to break tile pattern in cloud of smoke. Ranges from 0 to 3.

See Also