Just so that I have this all sorted out.
I don't seem to be able to use variables in room scripts, is that because you just cant do that, or am I just doing something wrong?
if you cant, then is the only way I can get variables in a function that is in a roomscript by making another variable in the global script, and then make a function of the same name?
thanks for any help in advance.
The variables have to be declared at the very top of the room script. The functions have to follow after that.
//room script file
int myInt;
function myFunction()
{
// do something
}
Then they can be used anywhere in that room.
Could you give some example of how you want to use variables? What doesn't work?
You can declare variables at any time btw, not just at the top of the script.
What a dunce I am! :P
I had it all figured out, it's just that i forgot to put the semicolon after the "int exampleCounter" bit.
thanks all the same. 8)