@ killap
The new Lenny base proto has the wrong AI. He has Vic custom, should obviously be Lenny custom. Haven't played with him but would assume this will lead to the same problems as Cassidy had earlier. Actually, looking at it the original base proto has the same bug and is resetting his combat settings just like Cassidy did. WTF? Why has no one noticed this before? I guess he's not popular enough for anyone to care.
So need to fix the proto and add to the Master.dat file and I suppose the map needs to be updated as well.
Bugged shopkeepers and general barter behavior:
Some sell their personal guns and ammo, stuff that are in their item slots from the beginning but that end up in their for sale inventory.
They don't put their weapons in a tempbox so they get added to the shop inventory in the barter screen. Some of them lose their weapons When their shop inventory is removed.
Others who use a tempbox to separate own and shop inventory, can't put their weapons back in their item slots and will therefor let you steal them (which you can't do before talking to them so it feels unintended).
Steal screen shows only items in inventory. The barter screen shows inventory items plus item in slot 1 as long as slot 2 contains an item.
If slot 2 is empty, an item in slot 1 will not show up in the barter screen.
If a critter has empty item slots and a weapon in his inventory, he will equip that weapon when you go to the barter screen (so you can't buy it).
When you exit the barter screen the weapon will be unequipped again
If a critter has more than one weapon (in inventory + empty item slots), he will equip the one last in his inventory (from top to bottom), and as it gets unequipped it gets put at the top of his inventory. The effect of this is that he will switch weapon he equips every time you push the barter button (unless he has multiple amounts of the last weapon ofc, as then he will only switch between those).
So why was it made like this? My guess is to make sure a critter you barter with won't sell you all his weapons (so he always have one for himself).
Just that it don't work too well with critters who have non-weapon items equipped in their item slot 2. Also pretty stupid that a critter equips a shop item (and thereby withholds it from you) as he can't use it himself anyway.
Code:
Some critters affected by selling their weapon bug:
Rebecka - Combat knife and stimpack.
Frankie - 10mm pistol and psycho.
Monte - Desert Eagle and JHP ammo.
most New Reno Drug dealers - some pistol and various items (hard to fix this one as many critters have this script).
RCLOU - Desert Eagle and FMJ ammo.
Rose - Desert Eagle and JHP ammo.
Chad - 10mm SMG and stimpack.
There's probably more, but these where the ones I checked.
I don't know the best way to fix this. Could remove the items they have in slot 2 (but then you will be able to steal that) or create the stuff in the combat procedure.
Code:
Lose their weapons When their shop inventory is removed (shop_box but no tempbox, so their own weapons are added to the shop box):
Duntons - Spiked knuckles. [Why have the create spiked knuckles code been moved from combat procedure to map enter procedure?
That is no good. As it is now you can steal them until you have talked to them. After that you can buy them as they get moved to the shop inventory (since there are 2 Duntons). But most importantly, they won't have any spikes knuckles to fight with after you've talked to them.]
Sajag - Pipe Rifle in slot and ammo in inventory. [Someone fucked up here as he don't have a rifle animation, and he spawns a club in his combat procedure. Should probably just remove the rifle and ammo from the map. Alternative is to give him the proper animation and put his stuff in a tembox while talking to him.]
I think the reason those two spawn weapons in their combat procedure is so a tempbox is not needed.
Balthas - Sledgehammer, make him create it in combat procedure or put it in a tempbox. Also, you don't get his shop stuff when he dies (shop_box not moved to self_object).
I noticed that critters won't equip their weapons while in combat by themselves if you stand in an adjacent hex, so might wanna think on adding the wield_obj code to the combat procedure. Make sure they only do it once though!
Code:
Jagged Jimmy J, Jules and some New Reno drug dealers - Disarm when you leave their barter screen, so then you can steal their weapons. The auto arm/disarm doesn't take into account if they already had a weapon equipped, it will unequip it anyway. Don't have a shop box, so they get to keep their weapons at least.
Code:
Can steal weapon from these (items removed from item slots to tempbox, can't be put back in item slots):
Tubby - Club and a jet.
Smitty - 10mm pistol and ammo.
HCLIZ - 14mm pistol.
Bill (BH) - Combat knife.
Moms - Knife.
Jo - Shothun and shells.
Happy Harry - 10mm SMG.
Mordino Bartender - 10mm pistol and ammo.
Eldrige - 14mm pistol, ammo and a combat leather armor.
Bishop Bartender - 10mm SMG.
Metzger - Shothgun and shells.
Maybe not a big issue and changing things might upset a few kleptomaniacs, but I don't think you should be able to steal those things.
They were put in their item slots so you can't take them. Talk to them once and all of a sudden you can. Yeah, that makes sense.
Unless there's a way to put the items back in the item slots, I suggest removing them and and create them in the combat procedure instead.
Drug dealer - Den residential - guns are removed when you enter map.
Code:
global_temp := create_object_sid(128, 0, 0, -1);
move_obj_inven_to_obj(self_obj, global_temp);
destroy_object(global_temp);
So you create a tempbox, put their guns in it and destroy the box. Not a good idea.
What i would like too see is the auto equip/unequip feature in barter screen removed through sfall. It's just too flawed.
Also would be nice with a command added to sfall, letting you put items into critters respective item slots.
Meh, I don't know, it's a mess, just like this report.
Fix anything you can/want to. I can understand if you don't want to touch most of the stuff.