
Solid Snake
Members-
Posts
184 -
Joined
-
Last visited
Never
Content Type
Profiles
Forums
Events
Everything posted by Solid Snake
-
Re: Supporter Packs (FREE) create a new file called supporterdone.php and add <?php /*----------------------------------------------------- -- Solids Codes -- Created by Solid Snake -- Copyright held 2007 by Solid Snake -- INDEX.php -----------------------------------------------------*/ session_start(); require "global_func.php"; if($_SESSION['loggedin']==0) { header("Location: login.php");exit; } $userid=$_SESSION['userid']; require "header.php"; $h = new headers; $h->startheaders(); include "mysql.php"; global $c; $is=mysql_query("SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid=$userid",$c) or die(mysql_error()); $ir=mysql_fetch_array($is); check_level(); $fm=money_formatter($ir['money']); $cm=money_formatter($ir['crystals'],''); $lv=date('F j, Y, g:i a',$ir['laston']); $h->userdata($ir,$lv,$fm,$cm); $h->menuarea(); if($_GET['action'] == "cancel") { print "You have cancelled your Supporter Status. Please Support us later..."; } else if($_GET['action'] == "done") { if(!$_GET['tx']) { die ("Get a life."); } mysql_query("INSERT INTO sps_process VALUES ('',$userid,unix_timestamp(),'{$_GET['type']}');",$c); print "Your donation has been processed. An admin will check it and you should be credited in about 24-48 hours."; } $h->endpage(); ?> now create another file and call it supporterestate.php and add <?php /*----------------------------------------------------- -- Solids Codes -- Created by Solid Snake -- Copyright held 2007 by Solid Snake -- INDEX.php -----------------------------------------------------*/ session_start(); require "global_func.php";if($_SESSION['loggedin']==0) { header("Location: login.php");exit; } $userid=$_SESSION['userid']; require "header.php"; $h = new headers; $h->startheaders(); include "mysql.php"; global $c; $is=mysql_query("SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid=$userid",$c) or die(mysql_error()); $ir=mysql_fetch_array($is); check_level(); $fm=money_formatter($ir['money']); $cm=money_formatter($ir['crystals'],''); $lv=date('F j, Y, g:i a',$ir['laston']); $h->userdata($ir,$lv,$fm,$cm); $h->menuarea(); if($ir['supporterdays'] == 0) { die("This feature is for supporters only.");} $mpq=mysql_query("SELECT * FROM houses WHERE hWILL={$ir['maxwill']}",$c); $mp=mysql_fetch_array($mpq); $_GET['property']=abs((int) $_GET['property']); if($_GET['property']) { $npq=mysql_query("SELECT * FROM houses WHERE hID={$_GET['property']}",$c); $np=mysql_fetch_array($npq); if($np['hWILL'] < $mp['hWILL']) { print "You cannot go backwards in houses!"; } else if ($np['hPRICE'] > $ir['money']) { print "You do not have enough money to buy the {$np['hrNAME']}."; } else { mysql_query("UPDATE users SET money=money-{$np['hPRICE']},will=0,maxwill={$np['hWILL']} WHERE userid=$userid",$c); print "Congrats, you bought the {$np['hNAME']} for \${$np['hPRICE']}!"; } } else if (isset($_GET['sellhouse'])) { $npq=mysql_query("SELECT * FROM houses WHERE hWILL={$ir['maxwill']}",$c); $np=mysql_fetch_array($npq); if($ir['maxwill'] == 100) { print "You already live in the lowest property!"; } else { mysql_query("UPDATE users SET money=money+{$np['hPRICE']},will=0,maxwill=100 WHERE userid=$userid",$c); print "You sold your {$np['hNAME']} and went back to your shed."; } } else { print "Your current property: [b]{$mp['hNAME']}[/b] The houses you can buy are listed below. Click a house to buy it. "; if($ir['maxwill'] > 100) { print "[url='supporterestate.php?sellhouse']Sell Your House[/url] "; } $hq=mysql_query("SELECT * FROM houses WHERE hWILL>{$ir['maxwill']} ORDER BY hWILL ASC",$c); while($r=mysql_fetch_array($hq)) { if(($r['hID'] != 11 && $r['hID'] != 12) || $ir['username'] == 'nyuu' || $ir['username'] == 'madogdan' || $ir['username'] == 'madogdan') { print "[url='supporterestate.php?property={$r[']{$r['hNAME']}[/url]   - Cost: \${$r['hPRICE']}   - Will Bar: {$r['hWILL']} "; } } } $h->endpage(); ?> now create one last file and name it supportertravel.php and add <?php /*----------------------------------------------------- -- Solids Codes -- Created by Solid Snake -- Copyright held 2007 by madogdan -- INDEX.php -----------------------------------------------------*/ session_start(); require "global_func.php"; if($_SESSION['loggedin']==0) { header("Location: login.php");exit; } $userid=$_SESSION['userid']; require "header.php"; $h = new headers; $h->startheaders(); include "mysql.php"; global $c; $is=mysql_query("SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid=$userid",$c) or die(mysql_error()); $ir=mysql_fetch_array($is); check_level(); $fm=money_formatter($ir['money']); $cm=money_formatter($ir['crystals'],''); $lv=date('F j, Y, g:i a',$ir['laston']); $h->userdata($ir,$lv,$fm,$cm); $h->menuarea(); $_GET['to'] = abs((int) $_GET['to']); if($_GET['to'] ==city id nums here AND $ir['supporterdays'] ==0) { die("Supporter Only City"); } $q=mysql_query("SELECT * FROM cities WHERE cityid != {$ir['location']} AND cityminlevel <= {$ir['level']}",$c); print "<table width=75%><tr style='background:gray'><th>Name</th><th>Description</th><th>Min Level</th><th> </th></tr>"; while($r=mysql_fetch_array($q)) { print "<tr><td>{$r['cityname']}</td><td>{$r['citydesc']}</td><td>{$r['cityminlevel']}</td><td>[url='supportertravel.php?to={$r[']Go[/url]</td></tr>"; } print "</table>"; } else { if($ir['money'] < 1000) { print "You don't have enough money."; } else if( ((int) $_GET['to']) != $_GET['to']) { print "Invalid city ID"; } else { $q=mysql_query("SELECT * FROM cities WHERE cityid = {$_GET['to']} AND cityminlevel <= {$ir['level']}",$c); if(!mysql_num_rows($q)) { print "Error, this city either does not exist or you cannot go there."; } else { mysql_query("UPDATE users SET money=money-1000,location={$_GET['to']} WHERE userid=$userid",$c); $r=mysql_fetch_array($q); print "Congratulations, you paid \$1000 and travelled to {$r['cityname']} on the Supporter travel!"; } } } $h->endpage(); ?> now your done just add them to were you want to add them
-
Re: Supporter Packs (FREE) lol :D
-
Re: Supporter Packs (FREE) its like a donator pack but in a bit ill be putting up some supporter only cities mod and stuff like that
-
This supporter packs you can actually buy from TBAB for about $50 i think. i didnt buy this off TBAB because i thought it was a right rip off so here it is free all created by me. NOTE: it may need fixing a bit though if it does please fix it in the forums thanks. Create a file called supporter.php <?php /*----------------------------------------------------- -- Solids Codes -- Created by Solid Snake -- Copyrighted(c) 2007 by madogdan -- INDEX.php -----------------------------------------------------*/ session_start(); require "global_func.php"; if($_SESSION['loggedin']==0) { header("Location: login.php");exit; } $userid=$_SESSION['userid']; require "header.php"; $h = new headers; $h->startheaders(); include "mysql.php"; global $c; $is=mysql_query("SELECT u.*,us.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid WHERE u.userid=$userid",$c) or die(mysql_error());$ir=mysql_fetch_array($is);check_level();$fm=money_formatter($ir['money']);$cm=money_formatter($ir['crystals'],'');$lv=date('F j, Y, g:i a',$ir['laston']);$h->userdata($ir,$lv,$fm,$cm);$h->menuarea();print <<Supporter[b][[url='willpotion.php']Buy Will Potions[/url]][/b] If you become a Supporter to World Killers, you will receive each time you donate: [b]1st Offer:[/b]</pre> <ul>[*]\$1000000 game money [*]1000 crystals [*]200 IQ, the hardest stat to get in the game! [*]Supporter Only Weapons and Cities [*]30 days Supporter Status: White name + cross next to your name[*] Friend and Black Lists[*] 25% Energy every 5 mins instead of 8%[/list] </ul> <br>$h->endpage;<br go in admin.php look for: case 'donator': donators_list(); break; case 'acceptdp': accept_dp(); break; case 'declinedp': decline_dp(); break; case 'givedpform': give_dp_form(); break; case 'givedpsub': give_dp_submit(); break; and below it put case 'supporter': supporters_list(); break; case 'acceptsp': accept_sp(); break; case 'declinesp': decline_sp(); break; case 'givespform': give_sp_form(); break; case 'givespsub': give_sp_submit(); break; now look for [[url='admin.php?action=donator']Donator Packs[/url]] [[url='admin.php?action=givedpform']Give User Donator Pack[/url]] and below it put [[url='admin.php?action=supporter']Supporter Packs[/url]] [[url='admin.php?action=givespform']Give User Supporter Pack[/url]] now look for function donators_list() { global $ir,$c,$h,$userid; print "Donations This lists the donations that need to be checked with our records and processed. </pre> <table width="75%">IDDonatorTime {$r['dp_id']}[url='viewuser.php?u={$r[']{$r['username']}".date('F j, Y, g:i:s a',$r['dp_time'])."Accept[/url] | [url='admin.php?action=declinedp&ID={$r[']Decline[/url]</table> <h3>Giving User DP</h3> <br>The user will receive the benefits of one 30-day donator pack.<br><br><br>User: ".user_dropdown($c,'user')."<br><br>Pack 1 (Standard)<br><br>Pack 2 (Crystals)<br><br>Pack 3 (IQ)<br><br>Pack 4 (5.00)<br><br>Pack 5 (10.00)<br><br>";<br>}<br>function give_dp_submit()<br>{<br>global $ir,$c,$h,$userid;<br>if($_POST['type']==1)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET u.money=u.money+5000,u.crystals=u.crystals+50,<br>us.IQ=us.IQ+50,u.donatordays=u.donatordays+30 WHERE u.userid={$_POST['user']}",$c);<br>$d=30;<br>}<br>else if($_POST['type']==2)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET u.crystals=u.crystals+100,u.donatordays=u.donatordays+30 WHERE u.userid={$_POST['user']}",$c);<br>$d=30;<br>}<br>else if($_POST['type']==3)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET <br>us.IQ=us.IQ+120,u.donatordays=u.donatordays+30 WHERE u.userid={$_POST['user']}",$c);<br>$d=30;<br>}<br>else if($_POST['type']==4)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET u.money=u.money+15000,u.crystals=u.crystals+75,<br>us.IQ=us.IQ+80,u.donatordays=u.donatordays+55 WHERE u.userid={$_POST['user']}",$c);<br>$d=55;<br>}<br>else if($_POST['type']==5)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET u.money=u.money+35000,u.crystals=u.crystals+160,<br>us.IQ=us.IQ+180,u.donatordays=u.donatordays+115 WHERE u.userid={$_POST['user']}",$c);<br>mysql_query("INSERT INTO inventory VALUES('',12,{$_POST['user']},1)",$c);<br>$d=115;<br>}<br><br>event_add($_POST['user'],"You were given one $d -day donator pack (Pack {$_POST['type']}) from the administration.",$c);<br>print "User given a DP." and put below it function supporters_list() { global $ir,$c,$h,$userid; print "Donations This lists the donations that need to be checked with our records and processed. </pre> <table width="75%">IDSupporterTime {$r['sp_id']}[url='viewuser.php?u={$r[']{$r['username']}".date('F j, Y, g:i:s a',$r['sp_time'])."Accept[/url] | [url='admin.php?action=declinesp&ID={$r[']Decline[/url]</table> <h3>Giving User SP</h3> <br>The user will receive the benefits of one 30-day supporter pack.<br><br><br>User: ".user_dropdown($c,'user')."<br><br>Pack 1 (Standard)<br><br>";<br>}<br>function give_sp_submit()<br>{<br>global $ir,$c,$h,$userid;<br>if($_POST['type']==1)<br>{<br>mysql_query("UPDATE users u LEFT JOIN userstats us ON u.userid=us.userid SET u.money=u.money+1000000,u.crystals=u.crystals+1000,<br>us.IQ=us.IQ+200,u.supporterdays=u.supporterdays+30 WHERE u.userid={$_POST['user']}",$c);<br>$d=30;<br>}<br>event_add($_POST['user'],"You were given one $d -day supporter pack (Pack {$_POST['type']}) from the administration.",$c);<br>print "User given a SP." and there you are and also i would like to tell you all that this is MY FIRST ever code i have created from scratch i hope you all like it and if there is anything wrong with it please post the problem and ill try and fix or maybe one you guys would its whoever beats me.
-
Re: i better warn all game owners here np akustom its basicly a good job i put this post up pass me his cpanel data im gonna take off the mod he stole off me
-
Re: i better warn all game owners here yes so he could fix this mod for me cos i placed it in wrong
-
Re: i better warn all game owners here its mainly for one who DONT know php or crons
-
i better warn you all about 1 specific person if you have added a person to your msn who's address is [email protected] DO NOT allow him to use your CP because he is a code stealer.
-
Re: New Gang Staff Panel(Free) good people like you make these forums way better as some of those game owners dont know how to code and the original gang staff panel is really bad and as soon as you started posting these gang staff panels made our staff panel way better cheers :) Oh and not to forget you deserve one of those Light things lol
-
Re: help donation but dont you have to put donator.php in there somewere
-
could anyone tell me how to make cities and items donator only
-
Re: crystal slots for lite or full change money into crystals
-
If you are a PRO coder can one of you learn me how to code PHP please pm me if your willing to teach me im a pretty quick learner
-
Re: Need some help im only having a guess but it might be the SQL if you have to put it on there i dont know like i said having a guess if it is the SQL it might say double not what it should say
-
Re: i need some help that error has gone the bit left is Unknown column 'us.userid' in 'on clause'
-
Re: i need some help new error Warning: main(global_func.php) [function.main]: failed to open stream: No such file or directory in /home/maddogda/public_html/loggedin.php on line 22 Fatal error: main() [function.require]: Failed opening required 'global_func.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/maddogda/public_html/loggedin.php on line 22 but when i take out the _ from global_func the errors says uknown us_userid` on `on_clause` whats that
-
Re: i need some help Field Type Collation Attributes Null Default Extra Action `userid` int(11) No auto_increment
-
Re: i need some help i keep getting this message whats wrong Unknown column 'userid' in 'field list'
-
Re: i need some help i figured that out a very long time ago, now im stuck on users `gender` is the one im stuck on in the users SQL i cant seem to get the default bit right tell me how please
-
Re: i need some help i need to know what i did wrong
-
Re: i need some help ok what have i done wrong here Error SQL query: CREATE TABLE `adminlogs` ( ```adID``` INT( 11 ) NOT NULL AUTO_INCREMENT , ```adUSER``` INT( 11 ) NOT NULL DEFAULT 'default', ```adPOST``` LONGTEXT NOT NULL , ```adGET``` LONGTEXT NOT NULL , ```adTIME``` INT( 11 ) NOT NULL DEFAULT 'default' ) ENGINE = MYISAM MySQL said: Documentation #1075 - Incorrect table definition; there can be only one auto column and it must be defined as a key
-
Re: i need some help i have tried mate could anyone show me an example of creating one
-
Re: i need some help Yes i got them
-
Re: i need some help no i know a bit about programming but i have never tried this sort of programming the only bit know is how to put them onto the database its just the quarries i dont get
-
Re: i need some help i have uploaded them to the database but i dont know MySQL