
corruptcity || skalman
Members-
Posts
358 -
Joined
-
Last visited
-
Days Won
3
Content Type
Profiles
Forums
Events
Everything posted by corruptcity || skalman
-
Slot machine v2
corruptcity || skalman replied to corruptcity || skalman's topic in Free Modifications
whoops on the $u for the userid and for the little table it shows it all no matter how many lines you pick although with a few if statements u can change that to only show the lines your playing and line 4 and 5 are diagional line hence why you only see 3 lines -
Hi i got bored and decided to recode the stock slot machine and add lines into it increasing the potential rewards the code has been secured to the best of my abilities and i have tested it and it works on my game. You can use the demo account on my game to test the slot machine out username and password is both demo here is the code slotmachine.php <?php //Slot Machine coded by skalman for makewebgames //this is a free mod made by me do sell, redistrubite or claim as you own //2nd may 2011 //this is an editted slot machine where you can use up to 3 lines increasing your players chance of winning //if i was drawing a box to show you how it works if you dont know you would have a 3 by 3 box number 1 - 9 with //the top left number 1 //the middle line is line 1 and the uses slot 4 - 6 //the top line is line 2 and uses slot 1 - 3 //bottom line uses slot 7 - 9 include_once (DIRNAME(__FILE__) . '/globals.php'); echo"<h3>Slot Machine</h3> <hr/>"; $fee = 100; if(!$_POST['submit']) { echo"<form action='slotsmachine.php' method='post'> To play the slot machine it is \$".number_format($fee)." * the amount of line you choose to play with.<br /> How many lines would you like to use? <select name='lines' id='lines'> <option value='1'>1</option> <option value='2'>2</option> <option value='3'>3</option> <option value='4'>5</option> </select> <input type='submit' name='submit' value='pull the arm'/> </form>"; } else { $lines = $_POST['lines']; $amnt = ($fee * $lines); $db->query(sprintf("UPDATE users SET money = money - %d WHERE (userid = %u)", $amnt, $userid)); $slot[1] = (int)rand(1,9); $slot[2] = (int)rand(1,9); $slot[3] = (int)rand(1,9); $slot[4] = (int)rand(1,9); $slot[5] = (int)rand(1,9); $slot[6] = (int)rand(1,9); $slot[7] = (int)rand(1,9); $slot[8] = (int)rand(1,9); $slot[9] = (int)rand(1,9); $line1 = $slot[4] == $slot[5] && $slot[5] == $slot[6]; $line1a= $slot[4] == $slot[5] || $slot[5] == $slot[6]; $line2 = $slot[1] == $slot[2] && $slot[2] == $slot[3]; $line2a = $slot[1] == $slot[2] || $slot[2] == $slot[3]; $line3 = $slot[7] == $slot[8] && $slot[8] == $slot[9]; $line3a = $slot[7] == $slot[8] || $slot[8] == $slot[9]; $line4 = $slot[3] == $slot[5] && $slot[5] == $slot[3]; $line4a = $slot[3] == $slot[5] || $slot[5] == $slot[3]; $line5 = $slot[1] == $slot[5] && $slot[5] == $slot[9]; $line5a = $slot[1] == $slot[5] || $slot[5] == $slot[9]; echo" <table width='60%' align='center'> <tr> <th colspan='3'>2nd Line</th> </tr> <tr> <td>".number_format($slot[1])."</td> <td>".number_format($slot[2])."</td> <td>".number_format($slot[3])."</td> </tr> <tr> <th colspan='3'>1st Line</th> </tr> <td>".number_format($slot[4])."</td> <td>".number_format($slot[5])."</td> <td>".number_format($slot[6])."</td> </tr> <tr> <th colspan='3'>3rd Line</th> </tr> <td>".number_format($slot[7])."</td> <td>".number_format($slot[8])."</td> <td>".number_format($slot[9])."</td> </tr> </table>"; //checks the 1st 3 slots if($lines = 1) { //all 3 match //if($slot[1] == $slot[2] && $slot[2] == $slot[3]) if($line1) { $won = 250; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //2 in a line match elseif($line1a) { $won = 150; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } else { $won = 0; echo"You pull the arm wait for it to stop spinning and you lost \$".number_format($won)."<br />"; } } //checks the 1st 6 slots elseif($lines = 2) { //both lines match if((line1) && ($line2)) { $won = 750; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //either 1 matches if((line1) || ($line2)) { $won = 500; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //any 2 in either lines match elseif(($line1a) || ($line2a)) { $won = 350; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //nothing else { $won = 0; echo"You pull the arm wait for it to stop spinning and you lost \$".number_format($won)."<br />"; } } //checks all 9 slots elseif($lines = 3) { //all 3 match if(($line1) && ($line2) && ($line3)) { $won = 1500; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 1 matches with either line 2 or 3 elseif(($line1) && ($line2) || ($line3)) { $won = 1000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 2 matches with either line 1 or 3 elseif((line2) && ($line1) || ($line3)) { $won = 1000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 3 matches with either line 1 or 2 elseif(($line3) && ($line1) || ($line2)) { $won = 1000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //only 1 of the 3 match elseif(($line1) || ($line2) || ($line3)) { $won = 750; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //any 2 in a line match elseif(($line1a) || ($line2a) || ($line3a)) { $won = 500; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } else { $won = 0; echo"You pull the arm wait for it to stop spinning and you lost \$".number_format($won)."<br />"; } } //checks all 9 slots else { //all 5 lines match if(($line1) && ($line2) && ($line3) && ($line4) && ($line5)) { $won = 2500; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 1 matches with either line 2 3 4 or 5 elseif(($line1) && ($line2) || ($line3) || ($line4) || ($line5)) { $won = 2000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 2 matches with either line 1 3 4 or 5 elseif((line2) && ($line1) || ($line3) || ($line4) || ($line5)) { $won = 2000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 3 matches with either line 1 2 4 or 5 elseif(($line3) && ($line1) || ($line2) || ($line4) || ($line5)) { $won = 2000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 4 matches with either line 1 2 3 or 5 elseif((line4) && ($line1) || ($line2) || ($line3) || ($line4)) { $won = 2000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //line 5 matches with either line 1 2 3 or 4 elseif(($line5) && ($line1) || ($line2) || ($line3) || ($line4)) { $won = 2000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //only 1 of the 5 match elseif(($line1) || ($line2) || ($line3) || ($line4) || ($line5)) { $won = 1500; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //any 2 in a line match elseif(($line1a) || ($line2a) || ($line3a) || ($line4a) || ($line5a)) { $won = 1000; echo"You pull the arm wait for it to stop spinning and you won \$".number_format($won)."<br />"; $db->query(sprintf("UPDATE users SET money = money + %d WHERE (userid = %u)", $won, $userid)); } //neither match else { $won = 0; echo"You pull the arm wait for it to stop spinning and you lost \$".number_format($won)."<br />"; } } echo" Would you like to change the amount of lines to use?<br /> <form action='slotsmachine.php' method='post'> <input type='hidden' name='lines' value='$lines'/> <input type='submit' name='submit' value='swing again'/> </form> <form action='slotsmachine.php' method='post'> <select name='lines' id='lines'> <option value='1'>1</option> <option value='2'>2</option> <option value='3'>3</option> <option value='4'>5</option> </select> <input type='submit' name='submit' value='pull the arm'/> </form>"; } $h->endpage(); ?>
-
found this when loggin into yahoo messenger today lol
-
Prison Survival - Out Rank, Out Will, Out Last
corruptcity || skalman replied to daftrude's topic in General Discussion
dam u beat me 2 it zu lol -
Prison Survival - Out Rank, Out Will, Out Last
corruptcity || skalman replied to daftrude's topic in General Discussion
you game is unsecured as hell, is just basically a stock v2 engine with a grey background and changed the banner your gonna need todo a hell of a lot more work to even get players -
m8 dont get me started on multi users tables for 1 of my foundation degree in ICT assigments was a www/internet project where had to build a help desk website using UML diagrams from my database unit and i ended up with 2 users tables and had ambiguous userids and had to spend hours fixing that and in the end ended up creating a user_login table that was to sit above the 2 user tables which gave the tables their ids
-
Apples are not know by their smartness
corruptcity || skalman replied to a_bertrand's topic in Tech News
well apple is run by communists lol -
function report_clear
corruptcity || skalman replied to corruptcity || skalman's topic in Engine Support
yeah ive downloaded v2.0.3 but im not prepered to waste more time editting the same files again to add the template and all the changes ive made to make it less mccodes -
hi i was just working in the staff panel and only just decided to post about it but why is there the report_clear function in most of the staff files when its not called in the get switch of most of the scripts other than staff_users ino i can simple delete them but was just wonder why dabs/cb put it in most of the staff_ files
-
the reason why the mail count doesnt increase is coz there isnt the update users query to update new_mail so it will always stay 0
-
nokia have released a symbian s60 edition 5 emulator
-
sorry m8 didnt read what board it was in lol ignore me then
-
as the owner of corruptcity i would like it to be know that its only just started beta and that im still working on improving it, i would like to thank alain for pointing out the mailbox undefined error as that only happens when you click contactlist then try to click back to inbox
-
i would see you a copy of the attack script i coded that is on my game http://corruptcity.net
-
hi was watchin rude tube on the box last night as 1 of the utube vid was this which is a parody of empire state of mind called newport state of mind
-
how long do you think it will be before paul is back on the streets? as there will be no need 2 hire him to secure v2 lol
-
bout bloody time m8
-
its ok i editted the stock v2 login script but had to end up using dual gateways and deviating from my class diagram
-
ok thanks for the replies guys look like ill need 2 redisgn the login page :(
-
no i have to follow the UML diagrams i created for it and i ended up with 2 tables for the end users clients and technicians
-
hi im studyin a foundation degree in ICT atm and 1 of the units im doing is about the internet and WWW where we are tasked with building a helpdesk site but ive come accross with a problem with that both the techies and clients need 2 be able to login to it and im stuck thinking how to get that to work now ive come up with 2 ideas and would like some imput if either or both would work or if you know another way that do it method 1 basically would be a select query in the technician table where username and password match then have $db->num_rows(query) == 0) { false runs query for the clients } else { true does the $r=$db->fetch_row(query); } then the rest method 2 put both tables in 1 query with a JOIN and in the WHERE have WHERE t.tech_login = $_POST['blah'] AND t.blah = $_POST['blah'] OR c.cust_login = $_POST['blah'] AND c.cust_password thanks skal
-
2 words get dreamweaver lol
-
CorruptCity Now open for beta
corruptcity || skalman replied to corruptcity || skalman's topic in Game Projects
CorruptCity is now open for beta