DesignLoft Posted November 30, 2006 Posted November 30, 2006 I am having serious trouble with the brave refilling, I have troubleshooted and have got rid of many errors, the errors i have got rid of are: Fixed URL Added the MYSQL Details into the Crons page Everything else seems right, I have had Darkwolf to check my crons, he says they are fine, my braveupdate code is: <?php include "mysql.php"; global $c; //brave update $q1=mysql_query("SELECT COUNT(*) as users FROM users",$c); $r=mysql_fetch_array($q1); $rows=$r['users']; print "Found $rows users to process."; $i=1; $next=$rows; $query="UPDATE users SET brave=brave+((maxbrave/10)+0.5) WHERE brave$query2="UPDATE users SET brave=maxbrave WHERE brave>maxbrave"; $query3="UPDATE users SET hp=hp+(maxhp/3) WHERE hp$query4="UPDATE users SET hp=maxhp WHERE hp>maxhp"; mysql_query($query,$c) or die("\nError Executing Query 1 for updating users $i to $next\n$query\n".mysql_error()."\nError Code:".mysql_errno()); mysql_query($query2,$c) or die("\nError Executing Query 2 for updating users $i to $next\n$query2\n".mysql_error()."\nError Code:".mysql_errno()); mysql_query($query3,$c) or die("\nError Executing Query 3 for updating users $i to $next\n$query3\n".mysql_error()."\nError Code:".mysql_errno()); mysql_query($query4,$c) or die("\nError Executing Query 4 for updating users $i to $next\n$query4\n".mysql_error()."\nError Code:".mysql_errno()); print "\nUsers $i to $next updated successfully."; print "\nDone."; ?> is there any error to why this is happening, before i sorted the url etc.. the bravery was setting itsself to -28/5 and would NOT update, now when people do crimes, it just stays on how many bravery left, please help its the only thing stopping my game from opening. Quote
Decepti0n Posted December 1, 2006 Posted December 1, 2006 Re: Brave not refilling, does anything come up in the error_log file? also, is mysql.php in the same directory as the cron? if its not, like the cron is in /blah/my/cron/cron.php, you'll need to use like, include('../../../../mysql.php'); or something along those lines. Quote
DesignLoft Posted December 1, 2006 Author Posted December 1, 2006 Re: Brave not refilling, I have checked what you said, nothing is coming up in the error log and the mysql.php is in with the crons so it shouldn't need to be /.././/.//.// etc.. any ideas why please help! Quote
DesignLoft Posted December 4, 2006 Author Posted December 4, 2006 Re: Brave not refilling, please.. Quote
seanybob Posted December 4, 2006 Posted December 4, 2006 Re: Brave not refilling, hm. well if dark said ur crons are fine, then they are... so prob isnt there. perhaps its your server? is it lunarpages or another one? don't really know where else it could be... Quote
DesignLoft Posted December 5, 2006 Author Posted December 5, 2006 Re: Brave not refilling, yeah it might be, I've double tripled quadroupled checked the Crons, i'm gonna upload a fresh Script and see if it works then... Quote
Revolution Posted December 5, 2006 Posted December 5, 2006 Re: Brave not refilling, Try creating a simple script, something such as placing a value in a table somewhere - just to see if the crons run Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.