InventoryWeight Actor Value

Post » Mon Jun 18, 2012 7:01 am

Is the InventoryWeight Actor Value actually used? CarryWeight seems to work okay, but InventoryWeight doesn't seem to function at all for me, either via Papyrus or via console commands.

(I have a status box that shows a follower's current stats, and would like to show their current and maximum encumbrance.)
User avatar
marie breen
 
Posts: 3388
Joined: Thu Aug 03, 2006 4:50 am

Post » Mon Jun 18, 2012 10:49 am

InventryWeight has been working fine for me.
User avatar
..xX Vin Xx..
 
Posts: 3531
Joined: Sun Jun 18, 2006 6:33 pm

Post » Mon Jun 18, 2012 5:08 pm

Hmm, then do you see anything wrong with this code?

Function ShowStatusBox(ObjectReference FollowerRef)	actor FollowerActor = FollowerRef as Actor	int iCurrentWeight = FollowerActor.GetAV("InventoryWeight") as int	int iMaxWeight = FollowerActor.GetAV("CarryWeight") as int

If I show a debug messagebox with both values, iCurrentWeight always seems to be 0, even when I give the follower some loot. iMaxWeight however seems to be correct.
User avatar
Laura Samson
 
Posts: 3337
Joined: Wed Aug 29, 2007 6:36 pm

Post » Mon Jun 18, 2012 10:15 am

I'm using InventoryWeight on the Player...don;t know if that makes any difference. But it is working OK.
User avatar
-__^
 
Posts: 3420
Joined: Mon Nov 20, 2006 4:48 pm

Post » Mon Jun 18, 2012 9:10 pm

Yeah, that's exactly what it is--InventoryWeight works on the player, but it doesn't seem to work on NPCs. Thanks for your help figuring that out. I guess Bethesda do the calculations for follower encumbrance in the Flash UI system, so didn't need to keep track of that actor value in-game.
User avatar
N3T4
 
Posts: 3428
Joined: Wed Aug 08, 2007 8:36 pm


Return to V - Skyrim