Game Development Community

RESOLVED Light AnimationPeriod Reversed!

by Steve Acaster · in Torque 3D Professional · 02/12/2010 (6:08 pm) · 6 replies

Not a bug I guess so posted for information purposes. Whilst porting, I was initially baffled as to why my animated lights were attempting to induce epileptic seizures and this is why: The "meaning" of a lightObject's AnimationPeriod has changed.

In 1.0.1, AnimationPeriod was the number in seconds it took the animation to loop.
eg: set to 3, it takes 3 seconds to play the full animation.

In 1.1b, AnimationPeriod is the animation loop set at 1.0.
eg: set it to 3, it plays 3 times in one second.

So for the original setting of 1 animation loop in 3 seconds, the 1.1b setting wants to be 0.33, or you'll get a surprise when you fall off your chair foaming at the mouth...

=============================================

On an unrelated note:

Whoever changed gfxDrawUtil and dispensed with the services of perp.set and perp.normalize to control the thick ribbon which was eventually drawn on-screen - The new method is infinitely superior.
"May choirs of heavenly angels carry you to your rest, M'lady!" ... though you're probably a dude...

RESOLVED IN 1.1BETA2

#1
02/12/2010 (8:19 pm)
Aha, thanks for pointing this out. I was actually rather confused as to why it was behaving like this (epileptic disco light show ftw!), since period in mathematics is how long it takes for a function to return to it's initial state or when it repeats, so the word AnimationPeriod seems a bit misleading if it means how many times in a second it repeats. Perhaps AnimationPhase would be a better name for it as it currently behaves, or changing it to actually behave like it's namesake.
#2
02/13/2010 (2:28 am)
It should be animationFrequency in that case and i think that would be a bug.

I guess it somehow slipped through their new QA department they announced before. ;)
#3
02/13/2010 (10:31 am)
lol @ mathematical semantics!
#4
02/13/2010 (3:07 pm)
@Sean: Ah yes, you are correct. Either way the current implementation of animationPeriod should be looked at and either the name changed or the functionality changed.
#5
02/13/2010 (11:11 pm)
Sounds like a bug to me... it should be easy fix. THREED-877

Thanks for all these great bug reports Steve!

#6
04/12/2010 (3:42 pm)
Fixed for 1.1 beta 2... note this means your light animation times will need to be adjusted.