View Single Post
  #1  
Old 01-18-2017, 12:02 PM
Chaos77777 Chaos77777 is offline
Member
 
Join Date: Jan 2017
Posts: 43
Gender: Male
Credits: 3,888
Chaos77777 is on a distinguished road
Default Allow owner to get rewarded

Hey guys, first time posting here. I'm not a programmer and I've taken no classes, but so far I've been able to figure out how to set things up the way I like. But I'm at a loss on this one. Seems like it would be so simple, but I just can't quite nail it down lol. All I want is for the owner to also receive a reward when a user clicks on their adopts. I found the script in levelup.php, but I can't make it work. Maybe someone else can see what I'm doing wrong.

PHP Code:
            $own $mysidia->db->select("users", array("username"), "username = '{$this->adopt->owner}'");
            
$mysidia->own->changecash(1000000);
// I set it up above where the user gets paid. I set up a high number just so I could definitely notice the change

            
$reward $mysidia->user->clickreward($this->settings->reward);
            
$mysidia->user->changecash($reward);
            
$this->setField("adopt"$this->adopt);
            
$this->setField("reward", new Integer($reward)); 
And I get
Fatal error: Call to a member function changecash() on a non-object in /home/arconlin/public_html/levelup.php on line 56

Thanks guys. Hopefully someone can show me what I'm messing up
Reply With Quote