ArmorMacrosSet
Armor Macros
New F12 toggle armor on/off macro. It also uses "/armor" or "eib" to equip and "dib" to uneqiup.
"/exarm" call examineArmor
set equipBPlate 1
set equipHelm 1
set equipShield 1
set myshirt "shirt1"
set defaultshield "Knight's Shield"
"/armor" call equipArmor
"dib" call removeArmor
"eib" call equipArmor
F12 call toggleArmor
// --*EquipMacro
equipArmor
{
if @my.torso_item != "iron breastplate"
setglobal myshirt @my.torso_item
end if
//Helm Equip
if equipHelm == 1
"/equip iron helmet\r"
else
message "* Helmet too damaged *"
end if
// --*ShieldEquip
if equipShield == 1
if @my.left_item != "chain"
"/equip iron shield\r"
else
message "*Chain Equipped: Not equipping iron shield to avoid accidental dropping of chainees"
end if
else
"/equip " defaultshield "\r"
message "* Shield too damaged *"
end if
// --*Breastplate Equip
if equipBPlate == 1
"/equip ironbreast \r"
else
message "* breastplate too damaged *"
"/equip shirt1\r"
end if
}
// --*RemoveMacro
removeArmor
{
"/unequip iron helmet\r"
//Iron Shield unequip
if @my.left_item >= "iron"
"/equip " defaultshield "\r"
else
message "*Iron Shield already unequipped."
end if
//Breastplate Unequip
if @my.torso_item >= "breastplate"
"/equip " myshirt "\r"
else
message "*Iron Breastplate already unequipped."
end if
}
// --*ToggleArmor
toggleArmor
{
if @my.head_item >= "helmet"
call removeArmor
else
call equipArmor
end if
}
// --*ExamineMacro
examineArmor
{
"/selectitem iron breastplate\r"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipBPlate 0
else
setglobal equipBPlate 1
end if
"/selectitem helmet\r"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipHelm 0
else
setglobal equipHelm 1
end if
"/selectitem <name>\r" //*IMPORTANT:name your shield & use the name instead of "iron shield"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipShield 0
else
setglobal equipShield 1
end if
}
Armor Macros Information
Purpose: This macro set will equip, de-equip and examine armor. Note: The equip macro checks to make sure each piece is not about to fall apart before equipping it for safety. See Repairing Items for armor wear levels.
Rangers Please Note: If you have the heartwood charm equipped, this will not de-equip it to equip the shield. This is in case you are taking off your armor while using the heartwood charm to run faster.
Instructions: Copy the code below into its own file and link it by adding include "filename.txt" in either your default or character macro file.
Use: By Default typing /exarm will call examinearmor . Use eib and dib equips and de-equip armor. (armorup also will call armor.) You can change the triggers that call the macros at the top to your liking, or add additional ones.
Armor Macros
//set these triggers to your liking
"/exarm" call examinearmor //examines armor
"eib" call armor // equips armor
"armorup" call armor //equips armor
"dib" call armoroff //de-equips armor
//global armor state defaults DO NOT EDIT (these assume armor is about to fall apart for safety)
set equipBPlate 1
set equipHelm 1
set equipShield 1
examinearmor
{
"/selectitem iron breastplate\r"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipBPlate 0
else
setglobal equipBPlate 1
end if
"/selectitem helmet\r"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipHelm 0
else
setglobal equipHelm 1
end if
"/selectitem shield 1\r"
pause 1
"/examine\r"
if @env.textLog > "fall apart"
setglobal equipShield 0
else
setglobal equipShield 1
end if
}
armoroff
{
"/unequip iron helmet 1\r"
if @my.left_item != "Heartwood Charm"
"/equip wooden shield\r"
end if
call armorup
}
armor
{
call examinearmor
setglobal shirt @my.torso_item
if equipHelm == 1
"/equip iron helmet\r"
else
message "* Helmet too damaged *"
end if
if equipShield == 1
"/equip iron shield\r"
else
"/equip wooden shield\r"
message "* Shield too damaged *"
end if
call armorup
}
armorup
{
set mytop @my.torso_item
if mytop >= "shirt"
setglobal myshirt @my.torso_item
if equipBPlate == 1
"/equip ironbreast \r"
else
message "* breastplate too damaged *"
"/equip shirt1 Black\r"
end if
else if mytop >= "iron"
message myshirt
if myshirt == ""
"/equip shirt1 Black\r"
message "default called"
else
"/equip " myshirt "\r"
message "global " myshirt " called"
end if
else
if equipBPlate == 1
"/equip ironbreast \r"
else
message "* breastplate too damaged *"
"/equip shirt1 Black\r"
end if
end if
}