![]() |
The "IF" with HasItem - 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: The "IF" with HasItem (/thread-14628.html) |
RE: The "IF" with HasItem - jessehmusic - 04-09-2012 (04-09-2012, 06:21 AM)Quotentote Wrote: i would make it a bit easier. i guess you want agrippa to spawn as soon as the player enters that area right? i would make the area inactive and activate it when you picked up that key..how do i make area ![]() RE: The "IF" with HasItem - Datguy5 - 04-09-2012 (04-09-2012, 01:11 PM)SilentStriker Wrote:Ive never used the if function before.Can you be more specific with that?Also the item is combinable in the game.What if the player has combined it before he collides with the area?(04-09-2012, 10:49 AM)Datguy5 Wrote: When this is done can someone help me with my if function?I dont wanna start a new thread about it.Im trying that if player doesnt have item,the player will look at it.try RE: The "IF" with HasItem - jessehmusic - 04-09-2012 (04-09-2012, 09:57 AM)SilentStriker Wrote: I remember a script that always messed up, it didn't trigger but then I realised that I went throught the area and the trigger was removed so I changed so the callback would be removed on trigger x) void Scary1(string &in asParent, string &in asChild, int alState) if(HasItem("The_gone_key") == false) { SetEntityActive("agrippa_headless_1", true); PlaySoundAtEntity("", "alois_amb_idle.snt", "Player", 0, false); } "get error : expected ; or :" RE: The "IF" with HasItem - Obliviator27 - 04-09-2012 void Scary1(string &in asParent, string &in asChild, int alState) { if(HasItem("The_gone_key")) { SetEntityACtive("agrippa_headless_1", true); PlaySoundAtEntity("", "alois_amb_idle.snt", "Player", 0, false); } } RE: The "IF" with HasItem - jessehmusic - 04-09-2012 (04-09-2012, 09:16 PM)Obliviator27 Wrote: void Scary1(string &in asParent, string &in asChild, int alState)He dosn't Spawn at all now :S damn this realy make me pissed RE: The "IF" with HasItem - Obliviator27 - 04-09-2012 SetEntityActive, sorry, I didn't release the shift key in time. RE: The "IF" with HasItem - jessehmusic - 04-10-2012 (04-09-2012, 10:22 PM)Obliviator27 Wrote: SetEntityActive, sorry, I didn't release the shift key in time.i saw that and changed it but it still dosnt work :S the script wont call :S RE: The "IF" with HasItem - SilentStriker - 04-10-2012 Start using debug messages it helps alot. RE: The "IF" with HasItem - jessehmusic - 04-10-2012 (04-10-2012, 12:40 PM)SilentStriker Wrote: Start using debug messages it helps alot.i have it ![]() RE: The "IF" with HasItem - Apjjm - 04-10-2012 Can you upload your map with script file? |