ironman0001
Member
Posts: 53
Threads: 8
Joined: Sep 2012
Reputation:
0
|
Amnesia Editor Activate monster area not working
I wanna activate a monster with an area! But it doesn't do anything when i walk in it! Is there anything wrong with the script?
void OnStart()
{
AddEntityCollideCallback("Player", "TeleportScript", "PoopedYaPants", true, 1);
SetMessage("Messages", "Popup1", 0);
AddUseItemCallback("", "Spooky", "Scared", "PopupHead", true);
SetEntityPlayerInteractCallback("Spooky", "lolz", true);
AddEntityCollideCallback("Player", "CreepySound", "wow", true, 1);
AddEntityCollideCallback("Player", "scare_script1", "scare_script1", true, 1);
}
void PoopedYaPants(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("Jesus", true);
AddPropForce("Jesus", 0, 0, 10000, "world");
PlaySoundAtEntity("", "24_iron_maiden.snt", "Jesus", 0, false);
PlaySoundAtEntity("", "react_breath_slow.snt", "Player", 0, false);
PlaySoundAtEntity("", "react_scare", "Player", 0, false);
}
void Popup1()
{
AddEntityCollideCallback("Player", "Message_1", "Message1", true, 1);
}
void PopupHead(string &in asItem, string &in asEntity)
{
SetSwingDoorLocked("Scared", false, true);
PlaySoundAtEntity("", "unlock_door", "Scared", 0, false);
RemoveItem("Spooky");
}
void lolz(string &in item)
{
SetEntityActive("lolz_1", true);
PlaySoundAtEntity("", "21_screams.snt", "Player", 0, false);
}
void wow(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "29_amb_guard.snt", "CreepySound", 0, false);
}
void scare_script1(string &in asParent, string &in asChild, int alState)
{
SetEntityActive("grunt01", true);
ShowEnemyPlayerPosition("grunt01");
}
|
|
09-29-2012, 04:49 AM |
|
Statyk
Schrödinger's Mod
Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation:
241
|
RE: Amnesia Editor Activate monster area not working
ironman, you were already told to post problems concerning your story HERE . Don't place in the wrong section again, okay?
|
|
09-29-2012, 04:53 AM |
|
ironman0001
Member
Posts: 53
Threads: 8
Joined: Sep 2012
Reputation:
0
|
RE: Amnesia Editor Activate monster area not working
(09-29-2012, 04:53 AM)Statyk Wrote: ironman, you were already told to post problems concerning your story HERE . Don't place in the wrong section again, okay? WOOPS! I did post it on the wrong one! xD Sorry
|
|
09-29-2012, 04:56 AM |
|
Statyk
Schrödinger's Mod
Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation:
241
|
RE: Amnesia Editor Activate monster area not working
No problem. Just giving you a heads up.
As for your problem, try changing the name of the script area so it isn't the same as the function. This is just neat organization and could fix some issues. Also make sure the script area IS the same name as:
AddEntityCollideCallback("Player", "scare_script1", "scare_script1", true, 1);
(This post was last modified: 09-29-2012, 04:59 AM by Statyk.)
|
|
09-29-2012, 04:57 AM |
|
ironman0001
Member
Posts: 53
Threads: 8
Joined: Sep 2012
Reputation:
0
|
RE: Amnesia Editor Activate monster area not working
(09-29-2012, 04:57 AM)Statyk Wrote: No problem. Just giving you a heads up.
As for your problem, try changing the name of the script area so it isn't the same as the function. This is just neat organization and could fix some issues. Also make sure the script area IS the same name as:
AddEntityCollideCallback("Player", "scare_script1", "scare_script1", true, 1); Wait, This thread is on the list on there...
|
|
09-29-2012, 05:00 AM |
|
Statyk
Schrödinger's Mod
Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation:
241
|
RE: Amnesia Editor Activate monster area not working
I moved it.
|
|
09-29-2012, 05:02 AM |
|
ironman0001
Member
Posts: 53
Threads: 8
Joined: Sep 2012
Reputation:
0
|
RE: Amnesia Editor Activate monster area not working
(09-29-2012, 04:57 AM)Statyk Wrote: No problem. Just giving you a heads up.
As for your problem, try changing the name of the script area so it isn't the same as the function. This is just neat organization and could fix some issues. Also make sure the script area IS the same name as:
AddEntityCollideCallback("Player", "scare_script1", "scare_script1", true, 1); Still not working :\
|
|
09-29-2012, 05:04 AM |
|
Statyk
Schrödinger's Mod
Posts: 4,390
Threads: 72
Joined: Sep 2011
Reputation:
241
|
RE: Amnesia Editor Activate monster area not working
How is it fixed? Also, check if there's a .map_cache. If so, delete it.
|
|
09-29-2012, 05:06 AM |
|
|