View Single Post
  #9  
Old 12-19-2016, 07:47 PM
Dinocanid's Avatar
Dinocanid Dinocanid is offline
Member
 
Join Date: Aug 2016
Location: Maryland, USA
Posts: 516
Gender: Unknown/Other
Credits: 65,245
Dinocanid is on a distinguished road
Default

I'm working on finding a way to make it drop, but so far I've found nothing that works. Some people suggest cronjobs, which would be ideal for this since it would only run once every 24 hours, but I've yet to find any sort of guide as to how to set it up with mysidia script. Right now I'm testing this line I added:

PHP Code:
$today date(d);
        
        if (
$mysidia->user->lastday != $today) {
        
$adopt->setMood($subMood"update");        
        }
        
$mysidia->db->update("users", array("lastday" => $today), "username = '{$mysidia->user->username}'"); 
Supposedly it could make the mood drop every day when you visit your pet's profile, but it's only been one day so I'm going to have to probably wait another to see if it's actually working.

I already mostly have a part done that makes a pet die when health reaches 0, but it also deletes the pet from the system so I have to do some pretty careful testing. I'm working on a less destructive alternative where the pet "dies" and you have a few days to revive them.

That sounds like a cool idea for an addon! Once I can actually get the bars to go down then I'll see about working on it.
__________________
Reply With Quote