![]() |
Questions - 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: Questions (/thread-25442.html) |
UNEXPECTED ERROR - Amnesiaplayer - 06-06-2014 Please Help me! i want to make a Naked guy JumpscarE (teleport) but if i do every steps and i open it says Unexpected token blabla line (11,1) This is my Script: void onstart () { AddEntityCollideCallback("Player", "Teleport", "jumpscare", true, 1); } void jumpscare (string &in asParents, string &in asChild, int alstates); { SetEntityActive("jumpscare1", true); AddPropForce("jumpscare1", -10000, 0, 0, "world"); PlaySoundAtEntity("", "24_iron_maiden.snt", "jumpscare1", 0, false); } PLEASE HELP ME! RE: UNEXPECTED ERROR - DnALANGE - 06-06-2014 It is this : (string &in asParent, string &in asChild, int alState) NOT Parent(s) in alstate(s) - Also check the CAPITAL letters. RE: UNEXPECTED ERROR - Amnesiaplayer - 06-06-2014 It is this : (string &in asParent, string &in asChild, int alState) NOT Parent(s) in alstate(s) - Also check the CAPITAL letters. [/quote] thanks! i did that one.. but now it says Unexpected token line 7,1 ? X_X RE: UNEXPECTED ERROR - Neelke - 06-06-2014 There's a ; on the jumpscare script. void jumpscare (string &in asParent, string &in asChild, int alState) It's supposed to be like this. RE: UNEXPECTED ERROR - Mudbill - 06-06-2014 Make sure void OnStart() has the proper capitals as well. The s'es in your constructor don't really make a difference. RE: UNEXPECTED ERROR - Amnesiaplayer - 06-06-2014 [quote='Neelke' pid='296615' dateline='1402066911'] There's a ; on the jumpscare script. void jumpscare (string &in asParent, string &in asChild, int alState) Thanks!" it worked! no error! but my naked man doesn´t come to let me scream ![]() RE: UNEXPECTED ERROR - PutraenusAlivius - 06-06-2014 PHP Code: void onstart () //should be void OnStart()...// EDIT: The object jumpscare1 should be applied the force depending on where you are. It's not always on the X coordinate. The Z coordinate is possible. RE: UNEXPECTED ERROR - Amnesiaplayer - 06-06-2014 (06-06-2014, 04:17 PM)SomethingRidiculous Wrote: i don't understand ?! on youtube they talked about x and z cordinate but i didn't understand that so i did what the youtuber did... RE: UNEXPECTED ERROR - Romulator - 06-06-2014 Basically, if it is moving correctly, don't worry about it. Otherwise Spoiler below!
If it moves in the wrong direction, change this: PHP Code: AddPropForce("jumpscare1", -10000, 0, 0, "world"); //Moves negative X relative to the world. To any of these, and figure out which one works best for you! PHP Code: AddPropForce("jumpscare1", 10000, 0, 0, "world"); //Moves positive X relative to the world. PHP Code: AddPropForce("jumpscare1", 0, 0, -10000, "world"); //Moves negative Z relative to the world. PHP Code: AddPropForce("jumpscare1", 0, 0, 10000, "world"); //Moves positive Z relative to the world. RE: UNEXPECTED ERROR - Amnesiaplayer - 06-06-2014 (06-06-2014, 04:43 PM)Romulator Wrote: Basically, if it is moving correctly, don't worry about it. thanks! but.. Before i try... i want to say... my dude DON'T come... no sound... nopthing.. the area thing doesn't work... |