05-21-2011, 09:58 AM
Hello peoples,
I wanted to know is there such features in angle script (the one to code Amnesia and custom stories) like 'if' and 'else' because I was going to do a bit in my level where you pull a lever and if a variable = 0 then a message will appear otherwise a door will unlock.
How would I set my script to detect if my var is 0 and show a message or 1 and unlock a door?
I hope that you can help
EDIT:
I wanted to know is there such features in angle script (the one to code Amnesia and custom stories) like 'if' and 'else' because I was going to do a bit in my level where you pull a lever and if a variable = 0 then a message will appear otherwise a door will unlock.
How would I set my script to detect if my var is 0 and show a message or 1 and unlock a door?
I hope that you can help
EDIT:
Code:
void used1(string &in asParent, string &in asChild, int alState)
{
if
AddLocalVarInt("door1", 0);
SetMessage("Message", "used1", 3);
else
//Something
}