Changeset 66:d112357a0ec1

Show
Ignore:
Timestamp:
12/11/10 18:36:20 (18 months ago)
Author:
Thibaut Girka <thib@…>
Branch:
default
Message:
Fix a bug with savegames introduced with changeset c7bcc0ec2267.

Warning: savegames created since c7bcc0ec2267 are probably corrupted,
you may have to start the game over.
If you chose not to do so, you should replace all occurrences of 'TextWindow' by 'TextImplWindow',
and 'Text Window' by 'TextImpl Window' in your save files.
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • scn2k/scn2k_text.cc

    r65 r66  
    315315        char buf[1024]; 
    316316        str = "\n"; 
    317         str += "[Text Window]\n"; 
    318         sprintf(buf, "TextWindow=%d\n",text_window_number); 
     317        str += "[TextImpl Window]\n"; 
     318        sprintf(buf, "TextImplWindow=%d\n", text_window_number); 
    319319        str += buf; 
    320320        if (rollback_save) { 
     
    413413        drawn_backlog_item.Clear(); 
    414414 
    415         str = strstr(str, "\n[Text Window]\n"); 
     415        str = strstr(str, "\n[TextImpl Window]\n"); 
    416416 
    417417        if (str) { 
    418418                SaveFaceHash face_log; 
    419                 str += strlen("\n[Text Window]\n"); 
     419                str += strlen("\n[TextImpl Window]\n"); 
    420420                const char* strend = str; 
    421421                do { 
     
    427427 
    428428                        if (str[0] == '[') break; // next section 
    429                         if (strncmp(str, "TextWindow=",15) == 0) { 
     429                        if (strncmp(str, "TextImplWindow=",15) == 0) { 
    430430                                str += 15; 
    431431                                sscanf(str, "%d", &text_window_number);