Jump to content


Photo

Comments on the aTweaks releases


  • Please log in to reply
63 replies to this topic

#1 Salk

Salk
  • Modder
  • 1419 posts

Donator

Posted 28 December 2008 - 03:21 PM

Very nice!

Thanks, aVenger!

May I ask if you know anything about the compatibility of some of your components and Spell Revisions?

I am speaking of:

- Prevent skeletal undead from being affected by Illithids' Devour Brain attack
- Change Spiritual Hammer into a ranged force weapon
- Allow Dispel/Remove Magic to take down Globes of Invulnerability
- Allow Breach to take down Stoneskin effects applied by items

Have you any idea of such modifications are already present or are incompatible with Spell Revisions?

Thanks!

#2 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 28 December 2008 - 04:50 PM

May I ask if you know anything about the compatibility of some of your components and Spell Revisions?

I am speaking of:

- Prevent skeletal undead from being affected by Illithids' Devour Brain attack
- Change Spiritual Hammer into a ranged force weapon
- Allow Breach to take down Stoneskin effects applied by items


These three changes are actually made by patching items, rather than spells, so I don't think there should be any compatibility problems there.

- Allow Dispel/Remove Magic to take down Globes of Invulnerability


This change modifies the Globe spells with a very simple patching technique which should also be compatible with pretty much anything. I haven't tested it with SR specifically, as I don't use that mod, but I don't think there should be any problems there either. Just remember to install aTWEAKS after the main components of SR (as they overwrite spell files). Basically, as long as this component installs successfully it should work properly.

Edited by aVENGER, 28 December 2008 - 04:55 PM.


#3 Azazello

Azazello

    The Anti-Spammer

  • Staff
  • 1912 posts

Posted 28 December 2008 - 04:59 PM

Awww man! aVENGER you are so awesome!
Posted Image

And a return to my favorite spelling convention. :lol:

Edited by Azazello, 28 December 2008 - 04:59 PM.

"I gladly simp for jastey" -- Aza
==========================================================
"You ever notice that "What the hell?!" is the answer to just about everything?"
==========================================================

"Girls are like phones, they like to be held and talked too, but if you press the wrong button, you will be disconnected!" DJ Nikodemus
================================================================
Community Contributions
* Level 1 NPCs * gMinion: expanded TP2 for MegaInstalls * PSM (PSQM): expanded scripts for Melanthium * Shar Nadal (DSotSC-BGT) revision * non-detectable Cloak of Non-Detection ?? * Weimer's-Tactics: revised TP2 for MegaInstalls * a directory of Mega-Installation Guides *

   
   
   


#4 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 28 December 2008 - 05:40 PM

Awww man! aVENGER you are so awesome!
Posted Image


Heh. :P

And a return to my favorite spelling convention. :lol:


Yup. Feel free to call this aPack instead of aTWEAKS if you prefer. :) In this case, both names are equally valid. :cheers:

#5 Demivrgvs

Demivrgvs
  • Member
  • 143 posts

Posted 29 December 2008 - 01:58 AM

May I ask if you know anything about the compatibility of some of your components and Spell Revisions?

I am speaking of:

- Prevent skeletal undead from being affected by Illithids' Devour Brain attack
- Change Spiritual Hammer into a ranged force weapon
- Allow Breach to take down Stoneskin effects applied by items


These three changes are actually made by patching items, rather than spells, so I don't think there should be any compatibility problems there.

- Allow Dispel/Remove Magic to take down Globes of Invulnerability

This change modifies the Globe spells with a very simple patching technique which should also be compatible with pretty much anything. I haven't tested it with SR specifically, as I don't use that mod, but I don't think there should be any problems there either. Just remember to install aTWEAKS after the main components of SR (as they overwrite spell files). Basically, as long as this component installs successfully it should work properly.

- SR's summoned skeletons, Skeletal Warrior, and Death Knight are already immune to Devour Brain, but aVENGER's patch may affect non-summoned ones.
- SR's Spiritual Hammer is already coded to be a "ranged" weapon with no penalties in melee just like PnP, and damage type will be changed from crushing to magic, making this tweak completely reduntant if SR is installed.
- IR's items with stoneskin effects are already breachable, but aVENGER's tweak will affect NPC's "custom/non droppable" items which I haven't touched thus if the patch does work over IR it's a fine addition.
- SR's MGoI and GoI are already coded to be dispellable, thus this tweak is redundant with SR unless there are innates with GoI effects which I haven't touched.

- 'Consistently spell-like Bhaalpowers' is already included within SR if you install it, and it also make sure SR's spells are used instead of vanilla's ones.

Great work as always aVENGER! :cheers:

#6 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 29 December 2008 - 11:43 AM

- SR's summoned skeletons, Skeletal Warrior, and Death Knight are already immune to Devour Brain, but aVENGER's patch may affect non-summoned ones.


That's correct. aTWEAKS will grant this immunity to non-summoned Skeletons and Skeleton Warriors as well.

#7 -Guest-

-Guest-
  • Guest

Posted 04 January 2009 - 07:20 AM

Hello.
Innate abilities, no matter spell-like or combat ones, are affected by spell failure caused by wild surge, miscast magic, silence, etc. Have you got this problem fixed in your tweak pack?
Thank you for your efforts.

#8 -Guest-

-Guest-
  • Guest

Posted 04 January 2009 - 07:46 AM

Sorry. I fogot to mention that the innate ability failure is a problem in a vanilla game, not your lovely little mod :)

#9 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 04 January 2009 - 08:36 AM

Hmm, I've done a quick scan of the innates and, as far as I can see, most warrior abilities are not affected by Miscast Magic and/or Wild Surges even in the unmodded game. However, for some reason Barbarian Rage and the secondary effect of Berserker Enrage (becoming winded) appear to be susceptible to those effects. I can fix this through my own mod but I'd rather report it in the G3 BG2 Fixpack forum as this is a core game bug.

BTW, all innates even clearly non-magical ones like Set Snare and Offensive Spin are affected by Silence. Sadly, I believe this is hardcoded. As for the spell-like innates (i.e. Cure Light Wounds and Vampiric Touch) their coding is fairly uniform so I think the original developers probably intended for them to be affected by Miscast Magic and Wild Surges.

#10 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 04 February 2009 - 11:01 PM

A small remark: due to engine limitations, the following components of aTweaks will only work properly if a new game is started:
  • Slightly expanded storage capacity for containers
  • Expanded temple services
The other aTweaks components should work fine even if they are installed mid-game.

#11 Azazello

Azazello

    The Anti-Spammer

  • Staff
  • 1912 posts

Posted 06 February 2009 - 03:56 PM

aTweaks Suggestion/Request:
{get it?-- " 'a' Tweaks Request" ...ahem}

Changing the music of the Bard Song.

I remember there's a thread about this somewhere on G3. Salk first suggested it, I think. I hope he jumps in with other suggestions.

My own pitch is adding songs that last much longer than the little vanilla ding; or songs that act like battle music (probably not a good idea if it extends SongList.2da).

Since you've done some recent work on Bard Songs, perhaps you see some potential in this.

#12 -Guest-

-Guest-
  • Guest

Posted 07 February 2009 - 09:41 PM

There is a minor bug in the 'Expanded temple services' component that doesn't properly update the items_for_sale offset once a new temple service is added. As a result, some of the store items overlap in between the cures, and sometimes even turn into corrupted (null) items.

#13 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 08 February 2009 - 12:45 AM

Changing the music of the Bard Song.


That's a nice idea, but due to the technical implementation of the bard songs (mainly their quirky timing mode), I don't know how feasible it would be.

Nonetheless, I'll look into it when I get a chance.

#14 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 08 February 2009 - 12:48 AM

There is a minor bug in the 'Expanded temple services' component that doesn't properly update the items_for_sale offset once a new temple service is added. As a result, some of the store items overlap in between the cures, and sometimes even turn into corrupted (null) items.


Damn, I was pretty sure I had that sorted out. :(

Since DLTCEP doesn't directly report any irregularities in the patched stores, here's the relevant tp2 code. Feel free to point out the part which seems to be causing this issue.

COPY_EXISTING_REGEXP GLOB ~^.+\.sto$~ ~override~									  // parses through all stores in the game (even those added by mods)
  READ_LONG 0x34 "sale_offset"
  READ_LONG 0x38 "sale_num"
  READ_LONG 0x2c "item_offset"
  READ_LONG 0x4c "drink_offset"
  READ_LONG 0x70 "cure_offset"
  READ_LONG 0x74 "cure_number"
PATCH_IF ("%cure_number%" > 0) BEGIN												  // Only patch stores which offer temple services
  SET "count" = 0																	 // New cure count
  FOR (index = 0; index < cure_number; index = index + 1) BEGIN
	READ_ASCII ("%cure_offset%" +		("%index%" * 0x0c)) "cure"
	PATCH_IF ("%cure%" STRING_EQUAL ~SPPR307~) AND (NOT FILE_CONTAINS_EVALUATED(~%SOURCE_FILE%~ ~SPPR317~)) BEGIN  // Add Cure Disease below Remove Curse if not already available in the temple
	  INSERT_BYTES  ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) 0x0c
		WRITE_ASCII ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) ~SPPR317~ #8  // spell reference (Cure Disease)
		WRITE_LONG  ("%cure_offset%" + 0x08 + (("%index%" + 1) * 0x0c)) 200		   // spell price
	SET "count" = ("count" + 1)												   // update new cure count
	END
	PATCH_IF ("%cure%" STRING_EQUAL ~SPPR401~) AND (NOT FILE_CONTAINS_EVALUATED(~%SOURCE_FILE%~ ~SPPR404~)) BEGIN  // Adds Neutralize Poison below Cure Serious Wounds if not already available in the temple
	  INSERT_BYTES  ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) 0x0c
		WRITE_ASCII ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) ~SPPR404~ #8  // spell reference (Neutralize Poison)
		WRITE_LONG  ("%cure_offset%" + 0x08 + (("%index%" + 1) * 0x0c)) 250		   // spell price
	SET "count" = ("count" + 1)												   // update new cure count
	END
	PATCH_IF ("%cure%" STRING_EQUAL ~SPPR404~) AND (NOT FILE_CONTAINS_EVALUATED(~%SOURCE_FILE%~ ~SPPR417~)) BEGIN  // Adds Lesser Restoration below Neutralize Poison if not already available in the temple
	  INSERT_BYTES  ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) 0x0c
		WRITE_ASCII ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) ~SPPR417~ #8  // spell reference (Lesser Restoration)
		WRITE_LONG  ("%cure_offset%" + 0x08 + (("%index%" + 1) * 0x0c)) 250		   // spell price
	SET "count" = ("count" + 1)												   // update new cure count
	END
	PATCH_IF ("%cure%" STRING_EQUAL ~SPPR502~) AND (NOT FILE_CONTAINS_EVALUATED(~%SOURCE_FILE%~ ~RR#PR514~)) BEGIN  // Add Mass Cure below Cure Critical Wounds if not already available in the temple
	  INSERT_BYTES  ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) 0x0c
		WRITE_ASCII ("%cure_offset%" + 0x00 + (("%index%" + 1) * 0x0c)) ~RR#PR514~ #8 // spell reference (custom Mass Cure, targets party)
		WRITE_LONG  ("%cure_offset%" + 0x08 + (("%index%" + 1) * 0x0c)) 300		   // spell price
	SET "count" = ("count" + 1)												   // update new cure count
	END
  END
   WRITE_LONG 0x74 ("%cure_number%" + "%count%")									  // update total number of available cures
// correct offsets
READ_LONG 0x74 "cure_number"
READ_LONG 0x2c "sale_offset"
READ_LONG 0x2c "item_offset"
READ_LONG 0x4c "drink_offset"
	PATCH_IF NOT ("%item_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x2c ("%item_offset%" + ("%count%" * 0x0c))
	END
	PATCH_IF NOT ("%drink_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x4c ("%drink_offset%" + ("%count%" * 0x0c))
	END
	PATCH_IF NOT ("%cure_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x70 ("%sale_offset%" + ("%count%" * 0x0c))
	END
END
BUT_ONLY_IF_IT_CHANGES


#15 -Guest-

-Guest-
  • Guest

Posted 08 February 2009 - 06:55 AM

I think it's here:

// correct offsets
READ_LONG 0x74 "cure_number"
READ_LONG 0x2c "sale_offset"	// shouldn't it be 0x34 ?
READ_LONG 0x2c "item_offset"
READ_LONG 0x4c "drink_offset"
	PATCH_IF NOT ("%item_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x2c ("%item_offset%" + ("%count%" * 0x0c))
	END
	PATCH_IF NOT ("%drink_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x4c ("%drink_offset%" + ("%count%" * 0x0c))
	END
	PATCH_IF NOT ("%cure_offset%" < "%sale_offset%") BEGIN
	  WRITE_LONG 0x70 ("%sale_offset%" + ("%count%" * 0x0c))
	END
END
BUT_ONLY_IF_IT_CHANGES

also, I think there are a few more conditions to be considered (for example, in one of the stores (Madeel.STO from TDD), %cure_offset% is less than %sale_offset%, but doesn't meet any of the above conditions and thus, %sale_offset% will not be updated to reflect the newly added cures (instead the items for sale overlaps over the cures).

#16 -Guest-

-Guest-
  • Guest

Posted 08 February 2009 - 07:09 PM

Just to make sure I'm describing the problem correctly - I think the 'expanded temple services' component expects the offset information to be in some systematic order. something like the following (correct me if I'm wrong Avenger).

1. Drinks

2. Items for Sale

3. Cures

4. Items purchased

Unfortunately, some mod-added stores swap this order around arbitrarily, and when you patch them some parts get messed up. In such cases, it's probably best to skip patching those stores. A more sophisticated algorithm to realign the order back to the "default" way is probably doable, but I'm not sure if it's worth spending time on that.

#17 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 08 February 2009 - 10:50 PM

READ_LONG 0x2c "sale_offset" // shouldn't it be 0x34 ?


Yup, that's definitively a typo, but unfortunately, correcting it doesn't resolve the issue (it actually worsens it).

Unfortunately, some mod-added stores swap this order around arbitrarily, and when you patch them some parts get messed up. In such cases, it's probably best to skip patching those stores. A more sophisticated algorithm to realign the order back to the "default" way is probably doable, but I'm not sure if it's worth spending time on that.


Yes, this seems to be a large part of the problem. According to my testing, in the current form (even with the typo) the code will properly patch all unmodded BG2, BGT and TuTu stores (since they are indexed correctly) but it will choke on some mod added stores which are indexed in a non-standard manner and may even corrupt them. I'll see what I can do about that, and in the mean time, I wouldn't recommend using the "Expanded temple services" component on a megamod install.

#18 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 09 February 2009 - 11:03 PM

Ok, I think I've managed to resolve this in v2.01.

Could someone try installing the latest version of aTweaks over TDD and similar mods and check whether it still corrupts their stores?

#19 -Guest-

-Guest-
  • Guest

Posted 11 February 2009 - 03:11 PM

Just tried the new version; looks like everything's indexed correctly now.

Good stuff. :cheers:

#20 aVENGER

aVENGER
  • Modder
  • 1680 posts

Posted 20 April 2009 - 11:52 PM

Just a small compatibility note here: the "Additional racial traits for Dwarves" and "Additional racial traits for Gnomes" components of aTweaks are fully compatible with the "Giants Receive Penalties When Attacking Halflings, Dwarves, and Gnomes" component of the G3 BG2 Fixpack.

As long as the fixpack component is installed first, aTweaks will detect and complement it without needlessly duplicating any content.