A couple more Errors

Beta4 testers

A couple more Errors

Postby KGB » Tue Jul 26, 2011 10:21 pm

A couple more errors today:

1) I attacked another neutral city again got the out of sync error that forced me to do a reload to see what the battle result was. This time I captured the Ajax error. It's in what looks like a file called highres at line 4081. The error says misc.isInt is not a function. The line of code is:

if ((misc.isInt(cityIncome)) {va ... on = "tbaseicon"; var margin = "18";}

I hope that lets you track down what happened.

2) When I go back into the battle screen and review the battle it shows the defender city wall icon with a +5 next to it. This despite the fact I brought a battering ram. If I tool tip over the enemy unit it shows 15 + 4 (swarm) + 5 = 19. Meanwhile on my side, there appears to be a battering ram icon with a 0 next to it instead of a 5. Clearly there is a math error there as the tool tip and battle screen is forgetting to subtract 5 from the ram. Of course the actual battle clearly used the right numbers so it's just a review battle issue.

3) On the City Overview screen that you are still working on I found an error. If you own 2+ cities and click on the production of the bottom one then click on the production of the upper one, the unit icon to the left changes to the icon of the unit on the lower city. So it appears you are making a unit there that you don't even have in that city. This produces an Ajax error is cities.js at line 274 that says cities.citiesobj[id].producing = producing is not defined. There is another one at line 2912 same file that says if (data.newdata == "yes") is NULL.

This seems to mess up the production in your cites so that you have to manually go and make sure they are all OK.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby SnotlinG » Tue Jul 26, 2011 11:01 pm

Regarding bug 1 - the out of sync.
I suspect you captured the wrong ajax callback.
Im attaching how it normally looks.
Im expecting some kind of PHP code output in front of the response-code, i.e. in front of the bracket of the example output below
<some kind of PHP error-output here I guess>{"endcoord":"21_16","warid":0,"movecheck":1}

In your out of sync response, Im expecting warid to not be 0 also.
Attachments
ajaxcall2.png
The standard ajax call looks something like this
ajaxcall2.png (14.42 KiB) Viewed 16275 times
ajaxcall1.png
This is what the standard ajax response looks like
ajaxcall1.png (5.25 KiB) Viewed 16275 times
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am

Re: A couple more Errors

Postby KGB » Wed Jul 27, 2011 1:22 am

SnotlinG,

I can't view your png files.

I took a screen shot which I didn't attach. But the only line in the Console->Error tab was the one I mentioned. The error obviously happened on the server side since it was an out-of-sync as opposed to a problem of me being able to attack. So I would imagine the real error is somewhere on the server side and what ever got shown on my side was because the sync didn't happen properly.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby SnotlinG » Wed Jul 27, 2011 8:32 am

Hello KGB,

The trick is you need to look in Console->All, as the ajax response itself is not reported as an error, but the error will come a bit later. So to find the faulty ajax response you need to check the console->all, and check the responses a few lines back. (Its a POST to ajax_receivedata.php that)

- Reposting images as jpg. You might have to access the forum via http://www.warbarons.net/forumframe.php to see the images also
Attachments
ajaxcall2.jpg
The standard ajax call looks something like this
ajaxcall2.jpg (39.68 KiB) Viewed 16269 times
ajaxcall1.jpg
This is what the standard ajax response looks like
ajaxcall1.jpg (16.34 KiB) Viewed 16269 times
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am

Re: A couple more Errors

Postby KGB » Thu Jul 28, 2011 10:54 pm

SnotlinG,

No out of sync this turn when attacking a neutral. I keep looking for it now that I know what to look for.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby KGB » Thu Jul 28, 2011 10:56 pm

SnotlinG,

No out of sync this turn when attacking a neutral.

If I get it again I'll know what to look for.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby KGB » Tue Aug 02, 2011 10:22 pm

SnotlinG,

I got the out of sync error again. I didn't capture a screen shot because I am 99% sure I know what's causing it.

Each time I have gotten it (turn 1, 3 and now this turn) I have attacked a neutral city with land units and a Sea Serpent in the same stack. That causes the error. In this case, I had movement of 6, 8 and 12 (Sea Serpent) standing next to a city. I clicked on the city to attack and it showed the path cost as 0, grayed out as if I could not reach 1 square away. However when I clicked the move button my stack disappeared and I got the out of sync error.

I checked the battle report and it attacked just fine. Refreshing the browser took me to the capture screen.

So something is amiss when attacking cities with a Sea Serpent.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby SnotlinG » Wed Aug 03, 2011 10:06 pm

Ok good, I think I have found the problem in the code and fixed it now.
I havent tested much myself yet, but looks promising.
Let me know if you face this error again.

Thanks!
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am

Re: A couple more Errors

Postby KGB » Sun Aug 07, 2011 9:09 pm

SnotlinG,

One more for your/Piranha's list

After capturing a city the last 2 turns I've clicked on the City menu icon (the one that shows all your production). Both times it's not opened the pop-up menu. There is an error displayed in the Java Console about an index issue. Reloading the browser lets the button work properly.

My guess is something isn't refreshing on the browser or back on the server after a city is captured to let that window function properly.

KGB
KGB
 
Posts: 3030
Joined: Tue Feb 16, 2010 12:06 am

Re: A couple more Errors

Postby SnotlinG » Mon Aug 08, 2011 10:34 am

Thanks,
Should be fixed now. Please give it a new try when you get the next city :-)
SnotlinG
 
Posts: 2148
Joined: Sat Feb 13, 2010 12:42 am


Return to beta4 discussion

Who is online

Users browsing this forum: No registered users and 1 guest

cron
Not able to open ./cache/data_global.php