Post reply

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.
Name:
Email:
Subject:
Message icon:

Verification:
Type the letters shown in the picture
Listen to the letters / Request another image

Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?:

shortcuts: hit alt+s to submit/post or alt+p to preview


Topic Summary

Posted by: icelus
« on: May 14, 2006, 12:23:30 PM »

Works on Tutu!  Hooray!  Thanks, Mr. Sin.  :)
Posted by: icelus
« on: May 14, 2006, 12:06:24 PM »

Works perfectly on BG1.  :)  Only one Dezkiel, all entrances functional, etc.

I'll start the conversion to Tutu now and test it, as well as get v2 out today to fix this and my horrible store bug.
Posted by: devSin
« on: May 14, 2006, 12:12:52 AM »

This business should now be fully finished. Give the updated patches a whirl; everything should go smoothly. Unless there's somehow more Dezkiel's than number of actors (impossible), the patch should never fail. The patch works correctly if Dezkiel doesn't exist in the target area (i.e., FotD is already installed).
Code: [Select]
COPY_EXISTING AR1008.ARE OVERRIDE
              AR1009.ARE OVERRIDE
  PATCH_IF (SOURCE_SIZE > 0x11c) BEGIN
    /* Doesn't work!!!
    PATCH_IF !("%SOURCE_RES%" STRING_COMPARE_CASE "AR1009") BEGIN
      // Remove Dezkiel from AR1009 (he's now in AR1010)
      READ_LONG 0x54 actOff
      FOR (READ_SHORT 0x58 numAct; numAct; numAct -= 0x1) BEGIN
        READ_ASCII actOff + 0x80 char
        PATCH_IF !("%char%" STRING_COMPARE_CASE "DEZKIE") BEGIN
          WRITE_LONG actOff + 0x28 0x0 // Disable Dezkiel in AR1009
        END
        actOff += 0x110
      END
    END
    */
    // Make default transitions autosave; enable travel to AR1010
    READ_LONG 0x5c trigOff
    FOR (READ_SHORT 0x5a numTrig; numTrig; numTrig -= 0x1) BEGIN
      READ_SHORT trigOff + 0x20 type
      PATCH_IF (type == 0x2) BEGIN
        READ_ASCII trigOff + 0x38 destAre
        PATCH_IF !(("%destAre%" STRING_COMPARE_CASE "AR1008") &&
                   ("%destAre%" STRING_COMPARE_CASE "AR1009")) BEGIN
          READ_BYTE trigOff + 0x60 flag
          WRITE_BYTE trigOff + 0x60 flag | 0x4 // Add party-required flag
        END
      END
      PATCH_IF !("%SOURCE_RES%" STRING_COMPARE_CASE "AR1009") BEGIN
        READ_ASCII trigOff name
        PATCH_IF !("%name%" STRING_COMPARE_CASE "DOOR1010") BEGIN
          WRITE_ASCII trigOff + 0x38 AR1010 #8 // Set destination area to AR1010
        END
      END
      trigOff += 0xc4
    END
    // Update number of entrances
    READ_LONG 0x6c numEntr
    WRITE_LONG 0x6c numEntr + 0x1
    // Add exit points for travel from AR1008 and AR1009
    READ_LONG 0x68 entrOff
    entrOff += numEntr * 0x68 // Added as last entrance in file
    INSERT_BYTES entrOff 0x68
    WRITE_ASCII entrOff EXIT1010 // Entrance name
    PATCH_IF !("%SOURCE_RES%" STRING_COMPARE_CASE "AR1008") BEGIN
      WRITE_SHORT entrOff + 0x20 842 // Location X
      WRITE_SHORT entrOff + 0x22 307 // Location Y
      WRITE_LONG  entrOff + 0x24 15  // Facing direction
    END ELSE BEGIN // AR1009 patch
      WRITE_SHORT entrOff + 0x20 697 // Location X
      WRITE_SHORT entrOff + 0x22 259 // Location Y
    END
    READ_LONG 0x54 actOff
    PATCH_IF (actOff > entrOff) BEGIN
      WRITE_LONG 0x54 actOff + 0x68
    END
    READ_LONG 0x5c trigOff
    PATCH_IF (trigOff > entrOff) BEGIN
      WRITE_LONG 0x5c trigOff + 0x68
    END
    READ_LONG 0x60 sptOff
    PATCH_IF (sptOff > entrOff) BEGIN
      WRITE_LONG 0x60 sptOff + 0x68
    END
    READ_LONG 0x68 entrOff
    PATCH_IF (entrOff > entrOff) BEGIN
      WRITE_LONG 0x68 entrOff + 0x68
    END
    READ_LONG 0x70 contOff
    PATCH_IF !(contOff < entrOff) BEGIN
      WRITE_LONG 0x70 contOff + 0x68
    END
    READ_LONG 0x78 itmOff
    PATCH_IF !(itmOff < entrOff) BEGIN
      WRITE_LONG 0x78 itmOff + 0x68
    END
    READ_LONG 0x7c vertOff
    PATCH_IF !(vertOff < entrOff) BEGIN
      WRITE_LONG 0x7c vertOff + 0x68
    END
    READ_LONG 0x84 ambOff
    PATCH_IF !(ambOff < entrOff) BEGIN
      WRITE_LONG 0x84 ambOff + 0x68
    END
    READ_LONG 0x88 varOff
    PATCH_IF !(varOff < entrOff) BEGIN
      WRITE_LONG 0x88 varOff + 0x68
    END
    READ_LONG 0xa0 explOff
    PATCH_IF !(explOff < entrOff) BEGIN
      WRITE_LONG 0xa0 explOff + 0x68
    END
    READ_LONG 0xa8 doorOff
    PATCH_IF !(doorOff < entrOff) BEGIN
      WRITE_LONG 0xa8 doorOff + 0x68
    END
    READ_LONG 0xb0 animOff
    PATCH_IF !(animOff < entrOff) BEGIN
      WRITE_LONG 0xb0 animOff + 0x68
    END
    READ_LONG 0xb8 tobjOff
    PATCH_IF !(tobjOff < entrOff) BEGIN
      WRITE_LONG 0xb8 tobjOff + 0x68
    END
    READ_LONG 0xbc musOff
    PATCH_IF !(musOff < entrOff) BEGIN
      WRITE_LONG 0xbc musOff + 0x68
    END
    READ_LONG 0xc0 rspnOff
    PATCH_IF !(rspnOff < entrOff) BEGIN
      WRITE_LONG 0xc0 rspnOff + 0x68
    END
    READ_LONG 0xc4 mapnOff
    READ_LONG 0xc8 numMapn
    PATCH_IF (!(mapnOff < entrOff) && numMapn) BEGIN
      WRITE_LONG 0xc4 mapnOff + 0x68
    END
  END
BUT_ONLY_IF_IT_CHANGES

COPY_EXISTING AR1009.ARE OVERRIDE
  PATCH_IF (SOURCE_SIZE > 0x11c) BEGIN
    // Remove Dezkiel from AR1009 (he's now in AR1010)
    READ_LONG 0x54 actOff
    deleteCount = 0x0
    FOR (READ_SHORT 0x58 numAct; numAct; numAct -= 0x1) BEGIN
      READ_ASCII actOff + 0x80 char
      PATCH_IF !("%char%" STRING_COMPARE_CASE "DEZKIE") BEGIN
        DELETE_BYTES actOff 0x110 // You have been purged.
        deleteCount += 0x1        // Have a nice day!
      END ELSE actOff += 0x110
    END
    READ_SHORT 0x58 numAct
    WRITE_SHORT 0x58 numAct - deleteCount
    READ_LONG 0x54 actOff
    PATCH_IF ((actOff > actOff) && deleteCount) BEGIN
      WRITE_LONG 0x54 actOff - (deleteCount * 0x110)
    END
    READ_LONG 0x5c trigOff
    PATCH_IF (!(trigOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x5c trigOff - (deleteCount * 0x110)
    END
    READ_LONG 0x60 sptOff
    PATCH_IF (!(sptOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x60 sptOff - (deleteCount * 0x110)
    END
    READ_LONG 0x68 entrOff
    PATCH_IF (!(entrOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x68 entrOff - (deleteCount * 0x110)
    END
    READ_LONG 0x70 contOff
    PATCH_IF (!(contOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x70 contOff - (deleteCount * 0x110)
    END
    READ_LONG 0x78 itmOff
    PATCH_IF (!(itmOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x78 itmOff - (deleteCount * 0x110)
    END
    READ_LONG 0x7c vertOff
    PATCH_IF (!(vertOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x7c vertOff - (deleteCount * 0x110)
    END
    READ_LONG 0x84 ambOff
    PATCH_IF (!(ambOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x84 ambOff - (deleteCount * 0x110)
    END
    READ_LONG 0x88 varOff
    PATCH_IF (!(varOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0x88 varOff - (deleteCount * 0x110)
    END
    READ_LONG 0xa0 explOff
    PATCH_IF (!(explOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xa0 explOff - (deleteCount * 0x110)
    END
    READ_LONG 0xa8 doorOff
    PATCH_IF (!(doorOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xa8 doorOff - (deleteCount * 0x110)
    END
    READ_LONG 0xb0 animOff
    PATCH_IF (!(animOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xb0 animOff - (deleteCount * 0x110)
    END
    READ_LONG 0xb8 tobjOff
    PATCH_IF (!(tobjOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xb8 tobjOff - (deleteCount * 0x110)
    END
    READ_LONG 0xbc musOff
    PATCH_IF (!(musOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xbc musOff - (deleteCount * 0x110)
    END
    READ_LONG 0xc0 rspnOff
    PATCH_IF (!(rspnOff < actOff) && deleteCount) BEGIN
      WRITE_LONG 0xc0 rspnOff - (deleteCount * 0x110)
    END
    READ_LONG 0xc4 mapnOff
    READ_LONG 0xc8 numMapn
    PATCH_IF (!(mapnOff < actOff) && numMapn && deleteCount) BEGIN
      WRITE_LONG 0xc4 mapnOff - (deleteCount * 0x110)
    END
  END
BUT_ONLY_IF_IT_CHANGES
Posted by: devSin
« on: May 13, 2006, 11:40:25 PM »

You should just run the AR1010 patch on vanilla BG1, and then convert the result to Tutu (since all the structures should already be in place, you'd just update the resource references).

I'll fix Dezkiel tomorrow.
Posted by: icelus
« on: May 13, 2006, 10:42:31 PM »

OK, I manually made the edits to the ambients and the actors and stuff to the .are and copied it over to the override.  I was able to enter the area without any problems.  Unfortunately the exit to AR1008 isn't there, so I'll need to manually add that.

As for Dezkiel--yeah, he's showing up in AR1009 in both BG1 and Tutu, sorry.  :(

Getting to AR1010 works just fine in BG1, as does the exit.
Posted by: devSin
« on: May 13, 2006, 10:24:32 PM »

So, it really doesn't work (at all, ever, in any IE version)?
Posted by: icelus
« on: May 13, 2006, 10:23:06 PM »

Yeah, it was in BG1 and BG2.  :(
Sorry, when I did the quick test of that component I didn't think to check for Dezkiel.  I just went around CTRL-Y'ing everyone to make sure I could get to the area.
Posted by: devSin
« on: May 13, 2006, 10:20:41 PM »

Oh.  But he did show up, right in front of the door to AR1010.  :(
Fuck. Are you sure the resref is right? Did you ever check in BG1? If it doesn't work in BG2, it may not work in BG1, and I WILL LOOK LIKE A COMPLETE ASS.

Also, for Tutu, would it just be easier to make all the necessary changes to the FW1010.are file and copy it direct to the override?  Tutu doesn't include it, so...
That would work. The only problems should be the resrefs (screw Tutu), the TIS (screw IE), and possibly teh crash trying to load ambient WAVs from compressed BIFFs (screw Mark D.). You can SAY the rest spawn Strrefs.
Posted by: Macready
« on: May 13, 2006, 10:20:23 PM »

Hello -

Oh.  But he did show up, right in front of the door to AR1010.  :(

Also, for Tutu, would it just be easier to make all the necessary changes to the FW1010.are file and copy it direct to the override?  Tutu doesn't include it, so...

Just be wary of strrefs whenever you consider a straight file copy.  Rest spawns, map notes, whatever else.
Posted by: icelus
« on: May 13, 2006, 10:15:32 PM »

Oh.  But he did show up, right in front of the door to AR1010.  :(

Also, for Tutu, would it just be easier to make all the necessary changes to the FW1010.are file and copy it direct to the override?  Tutu doesn't include it, so...
Posted by: devSin
« on: May 13, 2006, 10:13:49 PM »

Also, Dezkiel is indeed showing up in AR1009, at least he's listed as an actor in NI.  :(
He will be, but he shouldn't show up when the area is loaded (he should just get purged). I decided not to delete the actor struct for obscure reasons (compatibility).
Posted by: Macready
« on: May 13, 2006, 10:10:46 PM »

Hello -

I think I might know what the problem is--the actors.  I don't think the RESREFs are present in BG2, so we need to convert them to the Tutu RESREFs...

(DEZKIE --> _DEZKIE, WOLWI --> _WOLFWI, BEARPO --> _BEARPO)

This is what DLTCEP spit out when I loaded the edited FW1010.are file:

Quote
Bad creature reference 'DEZKIE' in actor header #1 (DEZKIEL [1360.2362])
Bad creature reference 'WOLFWI' in actor header #2 (WINTER WOLF [2313.1590])
Bad creature reference 'WOLFWI' in actor header #3 (WINTER WOLF [2394.1690])
Bad creature reference 'WOLFWI' in actor header #4 (WINTER WOLF [1910.1092])
Bad creature reference 'WOLFWI' in actor header #5 (WINTER WOLF [2181.757])
Bad creature reference 'WOLFWI' in actor header #6 (WINTER WOLF [461.991])
Bad creature reference 'WOLFWI' in actor header #7 (WINTER WOLF [288.298])
Bad creature reference 'WOLFWI' in actor header #8 (WINTER WOLF [1309.704])
Bad creature reference 'WOLFWI' in actor header #9 (WINTER WOLF [1169.677])
Bad creature reference 'BEARPO' in actor header #10 (MOUNTAIN BEAR [1145.2126])
Bad creature reference 'BEARPO' in actor header #11 (MOUNTAIN BEAR [1525.2034])
Bad creature reference 'WOLFWI' in actor header #12 (WINTER WOLF [608.609])
Bad creature reference 'WOLFWI' in actor header #13 (WINTER WOLF [2077.466])
Invalid destination reference 'EXIT1010' for area 'AR1009' (causes crash) in active region #1 (DOOR1009 [926.21])
Missing ambient entry #1 in ambient #1 (CANDLEKEEP CATACOMBS 01 [320.320])
Ambient reference is 'AMB_N20A', ambient counter is 1
Missing ambient entry #1 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15A', ambient counter is 4
Missing ambient entry #2 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15B', ambient counter is 4
Missing ambient entry #3 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15C', ambient counter is 4
Missing ambient entry #4 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15D', ambient counter is 4
Missing ambient entry #1 in ambient #4 (GLOBAL HAUNTS 01 [1728.960])
Ambient reference is 'AMB_M35D', ambient counter is 2
Missing ambient entry #2 in ambient #4 (GLOBAL HAUNTS 01 [1728.960])
Ambient reference is 'AMB_M16X', ambient counter is 2

I looks like the area needs to be edited to connect to FW1009 instead of AR1009.

Also, ambients in Tutu generally have underscore resrefs (i.e., _MB... instead of AMB...).
Posted by: icelus
« on: May 13, 2006, 09:41:31 PM »

Also, Dezkiel is indeed showing up in AR1009, at least he's listed as an actor in NI.  :(
Posted by: icelus
« on: May 13, 2006, 09:36:04 PM »

I think I might know what the problem is--the actors.  I don't think the RESREFs are present in BG2, so we need to convert them to the Tutu RESREFs...

(DEZKIE --> _DEZKIE, WOLWI --> _WOLFWI, BEARPO --> _BEARPO)

This is what DLTCEP spit out when I loaded the edited FW1010.are file:

Quote
Bad creature reference 'DEZKIE' in actor header #1 (DEZKIEL [1360.2362])
Bad creature reference 'WOLFWI' in actor header #2 (WINTER WOLF [2313.1590])
Bad creature reference 'WOLFWI' in actor header #3 (WINTER WOLF [2394.1690])
Bad creature reference 'WOLFWI' in actor header #4 (WINTER WOLF [1910.1092])
Bad creature reference 'WOLFWI' in actor header #5 (WINTER WOLF [2181.757])
Bad creature reference 'WOLFWI' in actor header #6 (WINTER WOLF [461.991])
Bad creature reference 'WOLFWI' in actor header #7 (WINTER WOLF [288.298])
Bad creature reference 'WOLFWI' in actor header #8 (WINTER WOLF [1309.704])
Bad creature reference 'WOLFWI' in actor header #9 (WINTER WOLF [1169.677])
Bad creature reference 'BEARPO' in actor header #10 (MOUNTAIN BEAR [1145.2126])
Bad creature reference 'BEARPO' in actor header #11 (MOUNTAIN BEAR [1525.2034])
Bad creature reference 'WOLFWI' in actor header #12 (WINTER WOLF [608.609])
Bad creature reference 'WOLFWI' in actor header #13 (WINTER WOLF [2077.466])
Invalid destination reference 'EXIT1010' for area 'AR1009' (causes crash) in active region #1 (DOOR1009 [926.21])
Missing ambient entry #1 in ambient #1 (CANDLEKEEP CATACOMBS 01 [320.320])
Ambient reference is 'AMB_N20A', ambient counter is 1
Missing ambient entry #1 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15A', ambient counter is 4
Missing ambient entry #2 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15B', ambient counter is 4
Missing ambient entry #3 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15C', ambient counter is 4
Missing ambient entry #4 in ambient #2 (DRIPPING WATER 01 [320.320])
Ambient reference is 'AMB_E15D', ambient counter is 4
Missing ambient entry #1 in ambient #4 (GLOBAL HAUNTS 01 [1728.960])
Ambient reference is 'AMB_M35D', ambient counter is 2
Missing ambient entry #2 in ambient #4 (GLOBAL HAUNTS 01 [1728.960])
Ambient reference is 'AMB_M16X', ambient counter is 2
Posted by: icelus
« on: May 13, 2006, 09:06:33 PM »

AR1008 and AR1009 are working OK.  Well, FWx, that is.  When I transition from 1009 (I think that's the right one--the maze with the wizards), up to FW1010, it crashes.  The .bmps are all renamed, too.  Will fix the #8.