Jump to content
xisto Community
Sign in to follow this  
Variablez

Mccodes V2 Mods A good mod for V2 Mccodes, a carnival (TUTORIAL)

Recommended Posts

Hey all I downloaded a new mod! Here is how to install it:


First page (main page) is here:

<?php
require "globals.php";

if($ir['jail']>0 || $ir['hospital']>0)
die("<center>You can not move around right now.");
if(!$_GET['buy'])
{

print "<h2><center>Welcome to the Carnival. You currently have {$ir['tickets']} tickets do you want to buy some?</h2></center>";
print "<center>What would you like to do?<br /><table BORDER=2 CELLPADDING=2 CELLSPACING=2> <tr><td>
<a href='carnival.php?buy=ticket'>Buy Tickets - $5000 for 5 tickets</a><br /></td><td>
<a href='carnigames.php?action=balloon'> Balloon Dart Game - 5 Tickets per dart.</a><br /></td></tr>
<tr><td>
<a href='carnigames.php?action=duck'>Lucky Ducks - 5 Tickets per duck</a><br /></center></td>
<td>
<a href='carnigames.php?action=strongman'>Strongman Game - 5 Tickets per swing</a><br /></center></td>
</tr>
<tr><td>
<a href='carnigames.php?action=dunk'>Dunking Booth - 5 Tickets per throw</a><br /></center></td>

</tr>
</table>";

}
else
{
if($_GET['buy'] == 'ticket')
{
if($ir['money'] <5000)
{
print "You don't have enough money for tickets";
}
else
{
$db->query("UPDATE users SET money=money-5000,tickets=tickets+5 WHERE userid=$userid");
print "You have paid $5000 for 5 carnival tickets.";
}
}
}

?>

upload that and call the file "carnival.php"





Then you must do the same with another file though:




<?php
require "globals.php";


if($ir['tickets']<1)
die("<center>You are out of tickets. <a href='carnival.php'><font color=red>Go buy some</font></a>");



if ($_GET['action'] == 'balloon') {

$bal=rand(1,100);


if ($bal>=10) {
print "You missed! <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
else {
print "You pop a balloon and win 5 Crystals!<br /><br />";
$db->mysql_query("update users set tickets=tickets-5 where userid=$userid");
$db->query("update users set crystals=crystals+5 where userid=$userid");
}
}
if ($_GET['action'] == 'duck') {

$dck=rand(1,10);

if ($dck==1) {

print "You picked up the duck with the number 1 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($dck==2) {

print "You picked up the duck with the number 2 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==3) {

print "You picked up the duck with the number 3 on the bottom! You won 3 Crystals! <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
$db->query("update users set crystals=crystals+3 where userid=$userid");
}
if ($dck==4) {

print "You picked up the duck with the number 4 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==5) {

print "You picked up the duck with the number 5 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==6) {
print "You picked up the duck with the number 6 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($dck==7) {
print "You picked up the duck with the number 7 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==8) {
print "You picked up the duck with the number 8 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==9) {
print "You picked up the duck with the number 9 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($dck==10) {
print "You picked up the duck with the number 10 on the bottom! Sorry the lucky number was 3 <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
}

if ($_GET['action'] == 'strongman') {

$mrk=rand(1,10);

if ($mrk==1) {

print "You pick up the hammer and swing! The little marker barely moves...pityful <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($mrk==2) {

print "You pick up the hammer and swing! The marker moves up a little to the spot that says

...weakling <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==3) {

print "You pick up the hammer and swing! The marker moves up a little to the spot that says

...wimpy<br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==4) {

print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...give it

up <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==5) {

print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...only

halfway how sad <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==6) {
print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...getting

there <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($mrk==7) {
print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...almost

<br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==8) {
print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...Good

Girl <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==9) {
print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...Good

boy <br /><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($mrk==10) {
print "You pick up the hammer and swing! You hear the bell ring!!! You won 2 Demon Claws <br /><br

/><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
$db->query("update users set crystals=crystals+2 where userid=$userid");
}
}
if ($_GET['action'] == 'dunk') {
print"staffmember is currently in the Dunking Booth<br /><br />";
$bal=rand(1,10);

if ($bal==1) {

print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($bal==2) {

print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==3) {

print "You throw the ball and miss so Cpt.JackSparrow taunts you<br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==4) {

print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==5) {

print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==6) {
print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}

if ($bal==7) {
print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==8) {
print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==9) {
print "You throw the ball and miss so Cpt.JackSparrow taunts you <br /><br /><a

href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
}
if ($bal==10) {
print "You throw the ball and hit the target and Cpt.JackSparrow goes for a dip!!! You won 5 crystals <br

/><br /><a href='carnival.php'>Back</a>";
$db->query("update users set tickets=tickets-5 where userid=$userid");
$db->query("update users set crystals=crystals+5 where userid=$userid");
}
}

?>

copy and paste and make a file called carnigames.php.

Then open PHP My Admin and run this query:


alter table users add `tickets` int(11) NOT NULL default '0';

and then you must add the link of "Carnival.Php" to the Explore file.



Thanks for reading, hope you like it!

Share this post


Link to post
Share on other sites

eh why even using quote tags when you should use code tags and that is not the full mod m8 but thats kl least you shared sumthing but for future references you may want to give step by step instructions
you may wonder how do i know its not the full mod well lets see i have the exact same thing its a carni mod also and i know theres alot more to it then posted

here ill be nice and post the correct way of doing it:

ok folks this is a V2 Carnival Mod

first In header.php Find :

print "[b]Level:[/b] {$ir['level']}";After Add :print "[b]Tickets:[/b] {$ir['tickets']}";

second In explore.php Add :

<a href='carnival.php'>Carnival</a><br />

third run this Sql in your phpmyadmin:
ALTER TABLE `users` ADD `tickets` INT( 11 ) NOT NULL DEFAULT '0';

then copy this and create a file called carnival.php

<?phpinclude "globals.php";if($ir['jail']>0 || $ir['hospital']>0)die("<center>You can not move around right now.");if(!$_GET['buy']){echo "<h5><center>Welcome to the Big Brother Carnival. You currently have {$ir['tickets']} Tickets do you want to Buy some ..??</h5></center>";echo "<center><u>What would you like to do ..??</u><br /><table border=3 cellpadding=4 cellspacing=5> <tr><td><a href='carnival.php?buy=ticket'><b><u>Buy Tickets - $5000 for 5 tickets</u></b></a><br /></td><td><a href='carnigames.php?action=balloon'> Balloon Dart Game - 5 Tickets Per Dart.</a><br /></td></tr><tr><td><a href='carnigames.php?action=duck'>Lucky Ducks - 5 Tickets Per Duck</a><br /></center></td><td><a href='carnigames.php?action=strongman'>Strongman Game - 5 Tickets Per Swing</a><br /></center></td></tr><tr><td><a href='carnigames.php?action=dunk'>Dunking Booth - 5 Tickets Per Throw</a><br /></center></td><td><a href='carnigames.php?action=sumo'>Fight Ultimate Sumo</a><br /></center></td></tr></table>";}else{if($_GET['buy'] == 'ticket'){if($ir['money'] <5000){echo "You don't have enough money for Tickets";}else{mysql_query("UPDATE users SET money=money-5000,tickets=tickets+5 WHERE userid=$userid",$c);print "You have paid $5000 for 5 carnival tickets.";}}}?>

then copy and create a file called carnigames.php then upload it

<?phpinclude "globals.php";if($ir['tickets']<1)die("<center>You are Out of Tickets. <a href='carnival.php'><font color=red>Go buy Some</font></a>");if ($_GET['action'] == 'balloon') {$bal=rand(1,100);if ($bal>=10) {print "You missed! <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}else {print "You pop a balloon and win 4 Bullets !!!<br /><br />";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set crystals=crystals+4 where userid=$userid",$c);}}if ($_GET['action'] == 'duck') {$dck=rand(1,10);if ($dck==1) {print "You picked up the duck with the number 1 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==2) {print "You picked up the duck with the number 2 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==3) {print "You picked up the duck with the number 3 on the bottom !!! You won 5 Crystals !!! <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set crystals=crystals+5 where userid=$userid",$c);}if ($dck==4) {print "You picked up the duck with the number 4 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==5) {print "You picked up the duck with the number 5 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==6) {print "You picked up the duck with the number 6 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==7) {print "You picked up the duck with the number 7 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==8) {print "You picked up the duck with the number 8 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==9) {print "You picked up the duck with the number 9 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($dck==10) {print "You picked up the duck with the number 10 on the bottom! Sorry the lucky number was 3 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}}if ($_GET['action'] == 'strongman') {$mrk=rand(1,10);if ($mrk==1) {print "You pick up the hammer and swing !!! The little marker barely moves...pityfull <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==2) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...weakling <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==3) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...wimpy<br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==4) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...give it up <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==5) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...only halfway how sad <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==6) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...getting there <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==7) {print "You pick up the Heavy hammer and swing !!! The marker moves up a little to the spot that says ...almost <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==8) {print "You pick up the hammer and swing! The marker moves up a little to the spot that says ...Good Girl <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($mrk==9) {print "You pick up the hammer and swing !!! The marker moves up a alot & You Win $5800 ...Good boy <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set moneys=moneys+5800 where userid=$userid",$c);}if ($mrk==10) {print "You pick up the hammer and swing !!! You hear the bell ring!!! You won Crystals  <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set crystals=crystals+2 where userid=$userid",$c);}} if ($_GET['action'] == 'dunk') {print"staffmember is currently in the Dunking Booth<br /><br />";$bal=rand(1,10);if ($bal==1) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==2) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==3) {print "You throw the ball and miss so staffmember taunts you<br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==4) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==5) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==6) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==7) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==8) {print "You throw the ball and miss so staffmember taunts you <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($bal==9) {print "You throw the ball and it was Hard To Decide if you Hit the Target So you Get $5500  <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set moneys=moneys+5500 where userid=$userid",$c);}if ($bal==10) {print "You throw the ball and hit the target and staffmember goes for a Dip !!! You won 3 Bullets  <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set crystals=crystals+3 where userid=$userid",$c);}}if ($_GET['action'] == 'sumo') {$sumo=rand(1,10);if ($sumo==1) {print "You Fight the Sumo & Get Smashed Like Glass !!! <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==2) {print "You Fight the Sumo then he Picks You Up and Throws You . <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==3) {print "You Fight The Ultimate Sumo & You Faint Straight away you Puff !!!<br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==4) {print "You Fight The fat Sumo & He Snaps your Leg. HAHA <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==5) {print "You Fight The Sumo & you fall Over. <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==6) {print "You Fight The Sumo & He Crushes your Ribs !!! <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==7) {print "You Fight The Ultimate Sumo & He Falls on Top of You.<br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==8) {print "You Fight The Sumo & you Slip on a Banana. <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);}if ($sumo==9) {print "You Fight the Sumo & was So Close Of Winning Him . You then Find 1 <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set crystals=crystals+1 where userid=$userid",$c);}if ($sumo==10) {print "You Fight the Sumo, He Beats you Up But Suddenly You Kick the Sh*t out of Him !!! You hear the Bell Ringing !!! You won $6000  <br /><br /><a href='carnival.php'>Back</a>";mysql_query("update users set tickets=tickets-5 where userid=$userid",$c);mysql_query("update users set moneys=moneys+6000 where userid=$userid",$c);}}?>

and then lala your finished and if it doesnt work check your edits
Edited by Wickidnezz (see edit history)

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.