![]() |
[SCRIPT] Make something occur upon continue? - 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] Make something occur upon continue? (/thread-21251.html) Pages:
1
2
|
RE: Make something occur upon continue? - Romulator - 04-23-2013 (04-23-2013, 02:33 PM)JustAnotherPlayer Wrote: Bro, the integer is 0. Refresh the page. I think the if statement is incorrect as well; if(alState) == 0) There seems to be one extra bracket.. RE: Make something occur upon continue? - PutraenusAlivius - 04-23-2013 (04-23-2013, 03:02 PM)ROMul8r Wrote:if(alState == 0)(04-23-2013, 02:33 PM)JustAnotherPlayer Wrote: Bro, the integer is 0. Refresh the page. RE: Make something occur upon continue? - Romulator - 04-23-2013 Well, seems like it doesnt work :/ I'll sleep on it, since it is 12:15 and I have school tomorrow. ![]() I'll continue as such tomorrow. RE: Make something occur upon continue? - Tomato Cat - 04-23-2013 PHP Code: if(alState) == 0) I *believe* this is your problem. During a collision, the "state" is either 1 or -1, entering and exiting, respectively. When setting up the callback, you can also set alState to have a value of 0, which basically means it will call the function in either state (entering/exiting). I don't think it means that alState is passed as 0 during the collision. Basically, your if statement is saying "only do this if the player is both entering and exiting." You see the problem with that, right? Try changing it to this: PHP Code: if(alState == 1) RE: Make something occur upon continue? - Romulator - 04-23-2013 (04-23-2013, 04:05 PM)Mr Credits Wrote: Yeah, I did note how on the wiki, 0 is defined as both entering and exiting, however, I could be misinterpreting it, as could JAP because he said to change it to zero. I will try later tonight ![]() RE: Make something occur upon continue? - Romulator - 04-24-2013 Aha! ![]() Solved ![]() +rep to those who helped as always! |