Jump to content

Petra errors after destroying AI's civic center.


Mythos_Ruler
 Share

Recommended Posts

The first two errors

ERROR: JavaScript error: uncaught exception: [sprintf] property "name" does not exist

and

WARNING: JavaScript warning: gui/common/timer.js line 64

have appeared when the I18n code was commited. And for me, I appears only when changing perspective and taking the AI player (both aegis and petra). I've made a ticket for the first one http://trac.wildfiregames.com/ticket/2485

The last error ERROR: JavaScript error: simulation/ai/common-api/utils.js line 23 is certainly a petra error. I will have a look at it.

Link to comment
Share on other sites

I thought the first ones were causing further issues (which would be a bug on its own, as the translation should never change the simulation).

I have improved the sprintf error reports, so now it should be easier to find the cause.

Link to comment
Share on other sites

Mythos_Ruler, thanks for the report. The petra error is fixed in svn r15092

sanderd17, thanks for the fix on sprintf ! Were you also able to reproduce the one on timer.js ? It also appeared for me when the I18n code was introduced, but may-be due to some "Change perspective" feature ?

Link to comment
Share on other sites

The timer problem was because sprintf threw a string instead of an Error object. Thus that string didn't have a stacktrace, and that's the error you saw in timer.js

I think it's good coding practice if we expect that anything that's thrown also had a trace, so i fixed sprintf rather than the timer.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...