Healing potion item function

Forum
Last Post
Threads / Messages

Ittermat

The awesomesauce
Member
Joined
Feb 2, 2016
Messages
291
Points
16
Location
in front of my laptop
Mysidian Dollar
21,140
Im attempting to add healing potions to heal a pet. but I cant figure out the item function, I basically copied the Clicks one and changed it but cant figure out where I went wrong cuz it tells me the item function is invalid when I try to use it.

The item function in the DB is healthpotion1
The health for pets is located in Owned_adoptables ->health

__________________________________________

function items_healthpotion1($item, $adopt){
$mysidia = Registry::get("mysidia");
$newhealth = $item->value;
$mysidia->db->update("owned_adoptables", array("health" => $newhealth), "aid='{$adopt->aid}'and owner='{$item->owner}'");
$note = "By using {$item->itemname}, the adoptable's health is fully restored<br>";
}

NEVERMIND I FIGURED IT OUT I WAS A STUPID <3
 
Last edited:

Similar threads

Users who are viewing this thread

  • Forum Contains New Posts
  • Forum Contains No New Posts

Forum statistics

Threads
4,162
Messages
32,369
Members
1,528
Latest member
XD_Stones
BETA

Latest Threads

Top