Howto-Make an advanced timer

Advanced Timer
Step 1
Make a variable and call it temp, make it an actor variable
Step 2
It wil wait for 189 frames then it will initiate the code
- Written by Hblade
Step 1
- Programming the timer
- Code: Select all
int framecount;
void Wait(int f)
{
framecount = framecount + 1;
if (framecount == f)
{
switch(temp)
case 0:
temp = 1;
framecount = 0;
}
}
Make a variable and call it temp, make it an actor variable
Step 2
- Using the timer
- Code: Select all
Wait(189);
if (temp == 1)
{
enter your code
}
It wil wait for 189 frames then it will initiate the code