Jump to content

Help unequip current item SCRIPT


Koalmex

Recommended Posts

Posted

Ok.

If you want to unequip a specific piece of armor from the player, can use:

Game.getplayer().unequipform(theArmor)

 

Where "theArmor" should be a property filled with the specific piece of armor.

 

If you want to unequip another actor hen replace game.getplayer() with a reference to the actor.

 

If you don't know what the armor will be, then you can use something like:

Armor thePiece = npc.getEquippedForm(Armor.getSlotMask(32))

If thePiece

  Npc.unequipForm(thePiece)

EndIf

 

Where "npc" is the reference to the actor.

In the code 32 is the body slot for the body. You can find on internet all the numbers for the different body slots. 

Archived

This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...