Jump to content

Do cres drop all their assigned items or is there a limit? [split from Please check my install list (2.6 EET)]


Gwaihir

Recommended Posts

Allright then, it is as I suspected. Kind of annoying, but not too bad I guess. The worst part will be paying attention on the number of drops from enemies. In Davaeorn's case, I knew what item to look for, but it might not be the case for others, so might be difficult to even realize if something's missing. There is indeed such a thing as too many mods. Oh well.

Link to comment

I checked my old (2.5, SCS v33) modded install. In that, the SCS random potions are at the end of the inventory slots used, because that's what the functions involved do when they add items. I don't see any good reason for that to have changed, but SCS is a big project and weird stuff sneaks in sometimes.

The items in that inventory before things start getting added: the key, three letters, and three specific low-level scrolls. A fourth scroll is in one of the quickslots. SCS adds a couple of no-drop items for scripting stuff, and then the random potions. The other two quickslots are used for the AC 6 bracers and archmage robes in vanilla; SCS moves those to be actually equipped by Dave and another mage earlier in the dungeon.

Link to comment

@jmerry This is how ADD_CRE_ITEM works though. When the inventory is already filled up, it'll start replacing the first item with the newly added one. The doc even mentions this.

Quote

ADD_CRE_ITEM will add the item to the first empty slot in the list. If no slot is empty, the item will be placed in the first slot in the list and the item that previously occupied the slot will be moved to the general inventory. If the general inventory is full, the moved item will be discarded.

 

Link to comment
Guest Graion@Work

Unless someone else won't be faster, I'll try to come up with something during the week. I'll need this for my random spell scrolls afterall since those should come even after SCS and while my ADD_CRE_ITEM call includes quick item slots alongside inventory, that's still not fully foulproof and I still shouldn't add anything if both are filled up. If something looks satisfactory to me, I'll share it in the common macros thread.

Link to comment
3 hours ago, Magus said:

Should be pretty trivial to write a safer function, no?

Well, it's a question of, where do you want a failure to be? It shouldn't be hard to check whether an item has the 'critical item' flag, but if it does, should the function fail to add the mod-added item? What if that item is critical to the functioning of the mod?

These are very much edge-case considerations, to be sure, but apparently Gwaihir has hit an edge case. (And FWIW, I distinctly remember having the same problem when I last played BG1 a couple years ago.)

For me the bigger question is, why couldn't it find an empty inventory slot? Is Davaeorn's inventory full?? He's a one-shot enemy who only appears for about five minutes! what is this guy carrying around in his pockets???

EDIT - oh I see, Gwaihir posted a list. I see several modder prefixes there, and several added items without prefixes (but let's not get into that again). The vanilla version has nine open inventory slots; it looks like SCS adds 4 items, the "DS" mod adds two, the "DTK" mod adds two, some unknown mod adds "ogi.itm," and that right there is the nine free slots taken up. Add a potion or two and something's got to give.

Frankly, rather than hope a new/better function gets into Weidu anytime soon, what should really happen is mods that add things to bosses' inventory should first check bosses inventory for critical items, and simply remove and add back the critical item after the mod is done adding its own things. This would guarantee no critical items get lost, and the effort would be fairly minimal...

EDIT - worth considering, why the heck does this boss have two 1st-level spell scrolls, at this point in the game?? What player is going to care about finding scrolls of Shield, ProEvil, and ProPetrification? And if they are loot, why weren't they put into the nearby loot chest?

Tagging @DavidW even though it is very much not his responsibility, but as long as SCS is doing stuff here anyway, it might be worth removing that trash.

Edited by subtledoctor
Link to comment

The Lv1 spell scrolls are there by default. There are some other ways to decrease this though. Arcane Treasury (MORING9/SPHRIN1), DSotSC and SoD2BG2IU - @Daeros_Trollkiller FYI -  should have tried to equip their items first and not add everything just for loot without affecting the fight anyway (ADD_CRE_ITEM accepts a list afterall although the robes are discussable). Additionally, the ogi.itm is also SoD2BG2_IU because it doesn't use prefixes for items copied out from IWD/SoD.

My original train of though is to just not add anything if every possible slot is filled up already. "Required" items are not always marked as critical and I wouldn't bother with a static list on this one.

Link to comment

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...