Jump to content
Sign in to follow this  
SpitShine

Script won't execute SOME TIMES, GIVES NO ERRORS

Recommended Posts

http://pastebin.com/CFCe8MSS

This is making me seriously fucking mad, the above script works just fine for spawning a convoy and setting up a task but it doesn't fucking do it consistently.

Yes, there are eight spawn markers on the map

no, it does not give script errors

yes, I have -showscripterrors on

Share this post


Link to post
Share on other sites

On a quick glance,

getMarkerPos objective1

->

getMarkerPos "objective1"

Share this post


Link to post
Share on other sites

If there's no script syntax mistakes in your script... I heard of scripts terminating when they take too long to be executed.

Share this post


Link to post
Share on other sites

Did you look in the .rpt file? Just because the script doesn't throw an error doesn't mean one doesn't get logged in the server/client rpt file(s).

Share this post


Link to post
Share on other sites

objective1 is defined elsewhere

how do I check the rpt file?

how do I know if the script is terminating early? How do I prevent that?

Share this post


Link to post
Share on other sites

Well you can check if a script has been executed all the way through with:

1. The "scriptDone" command.

Check out it's usage in the wiki command-overview.

https://community.bistudio.com/wiki/Category:Scripting_Commands_Arma_3

Be advised: The scriptDone command may also return true while some false/malfunctioning code in your script has been skipped.

Im not completely sure about that but the scriptDone command can be a first indicator.

Most likely the problem with your script is more syntax/logic based than the issue I posted but if you don't find a proper solution then maybe persuing this subject a bit more might be useful.

Furthermore I can only give you a Link to Killzone Kid's Blog with tutorials and hints on code performance. It's worth checking out anyway.

Share this post


Link to post
Share on other sites

scriptdone is broken, throws an undefined variable when there's nothing that's undefined.

and your link to KZK isn't helpful in the least unless you're going to point me to something specific relevant to my current troubles

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  

×