Frictional Games Forum (read-only)
[SCRIPT] Why doesn't this work? - Printable Version

+- Frictional Games Forum (read-only) (https://www.frictionalgames.com/forum)
+-- Forum: Amnesia: The Dark Descent (https://www.frictionalgames.com/forum/forum-6.html)
+--- Forum: Custom Stories, TCs & Mods - Development (https://www.frictionalgames.com/forum/forum-38.html)
+---- Forum: Development Support (https://www.frictionalgames.com/forum/forum-39.html)
+---- Thread: [SCRIPT] Why doesn't this work? (/thread-15403.html)



Why doesn't this work? - TheBigNotch - 05-12-2012

Code:
void OnStart()
{
    AddDebugMessage("Start: intro",false);
    SetEntityPlayerInteractCallBack("key_1","ActivateMonster", true);
    AddDebugMessage("SetEntityPlayerInteractCallBack complete.");
}

void OnEnter()
{
    AddDebugMessage("Enter: intro",false);
}

void OnLeave()
{
    AddDebugMessage("Leave: intro",false);
}

void ActivateMonster(string &in item)
{
    SetEntityActive("monster_1",true);
    AddDebugMessage("monster_1 is now active");
}
If you want to see the error you need to download the map. It's to large for me to write down. xD

(PS. I'm new to this.)



RE: Why doesn't this work? - SilentHideButFine - 05-12-2012

(05-12-2012, 08:04 PM)TheBigNotch Wrote:
Code:
void OnStart(){    AddDebugMessage("Start: intro",false);    SetEntityPlayerInteractCallBack("key_1","ActivateMonster", true);    AddDebugMessage("SetEntityPlayerInteractCallBack complete.");}
void OnEnter(){    AddDebugMessage("Enter: intro",false);}
void OnLeave(){    AddDebugMessage("Leave: intro",false);}
void ActivateMonster(string &in item){    SetEntityActive("monster_1",true);    AddDebugMessage("monster_1 is now active");}
If you want to see the error you need to download the map. It's to large for me to write down. xD
(PS. I'm new to this.)
Make it so i can read it ?


RE: Why doesn't this work? - TheBigNotch - 05-12-2012

Weird copy bug. Srry.


RE: Why doesn't this work? - Your Computer - 05-12-2012

The error tells you why. You tried to make a call to functions that don't exist.

FYI: You can reduce error messages by trying to load the map twice.


RE: Why doesn't this work? - TheBigNotch - 05-12-2012

Fixed.