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
Manually Stopping Monster Music?
Tanshaydar Offline
From Beyond

Posts: 3,085
Threads: 17
Joined: Mar 2009
Reputation: 67
#12
RE: Manually Stopping Monster Music?

(08-17-2011, 10:52 PM)palistov Wrote: Try this looping timer.

bool bMonsterActive = false;

void MonsterStuff(blahblah blahblah)
{
    SetEntityActive("grunty", true);
    PlayMusic("gruntymusic.ogg", true, 1, 0, 0, true);
    bMonsterActive = true;
    AddTimer("", 5, "MonsterCheck");
}

void MonsterCheck(string &in timer)
{
    bMonsterActive = GetEntityExists("grunty") ? true : false;
    if(!bMonsterActive) PlayMusic("newmusic.ogg", true, 1, 0, 0, 0, true);
    AddTimer("", 5, "MonsterCheck");
}

What I was thinking is something like that, but that requires to check whether monster seeing the player, or chasing the player. Requires more work, which I don't feel like doing lately.

Well, thanks for the help all!

(This post was last modified: 08-17-2011, 11:37 PM by Tanshaydar.)
08-17-2011, 11:37 PM
Website Find


Messages In This Thread
Manually Stopping Monster Music? - by Tanshaydar - 08-17-2011, 02:24 PM
RE: Manually Stopping Monster Music? - by MrBigzy - 08-17-2011, 09:57 PM
RE: Manually Stopping Monster Music? - by Tanshaydar - 08-17-2011, 11:37 PM



Users browsing this thread: 1 Guest(s)