Hmm... It seems like it's not copying (hard linking) the *.001 file.
For now, you can just copy this from the Compiled folder to Compiled/Windows. I'm on it.


This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.
Show posts Menubool ModeWalk, ModeRun;
int tiredness, time = -1; // time that detain the player is not moving
function Update_Runtoolbar()
{
if (ModeRun && player.Moving) // running
{
tiredness += 1;
if (tiredness >= 30 && gRunToolbar.BackgroundGraphic == 56) gRunGraphic.BackgroundGraphic = 57; // start growing
// etc etc
}
else // !ModeRun || !player.Moving
{
if (!player.Moving && tiredness >= 10) // should mean that he was running before...
{
time += 1;
if (time >= 40) // presumably this is called once per game loop, default 40 loops per second, this will happen after 1 second of player not moving while being tired
{
int time_recover = 0;
while (time_recover <= 30) // this is a tight loop, should run in under 1 game loop
{
time_recover ++; // start recover energy
// here is the problem, too much quickly change graphic.
// i tried lately here to put a SetTimer... but with no lucky at all
// note that the check occurs 30 times, but within a single game loop
// also note that there is no SetTimer call in this code snippet
if (gRunToolbar.BackgroundGraphic == 57 && IsTimerExpired(1)) // i though a timer was the ideal here
// but doesn't work...
{ gRunToolbar.BackgroundGraphic = 56; } // go back the graphic for recover
// etc etc
tiredness -= 1; // tiredness is always decreased by 31 each game loop (0..30, inclusive)
}
// note that unless tiredness was at least 60, this will always be true
if (tiredness < 29) time = 0; // note lack of braces means that only resetting the time variable depends on tiredness variable
// note that resetting the local variable time_recover is redundant -- it only exists within this scope which is ending
time_recover = 0; // send everything to back
// also note that tiredness is not reset; if player's tiredness was only 10, they may actually gain an energy boost just by stopping for 1 second
}
}
}
}
function game_start()
{
Game.SetSaveGameDirectory("$MYDOCS$/YourGameName");
}
By continuing to use this site you agree to the use of cookies. Please visit this page to see exactly how we use these.
Page created in 1.953 seconds with 15 queries.