Jump to content
MakeWebGames

Casey

Members
  • Posts

    69
  • Joined

  • Last visited

Everything posted by Casey

  1. any one got the pick a cup game if have post here thnks
  2. Re: [mccodes]Some one should make a robot mod it sould be on hosp and jail wen waiting there click on robot and theres allsouts of places to cath the fox :)like the idears:)
  3. Re: [mccodes]Some one should make a robot mod that would be nice
  4. Re: [mccodes]Some one should make a robot mod do u like my idea it will be so funny
  5. Re: [mccodes]Some one should make a robot mod it would be good
  6. when the robot mod gets created it should be like on explore and wheen you click on the link a fox runs round the page trying to get you and if you get it you get like 100k in money in game :)
  7. Re: [v2]Diamond market [v2] hi u on ur game
  8. Re: [v2]Diamond market [v2] i did make this took me 30mins
  9. Re: [v2]Diamond market [v2] ok il add some think different
  10. Re: [v2]Diamond market [v2] no i edited my crystal market
  11. Re: [Mccodes V2] Streets give me a +1:)
  12. Re: [v2]Diamond market [v2] What u mean edit all my codes?
  13. Re: [v2]Diamond market [v2] im makin a gem temle theres non on here?
  14. Re: [v2]Diamond market [v2] i edited mine and chaged to diamonds but ok
  15. Re: [Mccodes V2] Streets woops
  16. Re: [Mccodes V2] Streets first make a file called streets.php put this in <?php include "globals.php"; print "<h3>You are currently scavenging the streets</h3> "; if ($_GET['action'] != 'scavenge') { $turns=$ir['turns']; print "Holy smokes! You should scavenge for some serious shit dude. Maybe grab some money off the ground, or get some Experience... maybe even find a special item or two...? Start goin! You have {$turns} turns left for today and will be topped up to 100 at newday. "; print " <form method=post action=street.php?action=scavenge><input type=hidden name=action value=scavenge><input type='text' name='steps' value='{$ir['turns']}'> <input type=submit value='scavenge'></form>"; } else { $steps=abs((int) $_POST['steps']); for($i=0;$i<$steps;$i++) { if ($ir['turns'] < 1) { print("You do NOT have enough steps to scavenge the streets any more. Come back at newday. "); }else { $chance = rand(1,15); $db->query("UPDATE users SET turns=turns-1 where userid=$userid",$c); if ($chance == 1) { $amnt=rand(50,200); if($ir['money'] > $amnt) { print "As you scavenge the streets you see a hobo; he asks you for \$$amnt and you tell him to piss off. Then he proceeds to smack the shit out of you. He takes the \$$amnt anyway. "; $db->query("UPDATE users SET money=money- {$amnt } where userid=$userid",$c); $ir['money']-=$amnt; } else { print "As you walk the streets you see a hobo he asks you for \$1 you tell him to piss off he smacks you over the head and looks in your wallet. Finding it almost empty he just runs off with it. "; $db->query("UPDATE users SET money=0 where userid=$userid",$c); $ir['money']=0; } } if ($chance == 2) { print "Nothing here. "; } if ($chance == 3) { $gained=rand(20,90)*$ir['level']; print "You found a bag of cash on the side walk you open it up and find [b] \$$gained[/b] was inside. "; $db->query("UPDATE users SET money=money+$gained where userid=$userid",$c); } if ($chance == 7) { print "You see a guy getting mugged, but you decide to keep walking. You don't want to be in his shoes anytime soon. "; } if ($chance == 4) { print "While exploring the streets you found some cash, but a hobo came quickly behind you and whacked you over the head. You lurch in suprise and the hobo takes the cash and runs off."; } if ($chance == 5) { $gain = rand(5,20); print "While searching the streets you found [b]$gain[/b] crystals."; $db->query("UPDATE users SET crystals=crystals+$gain where userid=$userid",$c); } if ($chance == 6) { $gain = rand(50,100)*(floor($ir['level']/2)+1); print "While searching the streets you found [b] \$$gain[/b]. "; $db->query("update users set money=money+$gain where userid=$userid",$c); } if ($chance == 8) { print "Nothing here. Just a few drunk bums. "; } if ($chance == 9) { print "You see a small item on the ground, and decide to pick it up... wonder what it is? (Hint, look in your inventory lol)"; $itemidexplore = 40; $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); print" "; } if ($chance == 10) { print "You see a syringe on the ground, and decide to pick it up. Looks deadly enough..."; $itemidexplore = 16; $db->query("INSERT INTO inventory VALUES('',$itemidexplore,$userid,1)",$c); print" "; } if ($chance == 11) { print "Nothing here. "; } if ($chance == 12) { print "Nothing here. "; } if ($chance == 13) { $expcur=(($ir['exp']+$ir['exp_needed'])/100); $exp=(($expcur)*rand(1,5)); print "You got in a scuffle with a bum, and WON you gained some EXP!! (Go have a look!) "; $db->query("UPDATE users SET exp=exp+$exp WHERE userid=$userid",$c); } if ($chance == 14) { print "Nothing here. "; } if ($chance == 15) { $hosptime=(int) rand(1,5); $loseruser = $ir['userid']; $reasonhosp = 'Stepped on a land mine while scavenging.'; $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'],"You stepped on a land mine while exploring. Do be a bit more careful next time...",$c); die ("You stepped on a land mine. [b]Good news[/b]: You aren't dead [b]Bad News[/b]:You have to stop exploring and go into Recovery "); } $ir['turns']--; print"you have [b] {$ir['turns'] }[/b] steps left "; } } if($ir['turns']==0) { print "Sorry, all turns used! "; } else { print " <form method=post action=street.php?action=scavenge><input type=hidden name=action value=scavenge><input type='text' name='steps' value=' {$ir['turns'] }'> <input type=submit value='scavenge'></form>"; } } $h->endpage; ?> } than make a file called turns.php and put this in <?php require "mysql.php"; global $c; mysql_query("update users set turns=100",$c) or die(mysql_error()); ?> then go on php my admin and put the sql in alter table users add turns int(11) not null default 25 Change the above default number to something you want it to be, So when users sign up they start with that amount of turns* Add to day cron Code: $db->query("UPDATE users SET turns=25");
  17. Re: [Mccodes V2] Streets shure
  18. Re: [Mccodes V2] Streets i do
  19. Re: [V2]Register page with 1 account per ip [V2] its lets them have 1account
  20. Re: [V2]Stats Market[V2] who
  21. Re: [v2]Diamond market [v2] mail back plz and not tested i made it not tested ok
  22. first go on php my admin and insert the sql -- -------------------------------------------------------- -- -- Table structure for table `diamondmarket` -- CREATE TABLE `diamondmarket` ( `dmID` int(11) NOT NULL auto_increment, `dmQTY` int(11) NOT NULL default '0', `dmADDER` int(11) NOT NULL default '0', `dmPRICE` int(11) NOT NULL default '0', PRIMARY KEY (`dmID`) ) ENGINE=MyISAM ; -- -------------------------------------------------------- write i went and edited my crystal market and then i made it in to a diamond market so go and make a file called dmarket.php and put this in it <?php include "globals.php"; print "<h3>Diamond Market</h3>"; switch($_GET['action']) { case "buy": diamond_buy(); break; case "remove": diamond_remove(); break; case "add": diamond_add(); break; default: dmarket_index(); break; } function dmarket_index() { global $db,$ir,$c,$userid,$h; print "[url='dmarket.php?action=add']> Add A Listing[/url] Viewing all listings... <table width=75% cellspacing=1 class='table'> <tr style='background:blue'> <th>Adder</th> <th>Qty</th> <th>Price each</th> <th>Price total</th> <th>Links</th> </tr>"; $q=$db->query("SELECT cm.*, u.* FROM diamondmarket cm LEFT JOIN users u ON u.userid=dm.dmADDER ORDER BY dmPRICE/dmQTY ASC"); while($r=$db->fetch_row($q)) { if($r['dmADDER'] == $userid) { $link = "[url='dmarket.php?action=remove&ID={$r[']Remove[/url]"; } else { $link = "[url='dmarket.php?action=buy&ID={$r[']Buy[/url]"; } $each= (int) $r['dmPRICE'] / $r['dmQTY']; print "\n<tr> <td>[url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td> <td>{$r['dmQTY']}</td> <td> \$" . number_format($each)."</td> <td>\$".number_format($r['dmPRICE'])."</td> <td>[$link]</td> </tr>"; } print "</table>"; } function diamond_remove() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM diamondmarket WHERE dmID={$_GET['ID']} AND dmADDER=$userid"); if(!$db->num_rows($q)) { print "Error, either these diamond do not exist, or you are not the owner. [url='dmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); $db->query("UPDATE users SET diamond=diamond+{$r['dmQTY']} where userid=$userid"); $db->query("DELETE FROM diamondmarket WHERE dmID={$_GET['ID']}"); print "Diamonds removed from market! [url='dmarket.php']> Back[/url]"; } function diamond_buy() { global $db,$ir,$c,$userid,$h; $q=$db->query("SELECT * FROM diamondlmarket dm WHERE dmID={$_GET['ID']}"); if(!$db->num_rows($q)) { print "Error, either these diamond do not exist, or they have already been bought. [url='dmarket.php']> Back[/url]"; $h->endpage(); exit; } $r=$db->fetch_row($q); if($r['dmPRICE'] > $ir['money']) { print "Error, you do not have the funds to buy these diamonds. [url='dmarket.php']> Back[/url]"; $h->endpage(); exit; } $db->query("UPDATE users SET diamonds=diamonds+{$r['dmQTY']} where userid=$userid"); $db->query("DELETE FROM diamondmarket WHERE dmID={$_GET['ID']}"); $db->query("UPDATE users SET money=money-{$r['dmPRICE']} where userid=$userid"); $db->query("UPDATE users SET money=money+{$r['dmPRICE']} where userid={$r['dmADDER']}"); event_add($r['dmADDER'],"[url='viewuser.php?u=$userid']{$ir['username']}[/url] bought your {$r['dmQTY']} diamonds from the market for \$".number_format($r['dmPRICE']).".",$c); print "You bought the {$r['dmQTY']} diamonds from the market for \$".number_format($r['dmPRICE'])."."; } function diamond_add() { global $db,$ir,$c,$userid,$h; $_POST['amnt'] = abs((int) $_POST['amnt']); $_POST['price'] = abs((int) $_POST['price']); if($_POST['amnt']) { if($_POST['amnt'] > $ir['diamonds']) { die ("You are trying to add more diamonds to the market than you have."); } $tp=$_POST['amnt']*$_POST['price']; $db->query("INSERT INTO diamondmarket VALUES('',{$_POST['amnt']},$userid,$tp)"); $db->query("UPDATE users SET diamonds=diamonds-{$_POST['amnt']} WHERE userid=$userid"); print "Diamonds added to market! [url='dmarket.php']> Back[/url]"; } else { print "[b]Adding a listing...[/b] You have [b]{$ir['diamonds']}[/b] crystal(s) that you can add to the market.<form action='dmarket.php?action=add' method='post'><table width=50% border=2><tr> <td>Diamonds:</td> <td><input type='text' name='amnt' value='{$ir['diamonds']}' /></td></tr><tr> <td>Price Each:</td> <td><input type='text' name='price' value='200' /></td></tr><tr> <td colspan=2 align=center><input type='submit' value='Add To Market' /></tr></table></form>"; } } $h->endpage(); ?> save it thats my diamond market thanks by casey :)
  23. Re: [V2]My own v2 Explore page [V2] pike u are a retard because u just think that u no it all and no one likes u so up urs
  24. Re: [V2]Register page with 1 account per ip [V2] thanks people ever give anyone a chance and i added the code it works and b there nuts c u own a game
  25. Re: [V2]Register page with 1 account per ip [V2] This register i made to have 1account so ...
×
×
  • Create New...