Right I've got an animation class - happy happy joy - and it has an inline function, SetUpdateDelay:
Looks pretty normal; what could go wrong, right? Wrong.Code:void SetUpdateDelay(float delay) { m_UpdateDelay = delay; }
I'm calling this function like so:
If I step through it, CAnimation::m_UpdateDelay does indeed get set to 0.05. When I step through the update function, according to the debugger m_UpdateDelay is back to 250.0f (it's default value).Code:CAnimation explosion; explosion.AddFrame(m_ResourceMgr->GetTexture("./data/Explosion 1.png")); explosion.AddFrame(m_ResourceMgr->GetTexture("./data/Explosion 2.png")); m_Renderer->AddSceneObject("Explosion", explosion, CVector2<int>(100, 100)); explosion.SetUpdateDelay(0.05f);
What the hell am I doing wrong? I'm going to make the default value 0.05 right now and run that... otherwise I'm f'ing stumped.



LinkBack URL
About LinkBacks


