I was using Bob's Potions as a reference for the most part, but I just wanted to instead of it calling a function to give health back, give energy to function like a mana potion, but when I tested it, nothing happened, it just made the item go away. I'm not really much of a coder but I can understand a tiny bit of it, but can someone just tell me what to do here since I'm loving this up. Lmao
function ManaPotionImage::onFire(%data, %obj, %slot)
{
%obj.addEnergy(50);
%obj.playThread(0, shiftUp);
if(isObject(%client = %obj.client))
{
%obj.tool[%obj.currTool] = 0;
%obj.weaponCount--;
messageClient(%client, 'MsgItemPickup', '', %obj.currTool, 0, 1);
serverCmdUnUseTool(%client);
}
}