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
How do I make a lever that removes an entity?
oscar1007 Offline
Member

Posts: 64
Threads: 24
Joined: Oct 2011
Reputation: 0
#3
RE: How do I make a lever that removes an entity?

(10-04-2011, 05:09 PM)schmupper Wrote:
void OnStart()
{
SetEntityConnectionStateChangeCallback("LeverName", "Function");
}


void OnEnter()
{

}

void Function(string &in asEntity, int alState)
{
    if (alState == 1)
    {
    SetEntityActive("EntityName", false);
          return;
    }
void OnLeave()
{

}

That should work.
Thank you! it works now. but you forgot a "}" for ending the function. just sayin! Wink

Money can't buy you happiness. But I rather cry in my ferrari.

PROJECT:
http://www.moddb.com/mods/oscar1007
10-04-2011, 05:25 PM
Find


Messages In This Thread
RE: How do I make a lever that removes an entity? - by oscar1007 - 10-04-2011, 05:25 PM



Users browsing this thread: 1 Guest(s)