Jump to content
MakeWebGames

girardz

Members
  • Posts

    33
  • Joined

  • Last visited

Everything posted by girardz

  1. Re: Bank Layout V2   I dont know mmomaker I just tested it again and it works on my game ??? Also I didnt check the differences between IE and firefox if the table looks messed up in IE just change the TD Height to 25px instead of 50px. the table was made using firefox so it looks great as is.
  2. Re: Bank Layout V2 And the cyber bank image also:
  3. Re: Bank Layout V2 Sorry lol These are the images. I made these quick and didnt really put alot of thought into it you can change them to whatever you want I guess.
  4. I got bored with the old MCCode layout so I made a new one: Screenshot: <?php include "globals.php"; print " <img src=cyberbank.png> "; if($ir['cybermoney']>-1) { switch($_GET['action']) { case "deposit": deposit(); break; case "withdraw": withdraw(); break; default: index(); break; } } else { if(isset($_GET['buy'])) { if($ir['money']>9999999) { print "Congratulations, you bought a bank account for \$10,000,000! [url='cyberbank.php']Start using my account[/url]"; $db->query("UPDATE users SET money=money-10000000,cybermoney=0 WHERE userid=$userid"); } else { print "You do not have enough money to open an account. [url='explore.php']Back to town...[/url]"; } } else { print "Open a bank account today, just \$10,000,000! [url='cyberbank.php?buy']> Yes, sign me up![/url]"; } } function index() { global $db,$ir,$c,$userid,$h; print " At the end of each day, your bank balance will increase by the rate listed below. <table width='75%' cellpadding=10 border='1' class='table'> <tr> <td height=50px>[b]<center>Balance:[/b]</center></td> <td><center><font color=blue>[b]\${$ir['cybermoney']}</center></font></td> <td rowspan=4 background=bigbluebar.png>[b]C Y B E R B A N K[/b]</td> <td colspan=2 background=bigsilverbartop.png>[b]<center><font color=#000000>Deposit</font></center>[/b]</td> </tr> <tr> <td height=50px width=30%>[b]<center>Deposit Fee:</center> [/b]</td> <td width=30%>[b]<center><font color=red>8%</font></center></td> <td width=30% background=bigsilverbarmiddle.png><center><form action='cyberbank.php?action=deposit' method='post'><input type='text' name='deposit' value='{$ir['money']}' /></center></td> <td width=10% background=bigsilverbarmiddle.png><input type='submit' value='Deposit' /></form></td> </tr> <tr> <td height=50px>[b]<center>Withdrwl Fee:</center>[/b]</td> <td>[b]<center><font color=green>FREE</font></center></td> <td colspan=2 background=bigsilverbarmiddle.png>[b]<center><font color=#000000>Withdrawl</font></center>[/b]</td> </tr> <tr> <td height=50px>[b]<center>Current Interest Rate </center>[/b]</td> <td>[b]<center><font color=blue>5 %</font></center></td> <td background=bigsilverbarbottom.png><center><form action='cyberbank.php?action=withdraw' method='post'><input type='text' name='withdraw' value='{$ir['cybermoney']}' /></center></td> <td background=bigsilverbarbottom.png><input type='submit' value='Withdraw' /></form></th> </tr> <tr> </tr> </table>"; } function deposit() { global $db,$ir,$c,$userid,$h; $_POST['deposit']=abs((int) $_POST['deposit']); if($_POST['deposit'] > $ir['money']) { print "You do not have enough money to deposit this amount."; } else { $fee=ceil($_POST['deposit']*15/100); if($fee > 1500000) { $fee=1500000; } $gain=$_POST['deposit']-$fee; $ir['cybermoney']+=$gain; $db->query("UPDATE users SET cybermoney=cybermoney+$gain, money=money-{$_POST['deposit']} where userid=$userid"); print "You hand over \${$_POST['deposit']} to be deposited, after the fee is taken (\$$fee), \$$gain is added to your account. [b]You now have \${$ir['cybermoney']} in the Cyber Bank.[/b] [url='cyberbank.php']> Back[/url]"; } } function withdraw() { global $db,$ir,$c,$userid,$h; $_POST['withdraw']=abs((int) $_POST['withdraw']); if($_POST['withdraw'] > $ir['cybermoney']) { print "You do not have enough banked money to withdraw this amount."; } else { $fee=ceil($_POST['withdraw']*75/1000); if($fee > 750000) { $fee=750000; } $gain=$_POST['withdraw']-$fee; $ir['cybermoney']-=$gain; $db->query("UPDATE users SET cybermoney=cybermoney-$gain, money=money+$gain where userid=$userid"); print "You ask to withdraw $gain, the teller hands it over after she takes the bank fees. [b]You now have \${$ir['cybermoney']} in the Cyber Bank.[/b] [url='cyberbank.php']> Back[/url]"; } } $h->endpage(); ?>
  5. Re: [mccode v2] Easter Egg Hunt (Finished) Nice mod, I cleaned it up a bit: To make this work though I had to switch the west.gif and the east.gif, You could rename the image files. if you dont the the arrows wont point in the right direction. <?php include "globals.php"; print "<h3>Easter Egg Hunt</h3> "; if($ir['hospital']) { die("This page cannot be accessed while in hospital."); } if($ir['easterturns'] < 1) { die("You've already hunted today, come back tomorrow for the next stage"); } switch($_GET['action']) { case 'huntnorth': hunt_north(); break; case 'hunteast': hunt_east(); break; case 'huntsouth':hunt_south(); break; case 'huntwest': hunt_west(); break; default: index(); break; } function hunt_north() { global $db,$ir,$c,$h,$userid; $chance = rand(1,10); $db->query("UPDATE users SET easterturns=easterturns-1 where userid=$userid",$c); if($ir['eastertime'] == 0) { if($ir['easterturns'] == 25) { mysql_query("UPDATE `users` SET `eastertime` = 60, `easterturns` = 24 WHERE `userid` = ".$ir['userid']); //Display first attempt here } } if($ir['eastertime'] < 1) { die("Sorry, time's up! Come back tomorrow for the next hunt"); } if ($chance == 1) { print "You look behind a bush, you think you've found an easter egg, but its only a big rock. "; } if ($chance == 2) { print "Nothing here. "; } if ($chance == 3) { print "Nothing here, just a few stones. "; } if ($chance == 4) { $hosptime=(int) rand(1,5); $loseruser = $ir['userid']; $reasonhosp = 'Tried to beat someone up and failed!'; $db->query("UPDATE users SET hospital=$hosptime WHERE userid=$loseruser",$c); $db->query("UPDATE users SET hospreason='$reasonhosp' WHERE userid=$loseruser",$c); event_add($ir['userid'],"Don't mess with people bigger than you!",$c); die ("You try to beat up a guy with an easter egg. He turns round and beats you down. You wake up in hospital."); } if ($chance == 5) { print "You found an easter egg but a squirrel jumps out and takes it from your hands. "; } if ($chance == 6) { $gain = rand(1,5); print "While looking for easter eggs you coincidencially you found [b]$gain[/b] crystals. "; $db->query("UPDATE users SET crystals=crystals+$gain where userid=$userid",$c); } if ($chance == 7) { $gain = rand(50,100); print "You turn over a rock and find [b] \$$gain[/b]. You pocket it and carry on hunting. "; $db->query("update users set money=money+$gain where userid=$userid",$c); } if ($chance == 8) { print "Nothing here. Just a few chavs. "; } if ($chance == 9) { print "You look behind a giant leaf and find an easter egg! Look in your inventory for a special prize! "; $itemidexplore =rand(38,42); $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); } if ($chance == 10) { print "You fall into a bush of nettles. You are stinging all over. "; } print "Turns used: {$ir['easterturns']} "; print "Time remaining: {$ir['eastertime']} "; print " <table width=20% height=80% border=0> <tr> <td> </td> <td align=north><center>[url='easter.php?action=huntnorth'][img=north.gif][/url]</center></td> <td> </td> </tr> <tr> <td align=right>[url='easter.php?action=hunteast'][img=west.gif][/url]</td> <td> </td> <td>[url='easter.php?action=huntwest'][img=east.gif][/url]</td> </tr> <tr> <td> </td> <td align=bottom><center>[url='easter.php?action=huntsouth'][img=south.gif][/url]</center></td> <td> </td> </tr>"; } function hunt_east() { global $db,$ir,$c,$h,$userid; $chance = rand(1,10); $db->query("UPDATE users SET easterturns=easterturns-1 where userid=$userid",$c); if($ir['eastertime'] == 0) { if($ir['easterturns'] == 25) { mysql_query("UPDATE `users` SET `eastertime` = 60, `easterturns` = 24 WHERE `userid` = ".$ir['userid']); //Display first attempt here } } if($ir['eastertime'] < 1) { die("Sorry, time's up! Come back tomorrow for the next hunt"); } if ($chance == 1) { print "You look behind a bush, you think you've found an easter egg, but its only a big rock. "; } if ($chance == 2) { print "Nothing here. "; } if ($chance == 3) { print "Nothing here, just a few stones. "; } if ($chance == 4) { $hosptime=(int) rand(1,5); $loseruser = $ir['userid']; $reasonhosp = 'Tried to beat someone up and failed!'; $db->query("UPDATE users SET hospital=$hosptime WHERE userid=$loseruser",$c); $db->query("UPDATE users SET hospreason='$reasonhosp' WHERE userid=$loseruser",$c); event_add($ir['userid'],"Don't mess with people bigger than you!",$c); die ("You try to beat up a guy with an easter egg. He turns round and beats you down. You wake up in hospital."); } if ($chance == 5) { print "You found an easter egg but a squirrel jumps out and takes it from your hands. "; } if ($chance == 6) { $gain = rand(1,5); print "While looking for easter eggs you coincidencially you found [b]$gain[/b] crystals. "; $db->query("UPDATE users SET crystals=crystals+$gain where userid=$userid",$c); } if ($chance == 7) { $gain = rand(50,100); print "You turn over a rock and find [b] \$$gain[/b]. You pocket it and carry on hunting. "; $db->query("update users set money=money+$gain where userid=$userid",$c); } if ($chance == 8) { print "Nothing here. Just a few chavs. "; } if ($chance == 9) { print "You look behind a giant leaf and find an easter egg! Look in your inventory for a special prize! "; $itemidexplore =rand(38,42); $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); } if ($chance == 10) { print "You fall into a bush of nettles. You are stinging all over. "; } print "Turns used: {$ir['easterturns']} "; print "Time remaining: {$ir['eastertime']} "; print " <table width=20% height=80% border=0> <tr> <td> </td> <td align=north><center>[url='easter.php?action=huntnorth'][img=north.gif][/url]</center></td> <td> </td> </tr> <tr> <td align=right>[url='easter.php?action=hunteast'][img=west.gif][/url]</td> <td> </td> <td>[url='easter.php?action=huntwest'][img=east.gif][/url]</td> </tr> <tr> <td> </td> <td align=bottom><center>[url='easter.php?action=huntsouth'][img=south.gif][/url]</center></td> <td> </td> </tr>"; } function hunt_south() { global $db,$ir,$c,$h,$userid; $chance = rand(1,10); $db->query("UPDATE users SET easterturns=easterturns-1 where userid=$userid",$c); if($ir['eastertime'] == 0) { if($ir['easterturns'] == 25) { mysql_query("UPDATE `users` SET `eastertime` = 60, `easterturns` = 24 WHERE `userid` = ".$ir['userid']); //Display first attempt here } } if($ir['eastertime'] < 1) { die("Sorry, time's up! Come back tomorrow for the next hunt"); } if ($chance == 1) { print "You look behind a bush, you think you've found an easter egg, but its only a big rock. "; } if ($chance == 2) { print "Nothing here. "; } if ($chance == 3) { print "Nothing here, just a few stones. "; } if ($chance == 4) { $hosptime=(int) rand(1,5); $loseruser = $ir['userid']; $reasonhosp = 'Tried to beat someone up and failed!'; $db->query("UPDATE users SET hospital=$hosptime WHERE userid=$loseruser",$c); $db->query("UPDATE users SET hospreason='$reasonhosp' WHERE userid=$loseruser",$c); event_add($ir['userid'],"Don't mess with people bigger than you!",$c); die ("You try to beat up a guy with an easter egg. He turns round and beats you down. You wake up in hospital."); } if ($chance == 5) { print "You found an easter egg but a squirrel jumps out and takes it from your hands. "; } if ($chance == 6) { $gain = rand(1,5); print "While looking for easter eggs you coincidencially you found [b]$gain[/b] crystals. "; $db->query("UPDATE users SET crystals=crystals+$gain where userid=$userid",$c); } if ($chance == 7) { $gain = rand(50,100); print "You turn over a rock and find [b] \$$gain[/b]. You pocket it and carry on hunting. "; $db->query("update users set money=money+$gain where userid=$userid",$c); } if ($chance == 8) { print "Nothing here. Just a few chavs. "; } if ($chance == 9) { print "You look behind a giant leaf and find an easter egg! Look in your inventory for a special prize! "; $itemidexplore =rand(38,42); $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); } if ($chance == 10) { print "You fall into a bush of nettles. You are stinging all over. "; } print "Turns used: {$ir['easterturns']} "; print "Time remaining: {$ir['eastertime']} "; print " <table width=20% height=80% border=0> <tr> <td> </td> <td align=north><center>[url='easter.php?action=huntnorth'][img=north.gif][/url]</center></td> <td> </td> </tr> <tr> <td align=right>[url='easter.php?action=hunteast'][img=west.gif][/url]</td> <td> </td> <td>[url='easter.php?action=huntwest'][img=east.gif][/url]</td> </tr> <tr> <td> </td> <td align=bottom><center>[url='easter.php?action=huntsouth'][img=south.gif][/url]</center></td> <td> </td> </tr>"; } function hunt_west() { global $db,$ir,$c,$h,$userid; $chance = rand(1,10); $db->query("UPDATE users SET easterturns=easterturns-1 where userid=$userid",$c); if($ir['eastertime'] == 0) { if($ir['easterturns'] == 25) { mysql_query("UPDATE `users` SET `eastertime` = 60, `easterturns` = 24 WHERE `userid` = ".$ir['userid']); //Display first attempt here } } if($ir['eastertime'] < 1) { die("Sorry, time's up! Come back tomorrow for the next hunt"); } if ($chance == 1) { print "You look behind a bush, you think you've found an easter egg, but its only a big rock. "; } if ($chance == 2) { print "Nothing here. "; } if ($chance == 3) { print "Nothing here, just a few stones. "; } if ($chance == 4) { $hosptime=(int) rand(1,5); $loseruser = $ir['userid']; $reasonhosp = 'Tried to beat someone up and failed!'; $db->query("UPDATE users SET hospital=$hosptime WHERE userid=$loseruser",$c); $db->query("UPDATE users SET hospreason='$reasonhosp' WHERE userid=$loseruser",$c); event_add($ir['userid'],"Don't mess with people bigger than you!",$c); die ("You try to beat up a guy with an easter egg. He turns round and beats you down. You wake up in hospital."); } if ($chance == 5) { print "You found an easter egg but a squirrel jumps out and takes it from your hands. "; } if ($chance == 6) { $gain = rand(1,5); print "While looking for easter eggs you coincidencially you found [b]$gain[/b] crystals. "; $db->query("UPDATE users SET crystals=crystals+$gain where userid=$userid",$c); } if ($chance == 7) { $gain = rand(50,100); print "You turn over a rock and find [b] \$$gain[/b]. You pocket it and carry on hunting. "; $db->query("update users set money=money+$gain where userid=$userid",$c); } if ($chance == 8) { print "Nothing here. Just a few chavs. "; } if ($chance == 9) { print "You look behind a giant leaf and find an easter egg! Look in your inventory for a special prize! "; $itemidexplore =rand(38,42); $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); } if ($chance == 10) { print "You fall into a bush of nettles. You are stinging all over. "; } print "Turns used: {$ir['easterturns']} "; print "Time remaining: {$ir['eastertime']} "; print " <table width=20% height=80% border=0> <tr> <td> </td> <td align=north><center>[url='easter.php?action=huntnorth'][img=north.gif][/url]</center></td> <td> </td> </tr> <tr> <td align=right>[url='easter.php?action=hunteast'][img=west.gif][/url]</td> <td> </td> <td>[url='easter.php?action=huntwest'][img=east.gif][/url]</td> </tr> <tr> <td> </td> <td align=bottom><center>[url='easter.php?action=huntsouth'][img=south.gif][/url]</center></td> <td> </td> </tr>"; } function index() { global $db,$ir,$c,$h,$userid; print "<h3>You Are About To Start The 1 Hour Easter Hunt</h3> You Arrive At The Hunt, Ready To Win Some Eggs And Prove Everyone Wrong <table width=20% height=80% border=0> <tr> <td> </td> <td align=north><center>[url='easter.php?action=huntnorth'][img=north.gif][/url]</center></td> <td> </td> </tr> <tr> <td align=right>[url='easter.php?action=hunteast'][img=west.gif][/url]</td> <td> </td> <td>[url='easter.php?action=huntwest'][img=east.gif][/url]</td> </tr> <tr> <td> </td> <td align=bottom><center>[url='easter.php?action=huntsouth'][img=south.gif][/url]</center></td> <td> </td> </tr>"; } $h->endpage; ?>
×
×
  • Create New...