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
Despawn water lurker when he eats meat?
The chaser Offline
Posting Freak

Posts: 2,486
Threads: 76
Joined: Jun 2012
Reputation: 113
#2
RE: Despawn water lurker when he eats meat?

Hmm... you could try this:

Make a script area that surrounds the water. Put this:

void OnStart()
{
for (int i=1; i<500; i++) //500 in the case that you had 500 meats
{
AddEntityCollideCallback("Meat_"+i, "ScriptWater", "AddCollision", false, 1);
}
}

void AddCollision (string &in asParent, string &in asChild, int alState)
{
SetEnemyDisableTriggers("Waterlurker", false);
AddTimer("", //Time that your waterlurker will be busy//, "Reactivate");
}

void Reactivate (string &in asTimer)
{
SetEnemyDisableTriggers("Waterlurker", true);
}

It's possible that the true's and false's of SetEnemyDisableTriggers
have to be switched, just try this basic script and if it attacks you, change the true's for a false, and viceversa.

THE OTHERWORLD (WIP)
[Image: k6vbdhu]

Aculy iz dolan.
08-06-2013, 06:41 PM
Find


Messages In This Thread
RE: Despawn water lurker when he eats meat? - by The chaser - 08-06-2013, 06:41 PM



Users browsing this thread: 1 Guest(s)