Author Topic: Echelon Mirror causes crashes  (Read 4053 times)

0 Members and 1 Guest are viewing this topic.

Offline Earthmichael

Echelon Mirror causes crashes
« on: January 19, 2013, 06:31:54 AM »
I just encountered a bug that I had only seen once before, where the SMAX crashes when I move my cursor to a particular square.  I did not track down the cause the first time, but when I encountered the bug again, I spend some time tracking down the cause.

The crash appears to be triggered by an Echelon Mirror.  There are several odd aspects to this bug:
1. I had built the Echelon Mirror over 20 turns before the turn where it causes the crash.
2. The crash occurs only after I save and load the game.

The solution was fairly straightforward: I went back to a save one turn earlier, and destroyed the Echelon Mirror before it started triggering crashes.

Has anyone else observed this bug?

Does anyone know of any other solution other than destroying the Echelon Mirror?

Offline Petek

Re: Echelon Mirror causes crashes
« Reply #1 on: January 19, 2013, 12:26:03 PM »
Do you have a save file that illustrates the bug?
Which game (SMAC or SMAX) and which version (original, SOS, GOG, etc.) and which (if any) unofficial patch?
This might be a corruption of the Echelon Mirror graphic. Does anyone know in which file that graphic is kept?

Online Buster's Uncle

  • With community service, I
  • Ascend
  • *
  • Posts: 49426
  • €167
  • View Inventory
  • Send /Gift
  • Because there are times when people just need a cute puppy  Soft kitty, warm kitty, little ball of fur  A WONDERFUL concept, Unity - & a 1-way trip that cost 400 trillion & 40 yrs.  
  • AC2 is my instrument, my heart, as I play my song.
  • Planet tales writer Smilie Artist Custom Faction Modder AC2 Wiki contributor Downloads Contributor
    • View Profile
    • My Custom Factions
    • Awards
Re: Echelon Mirror causes crashes
« Reply #2 on: January 19, 2013, 03:09:56 PM »
That would be ter1.pcx - but I cannot imagine how a corrupted graphics file would have any effect other than displaying corrupted.

Offline Earthmichael

Re: Echelon Mirror causes crashes
« Reply #3 on: January 19, 2013, 03:19:56 PM »
The installation is GOG with all updates and the unofficial patch.

The game is T_Ras vs. Earthmichael.  It is the Drones that experience the problem at the mirror on the far west of their domain.  I have posted a save.

Offline Earthmichael

Re: Echelon Mirror causes crashes
« Reply #4 on: January 19, 2013, 03:22:26 PM »
To be clear, the bug occurs by moving the cursor adjacent to the mirror.  At this point, the game crashes.  If a graphics bug were to cause a crash, I don't see how it could be triggered by moving the cursor next to, but not on, the mirror.

Online Buster's Uncle

  • With community service, I
  • Ascend
  • *
  • Posts: 49426
  • €167
  • View Inventory
  • Send /Gift
  • Because there are times when people just need a cute puppy  Soft kitty, warm kitty, little ball of fur  A WONDERFUL concept, Unity - & a 1-way trip that cost 400 trillion & 40 yrs.  
  • AC2 is my instrument, my heart, as I play my song.
  • Planet tales writer Smilie Artist Custom Faction Modder AC2 Wiki contributor Downloads Contributor
    • View Profile
    • My Custom Factions
    • Awards
Re: Echelon Mirror causes crashes
« Reply #5 on: January 19, 2013, 03:41:09 PM »
It sounds to me like the north pole bug - sometimes a square on or near the northern edge of the map crashes the game if you do anything there.  It usually goes away if you avoid the square for a turn.  I never found a cause like your echelon mirror.

Offline Earthmichael

Re: Echelon Mirror causes crashes
« Reply #6 on: January 19, 2013, 04:56:04 PM »
This is different from the north pole bug.  For one thing, the location is not very close to the north pole.  And destroying the echelon mirror seems to have eliminated the bug.

Offline Petek

Re: Echelon Mirror causes crashes
« Reply #7 on: January 19, 2013, 05:56:54 PM »
I need the password to open the game. If you can't post it in public, you could PM it to me, if you wish. Is the tile in question near the "international date line"? That's the vertical strip where the tile coordinates roll over. I think there have been some bugs associated with that.

Offline Petek

Re: Echelon Mirror causes crashes
« Reply #8 on: January 19, 2013, 08:30:19 PM »
OK, so I opened the save game. I think I see what's causing the crash. There's a crawler NW of the Echelon Mirror that is crawling 7 EC/turn for Free Drone Central. However, if you open the Free Drone Central base screen, the Forces Supported display does not list any crawler crawling 7 ECs. In fact, if you click on each of the crawlers in that display, the crawler in question never activates. I guess that something in the internal game tables got out of synch. Destroying the Echelon Mirror in the previous turn prevented that from happening. A save game from the turn before this happened might allow Yitzi or kyrub to see the problem, but probably isn't worth the effort. Just my opinion.

Offline Earthmichael

Re: Echelon Mirror causes crashes
« Reply #9 on: January 19, 2013, 09:58:02 PM »
Thanks for looking into it!  If anyone wants to look at earlier turns, that is fine with me.  I have all of the saves back to the beginning of the game, in case I later want to do an AAR.

Offline Yitzi

Re: Echelon Mirror causes crashes
« Reply #10 on: February 07, 2013, 08:13:53 PM »
I tried to look at it, but I don't know the password to get into the game...

Offline Yitzi

Re: Echelon Mirror causes crashes
« Reply #11 on: February 07, 2013, 10:14:18 PM »
OK, so I opened the save game. I think I see what's causing the crash. There's a crawler NW of the Echelon Mirror that is crawling 7 EC/turn for Free Drone Central. However, if you open the Free Drone Central base screen, the Forces Supported display does not list any crawler crawling 7 ECs. In fact, if you click on each of the crawlers in that display, the crawler in question never activates.

That's because it's not 1 of the first 15 crawlers; only the first 15 crawlers show, and I think that's part of why it gets messed up; disbanding one of the earlier crawlers (so that one is no longer #16) makes it not crash.  More investigation will be needed.

Offline Yitzi

Re: Echelon Mirror causes crashes
« Reply #12 on: February 08, 2013, 01:40:57 AM »
Ok, turns out that it has nothing to do with the fact that it's not one of the first 15 crawlers and does not show on the base screen; what caused it not to crash when I disbanded the other crawlers from the base screen is that I had entered the base screen:

The culprit here is the obscure rule that if echelon mirrors outside your territory don't help you.  Thus, if I'm reading things correctly, the program, once it's found an echelon mirror next to the (collector-holding) square it's investigating, does as follows:
"If the mirror-ed square is in the territory of the base's owner, add +1 to the energy value of the square."  Seems pretty sensible...as long as "the base" exists.  If it doesn't, you get a crash.  For this reason, I expect that you will get a crash when checking the energy production of a square with a solar collector (or check its energy production if it had a solar collector) which is next to a square with an echelon mirror if and only if you do it before going into any bases.  Now, there are two ways to check the energy production of a square without going into any bases: Either look at a crawler that is crawling energy from it, or go to that square and then click on the square display to see how much of each resource it produces.

This also suggests an easy way to prevent the crash: As long as you check on one of your bases before clicking on that square, you should be fine.  Checking on someone else's bases (e.g. via infiltration) should also work, but will cause the energy production displayed to be wrong.

Now, it would be fairly easy to fix it to not crash, but might be somewhat more work to make it work properly (i.e. also show the right value under all circumstances.)  Even with the easy fix, the actual effect will work right, it's just the display that might have some mistakes.  Until I do whichever, checking on a base beforehand should prevent the crash.

Offline Yitzi

Re: Echelon Mirror causes crashes
« Reply #13 on: February 12, 2013, 02:18:59 AM »
Ok, I just looked into it, and it's actually a fairly simple fix (which will also fix an obscure error that in similar cases can cause a crawler to show the wrong amount being crawled), so it will be included in version 1.3 of my patch.  Until then, just make sure to enter a base before checking any crawlers benefiting from echelon mirrors, and you'll avoid the crash.

Offline ete

Re: Echelon Mirror causes crashes
« Reply #14 on: February 12, 2013, 04:30:43 PM »
Good find and fix Yitzi :).

 

* User

Welcome, Guest. Please login or register.

Login with username, password and session length

Select language:

* Community poll

SMAC v.4 SMAX v.2 (or previous versions)
-=-
24 (7%)
XP Compatibility patch
-=-
9 (2%)
Gog version for Windows
-=-
103 (32%)
Scient (unofficial) patch
-=-
40 (12%)
Kyrub's latest patch
-=-
14 (4%)
Yitzi's latest patch
-=-
89 (28%)
AC for Mac
-=-
3 (0%)
AC for Linux
-=-
6 (1%)
Gog version for Mac
-=-
10 (3%)
No patch
-=-
16 (5%)
Total Members Voted: 314
AC2 Wiki Logo
-click pic for wik-

* Random quote

Proper care and education for our children remains a cornerstone of our entire colonization effort. Children not only shape our future.. they determine in many ways our present. Men and women work harder knowing their children are safe and close at hand, and never forget that, with children present, parents will defend their home to the death!
~Col. Corazon Santiago 'Planet: A Survivalist's Guide'

* Select your theme

*
Templates: 5: index (default), PortaMx/Mainindex (default), PortaMx/Frames (default), Display (default), GenericControls (default).
Sub templates: 8: init, html_above, body_above, portamx_above, main, portamx_below, body_below, html_below.
Language files: 4: index+Modifications.english (default), TopicRating/.english (default), PortaMx/PortaMx.english (default), OharaYTEmbed.english (default).
Style sheets: 0: .
Files included: 45 - 1228KB. (show)
Queries used: 39.

[Show Queries]