Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SetPlayerActive(false) Help!
SilentStriker Offline
Posting Freak

Posts: 950
Threads: 26
Joined: Jul 2011
Reputation: 43
#4
RE: SetPlayerActive(false) Help!

(06-08-2012, 04:45 PM)P44RTHURN4X Wrote: Hmm, that's weird...

Why does you have no names in your timer? for example:

SetPlayerActive(false);
AddTimer("game_timer", 10.0f, "freeze_end");
SetPlayerActive(true);

1. You have to put 10.0f not 10 in the timer
2. you have to continue the timer, for example:

void Freeze(string &in asParent, string &in asChild, int alState)

{

SetPlayerActive(false);

AddTimer("game_timer", 10.0f, "freeze_end");

}

void freeze_end(string &in asTimer)
{
SetPlayerActive(true);
}

Try this and then tell me what happens then...



GReeZe' P44
1. He doesn't need to write 10.0f he can just write 10 the f is only used when you use the like 0.342f or 1.53f if it's a number that doesn't have decimals it's not needed to have a f

the first part of a timer, the one you call game_timer is only necessary if you need to stop the timer with RemoveTimer(""); if you don't need to remove the timer the name of the timer is not necessary. But it need to call a function for example freeze_end

06-08-2012, 07:25 PM
Find


Messages In This Thread
SetPlayerActive(false) Help! - by MaZiCUT - 06-08-2012, 04:29 PM
RE: SetPlayerActive(false) Help! - by P44RTHURN4X - 06-08-2012, 04:45 PM
RE: SetPlayerActive(false) Help! - by MaZiCUT - 06-08-2012, 04:56 PM
RE: SetPlayerActive(false) Help! - by SilentStriker - 06-08-2012, 07:25 PM
RE: SetPlayerActive(false) Help! - by P44RTHURN4X - 06-09-2012, 12:43 PM



Users browsing this thread: 1 Guest(s)