Jump to content

Access to all installed kits during character generation (implemented)


Recommended Posts

*Split from "BG2 Level Up support (partial), Implemented level up" topic:*


(...)Speaking about kit selection:




There's still a place for one more kit without need for scrolling, and may be moved by little pixels to fit the fashion from the very similar racial enemy selection window in vanilla bg2 :party:


Done :) This is what is currently in the trunk on example of my tdd+divine remix install (as you can see the elf can choose among 20 cleric kits):





But actually my kitlist.2da has 26 cleric kits entries, but some of them are skipped because are not assignable to a race and original engine does the same thing. This behaviour is not consistent with mage kits selection window, where when the race cannot become the specific specialist it's button is disabled, not skipped. Since we have far more control on GUI in GemRB maybe we should transfer this behaviour to other class kits windows: load all kits that are installed and disable buttons of not selectable by race kits? What do you think?

Link to comment

I don't support too much hacking (of the original gemrb), it should be similar to the original whenever possible.

This could seriously impact gui mods, which may expect that a window is used for a specific purpose.

Adding a control may be fine (but switching windows isn't).


(gemrb modpacks are fine, in an optional folder).

Link to comment
This could seriously impact gui mods, which may expect that a window is used for a specific purpose.


I think you already did similar simplification, in GUICG22.py, ironically :)


	#there is a specialist mage window, but it is easier to use
#the class kit window for both
KitWindow = GemRB.LoadWindowObject(22)
if ClassID == 1:
	Label = KitWindow.GetControl(0xfffffff)


So to follow that rule we would need fork the gui script for mage specialists window, but more importantly afaik all gui mods out there expect hacking exe to accomplish it's final effect, that in case of gemrb impacts their purpose more heavily, i guess :party: Besides i think loading all kits, and disabling some of them for selection would be rather transparent to all non-gui mods.


edit: some preliminary code i wrote:

AllKitsIndexes = []
AllKitsCount = 0
ClassColumnIndex = KitListTable.GetColumnIndex("CLASS")
for i in range(KitListTable.GetRowCount()):
	print("i: " + str(i)+" KitListSearchIndex: "+ str(KitListSearchIndex))
	if KitListTable.FindValue(ClassColumnIndex, ClassID, KitListSearchIndex) != -1:
		RowNr = KitListTable.FindValue(ClassColumnIndex, ClassID, KitListSearchIndex)
		print("RowNr: " + str(RowNr))
		AllKitsIndexes.append(KitListTable.GetValue(RowNr, 0))
		print("AllKitsIndex[" + str(AllKitsCount) + "]: " + str(AllKitsIndexes[AllKitsCount]))
		AllKitsCount += 1
		KitListSearchIndex = RowNr + 1
print ("AllKitsCount: " +str( AllKitsCount))


Finds and counts the 26 cleric kits entries nicely, but in case of figthers it counts Barbarian too :/

Link to comment


This topic is now archived and is closed to further replies.

  • Create New...