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


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
The if ?
Unearthlybrutal Offline
Posting Freak

Posts: 775
Threads: 12
Joined: May 2011
Reputation: 26
#6
RE: The if ?

(03-06-2012, 06:27 PM)Nevicar Wrote: This is relevant to the first question asked and is mainly directed at Unearthlybrutal concerning "if" loops.

I have this set up:


if (SetEntityActive("m1") == true)
{
SetPlayerLookSpeed(0.5f);
SetPlayerRunSpeed(0.5f);
SetPlayerMoveSpeed(0.5f);}

else

SetPlayerLookSpeed(1f);
SetPlayerRunSpeed(1f);
SetPlayerMoveSpeed(1f);
}

Would this run correctly? The only reason I'm asking instead of testing is because I don't have access to Amnesia right now.
I'm not sure about that will the "SetEntityActive" work with the "If".

But if it will, this should work:
Spoiler below!

void function(syntax)
{
if (SetEntityActive("m1") == true)
{
SetPlayerLookSpeed(0.5f);
SetPlayerRunSpeed(0.5f);
SetPlayerMoveSpeed(0.5f);}
}

else

SetPlayerLookSpeed(1f);
SetPlayerRunSpeed(1f);
SetPlayerMoveSpeed(1f);
}



When Life No Longer Exists
Full-conversion mod
03-06-2012, 07:26 PM
Website Find


Messages In This Thread
The if ? - by Shives - 03-06-2012, 02:46 PM
RE: The if ? - by Unearthlybrutal - 03-06-2012, 02:53 PM
RE: The if ? - by Datguy5 - 03-06-2012, 02:54 PM
RE: The if ? - by Shives - 03-06-2012, 04:14 PM
RE: The if ? - by Nevicar - 03-06-2012, 06:27 PM
RE: The if ? - by Unearthlybrutal - 03-06-2012, 07:26 PM
RE: The if ? - by Nevicar - 03-06-2012, 07:34 PM
RE: The if ? - by Shives - 03-07-2012, 01:46 PM
RE: The if ? - by Stepper321 - 03-07-2012, 05:01 PM
RE: The if ? - by Shives - 03-07-2012, 05:22 PM



Users browsing this thread: 1 Guest(s)