Is there an event for RightLeft hand equip?

Post » Tue Jun 19, 2012 3:29 pm

I'm looking for a simple way to detect when a weapon is equipped to a certain hand.

I would like to assign one variable a value based on the right hand weapon, and another variable a value based on the left hand weapon.

I've tried some things that seem to work sometimes, but they are not consistent or thorough.

I'm looking for it to update accurate values when a weapon is equipped and unequipped.


Thank you very much for any help! :-D
User avatar
Vahpie
 
Posts: 3447
Joined: Sat Aug 26, 2006 5:07 pm

Post » Wed Jun 20, 2012 3:04 am

Not a specific event, but you can use the ObObjectEquipped event and place a condition to check for a left or right hand weapon inside.

Event OnObjectEquipped(Form akBaseObject, ObjectReference akReference)if akBaseObject as Weapon		player = Game.GetPlayer()		if player.GetEquippedItemType(1) > 0;1 is the right hand, 0 is the left hand		....        endifendifendEvent

Of course, this means the condition is met every time you equip a weapon and have something in your right hand. This does not check if the weapon you equipped actually went into the right hand, so the condition will also be met when you have a weapon in your right hand and equip something into your left. I'm not sure what you are actually trying to do, but maybe this can get you on the right track.
User avatar
Sabrina Steige
 
Posts: 3396
Joined: Mon Aug 20, 2007 9:51 pm

Post » Tue Jun 19, 2012 5:34 pm

Thank you! :-)

I think I've got it NEARLY working properly :-P
User avatar
Makenna Nomad
 
Posts: 3391
Joined: Tue Aug 29, 2006 10:05 pm


Return to V - Skyrim