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
Script Help Combinating problems
Rapture Offline
Posting Freak

Posts: 1,078
Threads: 79
Joined: May 2011
Reputation: 30
#7
RE: Combinating problems

Tomato Cat is right, that was my Error. I'm guessing the compiler doesn't mine a bunch of "if"'s because I have a old working one.

void Timer_IntroFade(string &in asTimer)
{
if(asTimer == "IntroFade_0")
{
  FadeIn(1);
  StartPlayerLookAt("Area_Look_1", 0.75f, 0.75f, "");
}

if(asTimer == "IntroFade_1")
{
  StopPlayerLookAt();
  StartPlayerLookAt("Area_Look_2", 1, 1, "");
}

if(asTimer == "IntroFade_2")
{
  SetPlayerActive(true);
}

if(asTimer == "IntroFade_3")
{
  SetMessage("Message", "001_Sally01", 0);
}

if(asTimer == "IntroFade_4")
{
  SetMessage("Message", "001_Michael01", 0);
}

if(asTimer == "IntroFade_5")
{
  SetMessage("Message", "001_Sally02", 0);
}

if(asTimer == "IntroFade_6")
{
  StopPlayerLookAt();
  SetPlayerMoveSpeedMul(1);
  SetPlayerRunSpeedMul(1);
  SetPlayerLookSpeedMul(1);
  SetPlayerJumpDisabled(false);
  SetPlayerCrouchDisabled(false);
  SetInventoryDisabled(false);
}
}
Like Tomato Cat said, if I place another one of the "if(asTimer == "IntroFade_7) and replace the "if" with "else". The timer will default to "IntroFade_7" if none of the other above conditions match.
(This post was last modified: 08-02-2013, 10:45 PM by Rapture.)
08-02-2013, 10:45 PM
Find


Messages In This Thread
Combinating problems - by The chaser - 08-02-2013, 01:15 PM
RE: Combinating problems - by PutraenusAlivius - 08-02-2013, 01:31 PM
RE: Combinating problems - by The chaser - 08-02-2013, 03:19 PM
RE: Combinating problems - by Rapture - 08-02-2013, 03:38 PM
RE: Combinating problems - by The chaser - 08-02-2013, 04:21 PM
RE: Combinating problems - by Tomato Cat - 08-02-2013, 06:43 PM
RE: Combinating problems - by Rapture - 08-02-2013, 10:45 PM
RE: Combinating problems - by SilentStriker - 08-03-2013, 09:45 PM
RE: Combinating problems - by Rapture - 08-03-2013, 10:44 PM
RE: Combinating problems - by SilentStriker - 08-04-2013, 01:33 AM
RE: Combinating problems - by The chaser - 08-04-2013, 10:56 AM



Users browsing this thread: 1 Guest(s)