Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Dark Dreams of Furiae - a new module for NWN:EE! Buy now
Attention, new and old users! Please read the new rules of conduct for the forums, and we hope you enjoy your stay!

[SoD] Patching BDLEAT05.ITM

AndreaColomboAndreaColombo Member Posts: 5,326
I'm trying to patch BDLEAT05.ITM (the Dragonscale Armor in Siege of Dragonspear) to make its in-game colors better match its icon. The code I'm using is part of a much broader mod component that changes color offsets for most items in the game; every other item I'm patching is changing accordingly except BDLEAT05.ITM, which remains systematically untouched for reasons I cannot fathom.

My code:

ACTION_IF (FILE_EXISTS_IN_GAME ~bdleat05.itm~) THEN BEGIN COPY_EXISTING ~bdleat05.itm~ ~override~ PATCH_IF (SOURCE_SIZE > 0x71) THEN BEGIN LAUNCH_PATCH_MACRO ~clear~ SET gradient = 142 // colour index SET location = ablue // location LAUNCH_PATCH_MACRO ~colour~ SET gradient = 142 // colour index SET location = ared // location LAUNCH_PATCH_MACRO ~colour~ END BUT_ONLY END

The macros I'm using (which work flawlessly with all other items) were gently provided by Erephine (I have her written permission to use them):

DEFINE_ACTION_MACRO ~Locations~ BEGIN OUTER_SET agrey = 0 OUTER_SET ateal = 1 OUTER_SET apink = 2 OUTER_SET ayellow = 3 OUTER_SET ared = 4 OUTER_SET ablue = 5 OUTER_SET agreen = 6 END DEFINE_PATCH_MACRO ~clear~ BEGIN SET opcode_to_delete = 7 LAUNCH_PATCH_MACRO DELETE_ITEM_EQEFFECT SET opcode_to_delete = 8 LAUNCH_PATCH_MACRO DELETE_ITEM_EQEFFECT SET opcode_to_delete = 9 LAUNCH_PATCH_MACRO DELETE_ITEM_EQEFFECT END DEFINE_PATCH_MACRO ~colour~ BEGIN SET opcode = 7 // Set opcode SET target = 1 // target type SET timing = 2 // timing type SET power = 0 // power SET resist_dispel = 0 // dispel/resitance SET duration = 0 // duration SET probability1 = 100 // probability 1 SET probability2 = 0 // probability 2 SPRINT "resource" "" // resource SET dicenumber = 0 // dice number SET dicesize = 0 // dice size SET savingthrow = 0 // saving throw SET savebonus = 0 // saving throw bonus SET parameter1 = gradient // set colour gradient SET parameter2 = location // set location LAUNCH_PATCH_MACRO ADD_ITEM_EQEFFECT END

Any help would be appreciated; I just can't wrap my head around the reason why this particular item fails.



Sign In or Register to comment.