Problem with a script (Expected identifier) - 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 (https://www.frictionalgames.com/forum/forum-35.html) +--- Thread: Problem with a script (Expected identifier) (/thread-7265.html) |
Problem with a script (Expected identifier) - lordmestari - 04-09-2011 I cannot see where is the mistake, to my knowledge this script should work. I am quite new still though, so could one of you please check if there is an actual mistake? (11,32): ERR : Expected Identifier My script looks like this: void OnStart() { AddEntityCollideCallback("Player" , "GruntArea" , "MonsterFunc1" , true, 1); } void MonsterFunc1(string &in asParent , string &in asChild , int alState) { SetEntityActive("servant_grunt_2" , true); } SetEntityPlayerInteractCallback("tinderbox_1" , "TakeTinder" , true); void TakeTinder(string &in asEntity) { SetEntityActive("servant_grunt_1" , true); } Thanks in advance RE: Problem with a script (Expected identifier) - MrBigzy - 04-09-2011 SetEntityPlayerInteractCallback("tinderbox_1" , "TakeTinder" , true); is not in a function. Put it in OnStart. |