Question About Auto Perk Script

Post » Tue Sep 24, 2013 4:45 am

Spoiler

Scriptname AutoQuickShotPerk extends ObjectReference   spell property crossbowSpell auto ; Fix idea from RolandSirPerk Property QuickshotPerk autoInt PlayerHasPerk = 0 Event OnEquipped(Actor akActor)akActor.addSpell(crossbowSpell,false) if (akActor == Game.GetPlayer() && Game.GetPlayer().HasPerk(QuickshotPerk))PlayerHasPerk = 1Game.GetPlayer().RemovePerk(QuickshotPerk)endifendEvent Event OnUnequipped(Actor akActor)akActor.removeSpell(crossbowSpell) if (akActor == Game.GetPlayer() && PlayerHasPerk == 1)Game.GetPlayer().AddPerk(QuickshotPerk)endifendEvent

I was looking at this script and I might misunderstand what it's doing. It seems like it adds a perk if you don't have it. Then when the weapon is unequipped it removes the perk. So what If I chose the perk in the perk tree. Won't it remove that perk after I switch to another weapon. If I spent a Perk Point after leveling to obtain it normally I don't want the perk removed. I don't want to have to keep just that one weapon equipped.
User avatar
Juanita Hernandez
 
Posts: 3269
Joined: Sat Jan 06, 2007 10:36 am

Post » Tue Sep 24, 2013 3:15 am

When you equip the item this script is attached to, the script checks to see if you have the Quick Shot perk and if you do, removes it.

When you then unequip the item, the script adds the perk again if it previously removed it.

User avatar
Josh Trembly
 
Posts: 3381
Joined: Fri Nov 02, 2007 9:25 am


Return to V - Skyrim