Jump to content
Sign in to follow this  
KaRRiLLioN

Script error log/dumpfile

Recommended Posts

I'm porting missions over to ArmA, and yes, most of them still use SQS scripts instead of SQF scripts--but I'll get around to that later.

As you can guess, I'm getting a lot of errors since they've changed some functions, i.e. {} for code and call compile for string code.

Is there some way to have Arma dump the errors into a logfile so I can see the entire lines of code that are erroring out?  As it is, most of it runs off the screen so quickly that I can't make it out.

Also, couple of other questions--

I have this line of code:

Quote[/b] ]

call compile format ["%1Obj%2 = TRUE; publicVariable "%1Obj%2"",_side,_ns]

I was using {} inside some of these, but now I have to go to quotes.  Inside this, do I need double quotes now for the publicvariable?  I just can't remember and this particular mission uses a LOT of call compile strings for dynamic variables.

Share this post


Link to post
Share on other sites

I do believe inside quotes, you have to use double quotes. It's the same deal in description/config files.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">call compile format ["%1Obj%2 = TRUE; publicVariable ""%1Obj%2""",_side,_ns]

Ah, and it makes sense. This is because OFP(or ArmA) think the string ends when it sees a quotation mark followed by somethign else. But when there's two together, it nows that's its a string within a string. So yes, you need to use my example.

Share this post


Link to post
Share on other sites
call compile format ["%1Obj%2 = TRUE; publicVariable "%1Obj%2"",_side,_ns]

Without experimenting i noticed something wrong on the format there.

I think it should be:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">call compile format ["%1Obj%2 = TRUE",_side,_ns]; publicVariable "%1Obj%2";

Share this post


Link to post
Share on other sites
call compile format ["%1Obj%2 = TRUE; publicVariable "%1Obj%2"",_side,_ns]

Without experimenting i noticed something wrong on the format there.

I think it should be:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">call compile format ["%1Obj%2 = TRUE",_side,_ns]; publicVariable "%1Obj%2";

What?! Nonono. Why would you put publicvariable after format? Then the engine doesn't know what %1 and %2 is. %1 and %2 are the variables _side and _ns. That's why it's in Format. Your version wont work at all.

Share this post


Link to post
Share on other sites
call compile format ["%1Obj%2 = TRUE",_side,_ns]; publicVariable "%1Obj%2";

Well put it inside, but after the first set of "" anyways.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

call compile format ["%1Obj%2 = TRUE",_side,_ns; publicVariable "%1Obj%2"];

Share this post


Link to post
Share on other sites
call compile format ["%1Obj%2 = TRUE",_side,_ns]; publicVariable "%1Obj%2";

Well put it inside, but after the first set of "" anyways.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">

call compile format ["%1Obj%2 = TRUE",_side,_ns; publicVariable "%1Obj%2"];

No, that will still not work. Now you're trying to put that line of code as a %3.

This code WILL work.

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">call compile format ["%1Obj%2 = TRUE; publicVariable ""%1Obj%2""",_side,_ns]

You need it inside the quotes.

Share this post


Link to post
Share on other sites
The code you input there zig its the one he says it doesnt work...

Look again. I put more quotation marks, so ArmA doesnt confuse it with the string ending.

call compile format ["%1Obj%2 = TRUE; publicVariable <span style='color:red'>""</span>%1Obj%2<span style='color:red'>"""</span>,_side,_ns]

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×