Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Joined: Nov 2010
J
apprentice
OP Offline
apprentice
J
Joined: Nov 2010
before the patch your henchmen leveled up to your level when you bought them, so you could sort of build them yourselves, is it possible to return that now broken feature, through modding?

Joined: Nov 2010
J
apprentice
OP Offline
apprentice
J
Joined: Nov 2010
Really nothing and no one on this?

Joined: Aug 2014
J
stranger
Offline
stranger
J
Joined: Aug 2014
I'm also interested, if anyone has any ideas on what to mod to get this to work, please share!

Joined: Jul 2014
R
addict
Offline
addict
R
Joined: Jul 2014
I'm not sure about getting it to trigger right when you buy them, but it should be somewhat straightforward for a story script to check the henchman's levels compared to the main character's levels, and then calling the level up function until it's equal. The trigger I would use would be something like DialogEnded, which is something that can be performed at will when necessary after purchasing the henchman.

The problem would come with identifying who the henchman is (or what their character template is) for the level up.

Joined: Nov 2010
J
apprentice
OP Offline
apprentice
J
Joined: Nov 2010
So, if it can be done, can some enterprising person get on this? thank you in advance.

Joined: Apr 2013
N
addict
Offline
addict
N
Joined: Apr 2013
Something like this should work (only tested on a small test map):

Code
INIT:
DB_MainPlayers(CHARACTER_Player1);
DB_MainPlayers(CHARACTER_Player2);
DB_MainPlayers(CHARACTER_Jahan);
DB_MainPlayers(CHARACTER_Madoc);


KB:
// Sync henchman level when joining the party
IF  CharacterIsPlayer(_Henchman)
AND DB_HenchmanPool(_Henchman)
AND CharacterIsPartyMember(_Henchman, 1)
THEN
	PROC_SyncHenchmanLevel(_Henchman, CHARACTER_Player1);

// Iterate over all henchmen and sync their levels whenever the first PC has leveled up
IF  CharacterLeveledUp(CHARACTER_Player1)
AND DB_HenchmanPool(_Henchman)
AND CharacterIsPartyMember(_Henchman, 1)
THEN
	PROC_SyncHenchmanLevel(_Henchman, CHARACTER_Player1);

// Level up the henchman if its underlevelled
PROC PROC_SyncHenchmanLevel((CHARACTER)_Henchman, (CHARACTER)_SyncToCharacter)
AND CharacterGetLevel(_Henchman, _HenchmanLevel)
AND CharacterGetLevel(_SyncToCharacter, _SyncCharacterLevel)
AND IntegerSubtract(_SyncCharacterLevel, _HenchmanLevel, _LevelDifference)
AND _LevelDifference > 0
THEN
	CharacterLevelUp(_Henchman);
	// Call the level sync recursively in case the henchman is multiple levels behind the main PC
	PROC_SyncHenchmanLevel(_Henchman, _SyncToCharacter);


Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5