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
Need some help with scripting... new to AMNESIA'S scripting...
Adny Offline
Posting Freak

Posts: 1,766
Threads: 6
Joined: Mar 2012
Reputation: 173
#2
RE: Need some help with scripting... new to AMNESIA'S scripting...

Before posting I'd like to know if this is just 1 map, or 3 separate maps?

Okay, under the assumption that this is 1 map, here's how it should look:


void OnStart()
{
AddEntityCollideCallback("Player", "LightsOut", true);
SetEntityPlayerInteractCallback("monster_tinderbox", "function", true);
AddEntityCollideCallback("Player", "script_slam", "func_slam", true, 1);
}

void LightsOut(string &in asParent, string &in asChild, int alState)
{
[SetLampLit("outlamp_1", false, true); ///I don't know what "[]" do or what you're trying to accomplish with them, so I left them alone.
AddTimer("", 2, "Out2");
} ]

void function(string &in asEntity)
{
SetEntityActive("tinbox_prolwer", true);
}

void func_slam(string &in asParent, string &in asChild, int alState)
{
SetSwingDoorClosed("slamdoor1", true, true);
PlaySoundAtEntity("", "react_breath_slow.snt", "Player", 0, false
PlaySoundEntity("", "react_scare", "Player", 0, false);
GiveSanityDamage(5, 0f, true);
}

void OnEnter()
{

}

void OnLeave()
{

}

I rate it 3 memes.
(This post was last modified: 07-29-2012, 05:54 AM by Adny.)
07-29-2012, 05:47 AM
Find


Messages In This Thread
RE: Need some help with scripting... new to AMNESIA'S scripting... - by Adny - 07-29-2012, 05:47 AM



Users browsing this thread: 1 Guest(s)