SetTics
From Eternity Wiki
Jump to navigationJump to search
SetTics(baseamt, rnd, counter)
- baseamt: base amount
- If the counter field is set as constant, baseamt designates the base (non-random) number to set the frame duration to. If counter is set as counter, baseamt designates the counter number (0 to 7) containing the value.
- rnd: randomizer modulus value (0 == not randomized)
- If nonzero and positive, a random number between 0 and rnd - 1 will be added to baseamt when setting the frame duration.
- counter: counter toggle
- Can be one of the following values:
- 0 or constant: baseamt is a direct value
- 1 or counter: baseamt is a counter number containing the useful value
SetTics is a parameterized codepointer to set a thing's calling frame tics (duration) value. It can be used to vary the duration of thing frames dynamically and/or randomly. The duration is set by this range: baseamt to baseamt + rnd - 1. Rnd can be zero to disable the randomness.
Notes[edit]
This is not designed for weapon frames. If you decide to use it anyway, it will change the actor object's (player sprite's) frame duration, instead of changing the weapon frame duration.