View Single Post
  #5  
Old 10-30-2012, 07:27 AM
draugluin's Avatar
draugluin draugluin is offline
Member
 
Join Date: Oct 2011
Location: germany
Posts: 120
Gender: Unknown/Other
Credits: 10,926
draugluin is on a distinguished road
Default

Quote:
How can I make an item that switches the adoptable's gender?
its a very interesting question. I've tried a item, which makes an adoptable male, but

PHP Code:
function items_male($item$adopt){
  
// Update the gender info.
  
$GLOBALS['adopts']->update("owned_adoptables", array("gender" => 'm'), "aid ='{$adopt->aid}' and owner='{$item->owner}'");    
  
$note "Its male now<br>";
  
//Update item quantity...
  
$delitem $item->removeitem(1$item->owner);  
  return 
$note;

does'nt work. I've copied it from "breed1" which changes the "lastbred to 0" modified to "gender = m"

where is the fault???
Reply With Quote