Feky Posted June 26, 2009 Share Posted June 26, 2009 can anyone know why its not showing how much job point i get each day and this is what it says and it dosent show how much i get each day it just say (You receive $300 and Job Points) (You currently work in the Army! You receive $300 and Job Points You also receive 9 IQ, 9 strength, and 9 labour!) <?php $jobquery=1; include "globals.php"; $_GET['interview'] = abs((int) $_GET['interview']); if(!$ir['job']) { if(!$_GET['interview']) { print "You do not yet have a job. A list of jobs is available below. "; $q=$db->query("SELECT * FROM jobs"); while($r=$db->fetch_row($q)) { print "> {$r['jNAME']} - {$r['jDESC']} - [url='job.php?interview={$r[']Go to interview[/url] "; } } else { $q=$db->query("SELECT j.*,jr.* FROM jobs j LEFT JOIN jobranks jr ON j.jFIRST = jr.jrID WHERE j.jID={$_GET['interview']}"); $r=$db->fetch_row($q); print "{$r['jOWNER']}: So {$ir['username']}, you were looking for a job with us? {$ir['username']}: Yes please! "; if($ir['strength'] >= $r['jrSTRN'] && $ir['labour'] >= $r['jrLABOURN'] && $ir['IQ'] >= $r['jrIQN']) { $db->query("UPDATE users SET job={$_GET['interview']},jobrank={$r['jrID']} WHERE userid=$userid;"); $db->query("UPDATE users SET jobpay={$r['jrPAY']} WHERE userid=$userid;"); print "{$r['jOWNER']}: Okay {$ir['username']}, we're good to go, see you tomorrow. {$ir['username']}: Thanks! [url='job.php']Start your job[/url]"; } else { print "{$r['jOWNER']}: Sorry {$ir['username']}, you're not far enough in the game to work in this job. You'll need:"; if($ir['strength'] < $r['jrSTRN']) { $s=$r['jrSTRN']-$ir['strength']; print " $s more strength, "; } if($ir['labour'] < $r['jrLABOURN']) { $s=$r['jrLABOURN']-$ir['labour']; print " $s more labour, "; } if($ir['IQ'] < $r['jrIQN']) { $s=$r['jrIQN']-$ir['IQ']; print " $s more IQ, "; } print "before you'll be able to work here! [url='index.php']:'([/url]"; } } } else { switch($_GET['action']) { case 'quit': quit_job(); break; case 'promote': job_promote(); break; default: job_index(); break; } } function job_index() { global $db, $ir,$c,$userid,$h; print "<h3>Your Job</h3> You currently work in the {$ir['jNAME']}! You receive \${$ir['jrPAY']} and {$ir['jrPOINTS']} Job Points You also receive {$ir['jrIQG']} IQ, {$ir['jrSTRG']} strength, and {$ir['jrLABOURG']} labour! <table width=80% class='table'><tr><td>Job Points:{$ir['jobpoints']} <tr><td>Strength: {$ir['strength']}</td><td>IQ: {$ir['IQ']}</tr></td><tr><td>Labour: {$ir['labour']}</td><td>Job Rank: {$ir['jrNAME']}</td></tr></table> <table width=80% cellspacing=1 class='table'><tr style='background:gray'><th>Title</th><th>Pay</th><th>Strength Reqd</th><th>IQ Reqd</th><th>Labour Reqd</th></tr>"; $q=$db->query("SELECT * FROM jobranks WHERE jrJOB={$ir['job']} ORDER BY jrPAY ASC;"); while($r=$db->fetch_row($q)) { print "<tr><td>{$r['jrNAME']}</td><td>\${$r['jrPAY']}</td><td>{$r['jrSTRN']}</td><td>{$r['jrIQN']}</td><td>{$r['jrLABOURN']}</td></tr>"; } $js=$db->query("SELECT * FROM jobspecials WHERE jsJOB={$ir['job']} ORDER BY jsID ASC;",$c); print "[b]Job Ranks[/b] <form action='specials.php' method='post'> <table width=80% cellspacing=1 class='table'> <tr> <th><font color=white>Job Specials</font></th> <th><font color=white>Cost</font></th> <th><font color=white>Take</font></th></tr>"; if($db->num_rows($js) == 0) { print "<tr class='row$current_row'><td colspan=3>This Job has no Speacials</td></tr>"; $current_row = 1 - $current_row; } while($sp=$db->fetch_row($js)) { print "<tr class='row$current_row'><td><font color=black>{$sp['jsNAME']}</td><td><font color=#FF0000>-{$sp['jsCOST']} Job Points</font></td><td><center><input type='radio' name='ID' value='{$sp['jsID']}' /></td></tr>"; $current_row = 1 - $current_row; } print "<tr> <td colspan=3><div align=center><input type='submit' value='Purchase'></div></td> </tr></table></form>"; print "</table> [url='job.php?action=promote']> Try To Get Promoted[/url] [url='job.php?action=quit']> Quit[/url]"; } function job_promote() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM jobranks WHERE jrPAY > {$ir['jrPAY']} AND jrSTRN <= {$ir['strength']} AND jrLABOURN <= {$ir['labour']} AND jrIQN <= {$ir['IQ']} AND jrJOB = {$ir['job']} ORDER BY jrPAY DESC LIMIT 1"); if($db->num_rows($q) == 0) { print "Sorry, you cannot be promoted. [url='job.php']> Back[/url]"; } else { $r=$db->fetch_row($q); $db->query("UPDATE users SET jobrank={$r['jrID']} WHERE userid=$userid"); $db->query("UPDATE users SET jobpay={$r['jrPAY']} WHERE userid=$userid;"); print "Congrats, you have been promoted to {$r['jrNAME']} [url='job.php']> Back[/url]"; } } function quit_job() { global $db,$ir,$c,$userid,$h; $db->query("UPDATE users SET job=0,jobrank=0 WHERE userid=$userid"); $db->query("UPDATE users SET jobpay=0 WHERE userid=$userid;"); print "You have quit your job! [url='job.php']> Back[/url]"; } $h->endpage(); ?> Quote Link to comment Share on other sites More sharing options...
gurpreet Posted June 26, 2009 Share Posted June 26, 2009 Re: jobpoints bug Is this Cronus's job mod? Quote Link to comment Share on other sites More sharing options...
fbiss Posted June 27, 2009 Share Posted June 27, 2009 Re: jobpoints bug This is not a New game modification, so dont post this here Quote Link to comment Share on other sites More sharing options...
bineye Posted July 3, 2009 Share Posted July 3, 2009 Re: jobpoints bug can anyone know why its not showing how much job point i get each day and this is what it says and it dosent show how much i get each day it just say (You receive $300 and Job Points) (You currently work in the Army! You receive $300 and Job Points You also receive 9 IQ, 9 strength, and 9 labour!) <?php $jobquery=1; include "globals.php"; $_GET['interview'] = abs((int) $_GET['interview']); if(!$ir['job']) { if(!$_GET['interview']) { print "You do not yet have a job. A list of jobs is available below. "; $q=$db->query("SELECT * FROM jobs"); while($r=$db->fetch_row($q)) { print "> {$r['jNAME']} - {$r['jDESC']} - [url='job.php?interview={$r[']Go to interview[/url] "; } } else { $q=$db->query("SELECT j.*,jr.* FROM jobs j LEFT JOIN jobranks jr ON j.jFIRST = jr.jrID WHERE j.jID={$_GET['interview']}"); $r=$db->fetch_row($q); print "{$r['jOWNER']}: So {$ir['username']}, you were looking for a job with us? {$ir['username']}: Yes please! "; if($ir['strength'] >= $r['jrSTRN'] && $ir['labour'] >= $r['jrLABOURN'] && $ir['IQ'] >= $r['jrIQN']) { $db->query("UPDATE users SET job={$_GET['interview']},jobrank={$r['jrID']} WHERE userid=$userid;"); $db->query("UPDATE users SET jobpay={$r['jrPAY']} WHERE userid=$userid;"); print "{$r['jOWNER']}: Okay {$ir['username']}, we're good to go, see you tomorrow. {$ir['username']}: Thanks! [url='job.php']Start your job[/url]"; } else { print "{$r['jOWNER']}: Sorry {$ir['username']}, you're not far enough in the game to work in this job. You'll need:"; if($ir['strength'] < $r['jrSTRN']) { $s=$r['jrSTRN']-$ir['strength']; print " $s more strength, "; } if($ir['labour'] < $r['jrLABOURN']) { $s=$r['jrLABOURN']-$ir['labour']; print " $s more labour, "; } if($ir['IQ'] < $r['jrIQN']) { $s=$r['jrIQN']-$ir['IQ']; print " $s more IQ, "; } print "before you'll be able to work here! [url='index.php']:'([/url]"; } } } else { switch($_GET['action']) { case 'quit': quit_job(); break; case 'promote': job_promote(); break; default: job_index(); break; } } function job_index() { global $db, $ir,$c,$userid,$h; print "<h3>Your Job</h3> You currently work in the {$ir['jNAME']}! You receive \${$ir['jrPAY']} and {$ir['jrPOINTS']} Job Points You also receive {$ir['jrIQG']} IQ, {$ir['jrSTRG']} strength, and {$ir['jrLABOURG']} labour! <table width=80% class='table'><tr><td>Job Points:{$ir['jobpoints']} <tr><td>Strength: {$ir['strength']}</td><td>IQ: {$ir['IQ']}</tr></td><tr><td>Labour: {$ir['labour']}</td><td>Job Rank: {$ir['jrNAME']}</td></tr></table> <table width=80% cellspacing=1 class='table'><tr style='background:gray'><th>Title</th><th>Pay</th><th>Strength Reqd</th><th>IQ Reqd</th><th>Labour Reqd</th></tr>"; $q=$db->query("SELECT * FROM jobranks WHERE jrJOB={$ir['job']} ORDER BY jrPAY ASC;"); while($r=$db->fetch_row($q)) { print "<tr><td>{$r['jrNAME']}</td><td>\${$r['jrPAY']}</td><td>{$r['jrSTRN']}</td><td>{$r['jrIQN']}</td><td>{$r['jrLABOURN']}</td></tr>"; } $js=$db->query("SELECT * FROM jobspecials WHERE jsJOB={$ir['job']} ORDER BY jsID ASC;",$c); print "[b]Job Ranks[/b] <form action='specials.php' method='post'> <table width=80% cellspacing=1 class='table'> <tr> <th><font color=white>Job Specials</font></th> <th><font color=white>Cost</font></th> <th><font color=white>Take</font></th></tr>"; if($db->num_rows($js) == 0) { print "<tr class='row$current_row'><td colspan=3>This Job has no Speacials</td></tr>"; $current_row = 1 - $current_row; } while($sp=$db->fetch_row($js)) { print "<tr class='row$current_row'><td><font color=black>{$sp['jsNAME']}</td><td><font color=#FF0000>-{$sp['jsCOST']} Job Points</font></td><td><center><input type='radio' name='ID' value='{$sp['jsID']}' /></td></tr>"; $current_row = 1 - $current_row; } print "<tr> <td colspan=3><div align=center><input type='submit' value='Purchase'></div></td> </tr></table></form>"; print "</table> [url='job.php?action=promote']> Try To Get Promoted[/url] [url='job.php?action=quit']> Quit[/url]"; } function job_promote() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM jobranks WHERE jrPAY > {$ir['jrPAY']} AND jrSTRN <= {$ir['strength']} AND jrLABOURN <= {$ir['labour']} AND jrIQN <= {$ir['IQ']} AND jrJOB = {$ir['job']} ORDER BY jrPAY DESC LIMIT 1"); if($db->num_rows($q) == 0) { print "Sorry, you cannot be promoted. [url='job.php']> Back[/url]"; } else { $r=$db->fetch_row($q); $db->query("UPDATE users SET jobrank={$r['jrID']} WHERE userid=$userid"); $db->query("UPDATE users SET jobpay={$r['jrPAY']} WHERE userid=$userid;"); print "Congrats, you have been promoted to {$r['jrNAME']} [url='job.php']> Back[/url]"; } } function quit_job() { global $db,$ir,$c,$userid,$h; $db->query("UPDATE users SET job=0,jobrank=0 WHERE userid=$userid"); $db->query("UPDATE users SET jobpay=0 WHERE userid=$userid;"); print "You have quit your job! [url='job.php']> Back[/url]"; } $h->endpage(); ?> Are your job points set to 0? It will still show 'job points', but no number Quote Link to comment Share on other sites More sharing options...
Feky Posted July 3, 2009 Author Share Posted July 3, 2009 Re: jobpoints bug nopr their is no zero it just says job points with no figure Quote Link to comment Share on other sites More sharing options...
CrazyT Posted July 3, 2009 Share Posted July 3, 2009 Re: jobpoints bug <?php function quit_job() { global $db, $ir, $h; if(!$ir['job']) { echo 'You don\'t have a job to quit!'; exit(headers::endpage()); } else { $db->query('UPDATE `users SET `job` = 0, `jobrank` = 0, `jobpay` = 0 WHERE `userid` = ', $ir['userid']); echo 'You have quit your job! [url="job.php"]Back[/url]'; } } That should be better than your other one lmao Quote Link to comment Share on other sites More sharing options...
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.