mob
var
inventory_panel = 1
verb/inventory()
inventory_panel = !inventory_panel // toggle the value on or off
if(inventory_panel)
src << "Inventory opened."
else
src << "Inventory closed."
Stat()
if(inventory_panel && statpanel("Inventory"))
stat(contents)
Could you change 'inventory_panel' to what ever panel you choose?