![]() |
Script wrong - 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 wrong (/thread-16654.html) |
Script wrong - snickker300 - 07-01-2012 I'm trying to make a custom story for amnesia and i'm kinda new to scripting. I tried making a script with the idea that you could open a door with a hollow needle but everytime i try to open the door with the needle it says: "cannot use this item this way!." This is my script: void Onstart() { AddUseItemCallback("","hollow_needle_1","prison_section_4","FUNC1", true); } void Onenter() { } void Onleave() { } void FUNC1(string &in asItem, string &in asEntity) { SetSwingDoorLocked("prison_section_4", false, true); RemoveItem("hollow_needle_1"); } Please help! RE: Script wrong - Adny - 07-01-2012 OnStart OnEnter and OnLeave aren't spelled properly; the word after On needs to be capitalized as well. RE: Script wrong - snickker300 - 07-01-2012 (07-01-2012, 05:37 PM)andyrockin123 Wrote: OnStart OnEnter and OnLeave aren't spelled properly; the word after On needs to be capitalized as well.Thanks! |