Playing with Epic's original patches I noticed that the Nalis never seem to teleport away, they are just stuck meditating forever. I vividly remember that eerie teleportation sound from back when I first played Unreal using the software renderer, so I was wondering what's going on. Then I found a someone suggesting that it's related to the framerate. I limited my fps o 30 and whoosh, the Nali teleported right away as I loaded my save. What gives?
I had to find out so I peeked into Nali.uc, and found the Tick function of the FadeOut state:
Code: Select all
function Tick(float DeltaTime)
{
local int NewFatness;
if ( !bFading )
{
NewFatness = fatness + 50 * DeltaTime; // this is the timer for the teleportation
bFading = ( NewFatness > 160 );
}
else if ( Style == STY_Translucent )
{
ScaleGlow -= 3 * DeltaTime;
if ( ScaleGlow < 0.3 )
{
PlaySound(sound'Teleport1',, 2.0);
Destroy();
}
return;
}
else
{
NewFatness = fatness - 100 * DeltaTime;
if ( NewFatness < 80 )
{
bUnlit = true;
ScaleGlow = 2.0;
Style = STY_Translucent;
}
}
fatness = Clamp(NewFatness, 0, 255);
}
E.g. If the game runs as 60 fps then this is going to happen:
Code: Select all
DeltaTime = 1 / 60 = ~0,0167
50 * 0,0167 = 0,8333 which is less than 1
I hope this will be interesting to someone besides me, I just let this out of my system