Wargus / stratagus

The Stratagus strategy game engine
GNU General Public License v2.0
614 stars 115 forks source link

Saved games won't load at all! #64

Closed timfel closed 8 years ago

timfel commented 8 years ago

I'm testing out build 8201 - here are the bugs

Goldmines (and probably Oil derriks) don't animate when playing Skirmish - they do work when playing campaign though Saved Games will not load AT ALL, don't matter if you try loading straight after saving, quiting to menu/to windows, they won't load at all.

I've even run it in debug mode and there's no message telling me where the error is. My friend is also having the same problem.


Imported from Launchpad using lp2gh.

timfel commented 8 years ago

(by dinky-dye-aussie) Build 8203 loads games just after you save them as soon as you start, but when you have a big battle after saving, it won't load the save, it just exits.

it keeps telling me the there's an error in "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\vector - where "vector" is the name of the external file - it doesn't have an extension to it like .cpp, etc...

Anyways it's line 932 which is the following

if _ITERATOR_DEBUG_LEVEL == 2

    if (size() <= _Pos)
        {   // report error

---> _DEBUG_ERROR("vector subscript out of range"); <--- _SCL_SECURE_OUT_OF_RANGE; }

the arrowed line is the error that is being reported.

timfel commented 8 years ago

(by dinky-dye-aussie) i think it's a Vec2i issue to be honest

timfel commented 8 years ago

(by joris-dauphin) Fix a Saving/loading problem with Missile and Animation-die. now Saving/loading should work.

vector and Vec2i are unrelated (vector is the std:: "array" , Vec2i is a stratagus "Point") as it is a common low level container, most stack error or buffer overflow make these container report error.

For the gold Mine, it is not the game mode where is the bug, but a conflict in animation and unit ID (not fixed yet).

Thanks for the report.

timfel commented 8 years ago

(by joris-dauphin) gold mine animation fixed in trunk (stratagus+wargus).

timfel commented 8 years ago

(by dinky-dye-aussie) Well it seems your fix to the code to make save games load is so far working nicely for me :)

I've been testing the skirmish mode a lot this morning and have been getting whipped hardcore by the computer :) and have had to reload the save games alot, and have done so without a single crash :) So I'm very happy about it working they way it should. If I have any more trouble with it I will let you know, but for now - great work mate :)