Jump to content
MakeWebGames

HITMAN 17

Members
  • Posts

    1,145
  • Joined

  • Last visited

Everything posted by HITMAN 17

  1. Re: [v1]Request For Failing Crime Results to jail i have tryed this and it dosnt put me in jail can anyone fix it please
  2. Re: [mccode] Advanced Properties ok guys im still getting this error Unknown column 'jb.jbID' in 'on clause'
  3. Re: [mccode] Advanced Properties why not try and improve on gangs more and take up some of those requests
  4. i have not yet seen a working version of this and whenever i try i fail please can someone make this for v1 and i will test it out for them thank you
  5. Re: [mccode] Gangs http://chavsterv1.co.cc/Factions.zip Please +1 for converting if you feel like it no instructions need any help with mainmenu crap mail me
  6. Re: [mccode] Gangs   i am very sorry guys i fucked it up as i was in a rush here <?php /*----------------------------------------------------- -- Mono Country v1.0 BETA -- A product of DBS-entertainment -- Copyright held 2005 by Dabomstew -- 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['u'] = abs((int) $_GET['u']); if(!$_GET['u']) { print "Invalid use of file"; } else { $q=mysql_query("SELECT u.*,us.*,c.*,h.*,g.*,f.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid LEFT JOIN cities c ON u.location=c.cityid LEFT JOIN houses h ON u.maxwill=h.hWILL LEFT JOIN factions g ON g.faID=u.faction LEFT JOIN fedjail f ON f.fed_userid=u.userid WHERE u.userid={$_GET['u']}",$c); if(mysql_num_rows($q) == 0) { print "Sorry, we could not find a user with that ID, check your source."; } else { $r=mysql_fetch_array($q); if($r['user_level'] == 1) { $userl="Member"; } else if($r['user_level'] == 2) { $userl="Admin"; } else if ($r['user_level'] == 3) { $userl="Secretary"; } else if($r['user_level'] == 0) { $userl="NPC"; } else if($r['user_level']==4) { $userl="IRC Mod"; } else {$userl="Assistant"; } $lon=date('F j, Y g:i:s a',$r['laston']); $sup=date('F j, Y g:i:s a',$r['signedup']); $ts=$r['strength']+$r['agility']+$r['guard']+$r['labour']+$r['IQ']; $d=""; $la=time()-$r['laston']; $unit="seconds"; if($la >= 60) { $la=(int) ($la/60); $unit="minutes"; } if($la >= 60) { $la=(int) ($la/60); $unit="hours"; if($la >= 24) { $la=(int) ($la/24); $unit="days"; } } if($r['donatordays']) { $r['username'] = "<font color=red>{$r['username']}</font>";$d="[img=donator.gif]"; } if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } print "<h3>Profile for {$r['username']}</h3> <table width=75%><tr style='background:gray'><th>General Info</th><th>Financial Info</th> <th>Display Pic</th></tr> <tr><td>Name: {$r['username']} [{$r['userid']}] $d User Level: $userl Duties: {$r['duties']} Gender: {$r['gender']} Signed Up: $sup Last Active: $lon Last Action: $la $unit ago Online: $on Days Old: {$r['daysold']} Location: {$r['cityname']}</td><td> Money: \${$r['money']} Crystals: {$r['crystals']} Property: {$r['hNAME']} Referals: "; $rr=mysql_query("SELECT * FROM referals WHERE refREFER={$r['userid']}",$c); print mysql_num_rows($rr); $q_y=mysql_query("SELECT * FROM friendslist WHERE fl_ADDED={$r['userid']}",$c); $q_z=mysql_query("SELECT * FROM blacklist WHERE bl_ADDED={$r['userid']}",$c); print " Friends: ".mysql_num_rows($q_y)." Enemies: ".mysql_num_rows($q_z)." </td> <td rowspan='2'>"; if($r['display_pic']) { print "[img={$r[]"; } else { print "This user has no display pic!"; } print "</td></tr> <tr style='background:gray'><th>Physical Info</th><th>Links</th></tr> <tr><td>Level: {$r['level']} Health: {$r['hp']}/{$r['maxhp']} Gang: "; if($r['gang']) { print "[url='factions.php?step=profile&ID={$r[']{$r['faNAME']}[/url]"; } else { print "N/A"; } if($r['fedjail']) { print " [b]<font color=red>In federal jail for {$r['fed_days']} day(s). {$r['fed_reason']}</font>"; } if($r['hospital']) { print " [b]<font color=red>In hospital for {$r['hospital']} minutes. {$r['hospreason']}</font>[/b]"; } if($ir['user_level'] == 2 || $ir['user_level'] == 3 || $ir['user_level'] == 5) { print " IP Address: {$r['lastip']}"; print "<form action='staffnotes.php' method='post'> Staff Notes: <textarea rows=7 cols=40 name='staffnotes'>{$r['staffnotes']}</textarea> <input type='hidden' name='ID' value='{$_GET['u']}' /> <input type='submit' value='Change' /></form>"; } print "</td><td>[[url='mailbox.php?action=compose&ID={$r[']Send Mail[/url]] [[url='sendcash.php?ID={$r[']Send Cash[/url]] [[url='attack.php?ID={$r[']Attack[/url]]"; if($ir['user_level'] == 2 || $ir['user_level'] == 3 || $ir['user_level'] == 5) { print " [[url='jailuser.php?userid={$r[']Jail[/url]] [[url='mailban.php?userid={$r[']MailBan[/url]]"; } if($ir['donatordays'] > 0) { print " [[url='friendslist.php?action=add&ID={$r[']Add Friends[/url]] [[url='blacklist.php?action=add&ID={$r[']Add Enemies[/url]] "; } print "</td></tr></table>"; } } $h->endpage(); ?>
  7. Re: Hospital Time what about to display secounds as well
  8. Re: Request l Jail Hospital Correct Time how am i suppose to find it if i dont know what its called and yer miniman thanks for that i want it like torncity not exact though
  9. Re: How do i add images on to events broblem is the images have gone
  10. From exactly when someone mugs you and puts you in hospital for hours minutes and secounds and shows this to you and everyone else
  11. Re: right hand side main menu i got this now its great just look at my layout now
  12. Re: [mccode] Gangs ye lol that would be great also why not make roles like what are the gang role and make them show upo when you see all of the users in the gang and what about managing the gang applications and a person who looks after armory and stuff
  13. look here on www.lostpower.com look when you get an event how do i go that when i get an event on my mainmenu please can you give me example thanks
  14. Re: [mccode] Gangs ye btw sorry about earlier guys i am going to be on now for the rest of the night so i am just packing the mod into a zip file with instructions
  15. Re: [mccode] Gangs a little its a lot better i will be happy to convert this so i will start now let me just go get my cup of tea
  16. Re: Add Jail Time to Crimes! ok for some reason the docrime.php isnt putting anyone in jail
  17. Re: [mccode] Gangs replace viewuser with <?php /*----------------------------------------------------- -- Mono Country v1.0 BETA -- A product of DBS-entertainment -- Copyright held 2005 by Dabomstew -- 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['u'] = abs((int) $_GET['u']); if(!$_GET['u']) { print "Invalid use of file"; } else { $q=mysql_query("SELECT u.*,us.*,c.*,h.*,g.*,f.* FROM users u LEFT JOIN userstats us ON u.userid=us.userid LEFT JOIN cities c ON u.location=c.cityid LEFT JOIN houses h ON u.maxwill=h.hWILL LEFT JOIN factions g ON g.faID=u.faction LEFT JOIN fedjail f ON f.fed_userid=u.userid WHERE u.userid={$_GET['u']}",$c); if(mysql_num_rows($q) == 0) { print "Sorry, we could not find a user with that ID, check your source."; } else { $r=mysql_fetch_array($q); if($r['user_level'] == 1) { $userl="Member"; } else if($r['user_level'] == 2) { $userl="Admin"; } else if ($r['user_level'] == 3) { $userl="Secretary"; } else if($r['user_level'] == 0) { $userl="NPC"; } else if($r['user_level']==4) { $userl="IRC Mod"; } else {$userl="Assistant"; } $lon=date('F j, Y g:i:s a',$r['laston']); $sup=date('F j, Y g:i:s a',$r['signedup']); $ts=$r['strength']+$r['agility']+$r['guard']+$r['labour']+$r['IQ']; $d=""; $la=time()-$r['laston']; $unit="seconds"; if($la >= 60) { $la=(int) ($la/60); $unit="minutes"; } if($la >= 60) { $la=(int) ($la/60); $unit="hours"; if($la >= 24) { $la=(int) ($la/24); $unit="days"; } } if($r['donatordays']) { $r['username'] = "<font color=red>{$r['username']}</font>";$d="[img=donator.gif]"; } if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } print "<h3>Profile for {$r['username']}</h3> <table width=75%><tr style='background:gray'><th>General Info</th><th>Financial Info</th> <th>Display Pic</th></tr> <tr><td>Name: {$r['username']} [{$r['userid']}] $d User Level: $userl Duties: {$r['duties']} Gender: {$r['gender']} Signed Up: $sup Last Active: $lon Last Action: $la $unit ago Online: $on Days Old: {$r['daysold']} Location: {$r['cityname']}</td><td> Money: \${$r['money']} Crystals: {$r['crystals']} Property: {$r['hNAME']} Referals: "; $rr=mysql_query("SELECT * FROM referals WHERE refREFER={$r['userid']}",$c); print mysql_num_rows($rr); $q_y=mysql_query("SELECT * FROM friendslist WHERE fl_ADDED={$r['userid']}",$c); $q_z=mysql_query("SELECT * FROM blacklist WHERE bl_ADDED={$r['userid']}",$c); print " Friends: ".mysql_num_rows($q_y)." Enemies: ".mysql_num_rows($q_z)." </td> <td rowspan='2'>"; if($r['display_pic']) { print "[img={$r[]"; } else { print "This user has no display pic!"; } print "</td></tr> <tr style='background:gray'><th>Physical Info</th><th>Links</th></tr> <tr><td>Level: {$r['level']} Health: {$r['hp']}/{$r['maxhp']} Gang: "; if($r['gang']) { print "[url='gangs.php?action=view&ID={$r[']{$r['faNAME']}[/url]"; } else { print "N/A"; } if($r['fedjail']) { print " [b]<font color=red>In federal jail for {$r['fed_days']} day(s). {$r['fed_reason']}</font>"; } if($r['hospital']) { print " [b]<font color=red>In hospital for {$r['hospital']} minutes. {$r['hospreason']}</font>[/b]"; } if($ir['user_level'] == 2 || $ir['user_level'] == 3 || $ir['user_level'] == 5) { print " IP Address: {$r['lastip']}"; print "<form action='staffnotes.php' method='post'> Staff Notes: <textarea rows=7 cols=40 name='staffnotes'>{$r['staffnotes']}</textarea> <input type='hidden' name='ID' value='{$_GET['u']}' /> <input type='submit' value='Change' /></form>"; } print "</td><td>[[url='mailbox.php?action=compose&ID={$r[']Send Mail[/url]] [[url='sendcash.php?ID={$r[']Send Cash[/url]] [[url='attack.php?ID={$r[']Attack[/url]]"; if($ir['user_level'] == 2 || $ir['user_level'] == 3 || $ir['user_level'] == 5) { print " [[url='jailuser.php?userid={$r[']Jail[/url]] [[url='mailban.php?userid={$r[']MailBan[/url]]"; } if($ir['donatordays'] > 0) { print " [[url='friendslist.php?action=add&ID={$r[']Add Friends[/url]] [[url='blacklist.php?action=add&ID={$r[']Add Enemies[/url]] "; } print "</td></tr></table>"; } } $h->endpage(); ?>
  18. Re: [mccode] Gangs ok i fixed this myself so if anyone else has same problem here is the code <?php /*----------------------------------------------------- -- Mono Country v1.0 BETA -- A product of DBS-entertainment -- Copyright held 2005 by Dabomstew -- 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 "<font face='Arial' size='4'>Factions</font><hr width='90%'>"; switch ($_GET['step']) { case 'create': create_faction(); break; case 'profile': faction_profile(); break; case 'users': faction_members(); break; case 'search': search_factions(); break; case 'apply': faction_apply(); break; default: factions_index(); break; } function factions_index() { global $ir,$c,$userid,$h; $sql = sprintf("SELECT * FROM `factions` fa LEFT JOIN `users` u ON (u.userid = fa.faLEADER) ORDER BY faID DESC"); $q = mysql_query($sql); print "This is a list of all factions by ID <table width='90%' cellspacing='1'><tr bgcolor='#AAAAAA'><th width='25%'>Name</th><th width='13%'>Members</th><th width='12%'>Reputation</th><th width='50%'>Image</th></tr>"; while($r = mysql_fetch_array($q)) { print "<tr><td>[url='factions.php?step=profile&ID={$r[']<h3>{$r['faNAME']}</h3>[/url]</td><td>"; $membs = sprintf("SELECT * FROM `users` WHERE faction = %u", mysql_real_escape_string($r['faID'])); $mems = mysql_query($membs); print mysql_num_rows($mems)."</td> <td>{$r['faREPUTATION']}</td> <td>[img={$r[]</td></tr>"; } print "</table> <hr width='90%'>> [url='explore.php']Back[/url]<hr width='90%'>"; } function create_faction() { global $ir,$c,$userid,$h; $sql = sprintf("SELECT * FROM `factions` WHERE faID > 0"); $q = mysql_query($sql); $fcs = mysql_num_rows($q); $r['faCOST'] = ($fcs*10000); if($ir['money'] < $r['faCOST']) { print " You don't have enough money. It costs ".money_formatter($r['faCOST'])." to create a new Faction. <hr width='90%'>> [url='explore.php']Back[/url]<hr width='90%'>"; } else if($ir['faction'] > 0) { print " You are already part of a Faction. Leave before creating a new one. <hr width='90%'>> [url='explore.php']Back[/url]<hr width='90%'>"; } else if($_POST['name'] AND $_POST['description'] AND $_POST['status']) { $ins = sprintf("INSERT INTO `factions` (`faID`, `faNAME`, `faDESC`, `faSTATUS`, `faLEADER`, `faCOLEADER`, `faCAPACITY`, `faREPUTATION`) VALUES ('NULL','%s', '%s', '%s', '%d', '%d', '%d', '%d')", mysql_real_escape_string($_POST['name']), mysql_real_escape_string($_POST['description']), mysql_real_escape_string($_POST['status']), $userid, $userid, 10, 100); mysql_query($ins); $r['insID'] = mysql_insert_id($c); $fac = sprintf("UPDATE `users` SET faction = %d, money=money-%d WHERE (userid = %u)", $r['insID'], $r['faCOST'], $userid); mysql_query($fac); print " The {$_POST['name']} faction was successfully created. <hr width='90%'>> [url='factions.php?step=manage']Back[/url]<hr width='90%'>"; } else { print " <form action='factions.php?step=create' method='post'> A new faction will cost $10,000 times the amount of factions in existence. The current price is [b]".money_formatter($r['faCOST'])."[/b]. Name your Faction <input type='text' name='name' /> Choose a Status <select type='dropdown' name='status'> <option value='Peaceful'>Peaceful</option> <option value='Aggressive'>Aggressive</option> </select> Description <textarea name='description' cols='40' rows='7'></textarea> <input type='submit' value='Create' /></form> <hr width='90%'>> [url='factions.php']Back[/url]<hr width='90%'>"; } } function faction_profile() { global $ir,$c,$userid,$h; $sql = sprintf("SELECT * FROM `factions` fa LEFT JOIN `users` u ON (u.userid = fa.faLEADER) WHERE (fa.faID = %u)", mysql_real_escape_string($_GET['ID'])); $q = mysql_query($sql); $r = mysql_fetch_array($q); print " <table width='400' bgcolor='#DFDFDF'><tr><td align='center'>[b]<font size='5'>{$r['faNAME']}</font>[/b]</td></tr></table> [img={$r[] <table width='400' bgcolor='#DFDFDF'><tr><td valign='middle' align='center'><font size='5'>[b]{$r['faREPUTATION']}[/b]</font></td></tr></table> <table width='400' bgcolor='#DFDFDF'><tr><td width='200' valign='middle'> [b]Leader: [/b][url='viewuser.php?u={$r[']{$r['username']}[/url] "; $col = sprintf("SELECT * FROM `users` WHERE (userid = %u)", mysql_real_escape_string($r['faCOLEADER'])); $q2 = mysql_query($col); $co = mysql_fetch_array($q2); print "[b]Co-Leader: [/b][url='viewuser.php?u={$r[']{$co['username']}[/url] "; $membs = sprintf("SELECT * FROM `users` WHERE faction = %u", mysql_real_escape_string($r['faID'])); $mems = mysql_query($membs); print "[b]Members: [/b]".mysql_num_rows($mems)." [b]Reputation: [/b]{$r['faREPUTATION']} [b]Current chain: [/b]{$r['faCHAIN']} attacks [b]Best chain: [/b]{$r['faBCHAIN']} attacks [b]Status: [/b]"; if ($r['faSTATUS'] == 'Peaceful') { print "<font color='green'>[b]Peaceful[/b]</font>"; } else { print "<font color='red'>[b]Aggressive[/b]</font>"; } print " </td> <td valign='top' align='right' width='200'>[url='factions.php?step=users&ID={$r[']User list[/url] < [url='factions.php?step=apply&ID={$r[']Apply[/url] < </td></tr></table> <table width='400' bgcolor='#DFDFDF'><tr> <td width='50%' height='100%'> <table width='100%' height='100%'><tr> <td align='center'> {$r['faDESC']} </td> </tr></table></td></tr></table> <hr width='90%'>> [url='factions.php']Back[/url]<hr width='90%'>"; } function faction_members() { global $ir,$c,$userid,$h; $sql = sprintf("SELECT * FROM `factions` fa LEFT JOIN `users` u ON (u.faction = fa.faID) WHERE (fa.faID = %u)", mysql_real_escape_string($_GET['ID'])); $q = mysql_query($sql); print "<table width='90%' cellspacing='1'><tr bgcolor='#AAAAAA'><th width='25%'>Num</th><th width='25%'>Name</th><th width='25%'>Level</th><th width='25%'>Days in Faction</th></tr>"; while ($r = mysql_fetch_array($q)) { $cn++; print "<tr><td>$cn.</td><td>[url='viewuser.php?u={$r[']{$r['username']}[/url]</td><td>{$r['level']}</td><td>{$r['faction_days']}</td></tr>"; } print "</table> <hr width='90%'>> [url='factions.php?step=profile&ID={$_GET[']Back[/url]<hr width='90%'>"; } function search_factions() { global $ir,$c,$userid,$h; if (!$_POST['name']) { print "<form action='factions.php?step=search' method='post'> [b]Search by Keyword[/b] Insert the keyword that you'd like to search for Factions: <input type='text' name='name'> <input type='submit' value='Search'></form> <hr width='90%'>> [url='factions.php']Back[/url]<hr width='90%'>"; } else { $sql = sprintf("SELECT * FROM `factions` fa LEFT JOIN `users` u ON (u.userid = fa.faLEADER) WHERE (`faNAME` LIKE '%%%s%%')", mysql_real_escape_string($_POST['name'])); $q = mysql_query($sql); print "[b]Search by Keyword[/b] Keyword: {$_POST['name']} <table width='90%' cellspacing='1'><tr bgcolor='#AAAAAA'><th width='25%'>Name</th><th width='13%'>Members</th><th width='12%'>Reputation</th><th width='50%'>Image</th></tr>"; while($r = mysql_fetch_array($q)) { print "<tr><td>[url='factions.php?step=profile&ID={$r[']<h3>{$r['faNAME']}</h3>[/url]</td><td>"; $membs = sprintf("SELECT * FROM `users` WHERE faction = %u", mysql_real_escape_string($r['faID'])); $mems = mysql_query($membs); print mysql_num_rows($mems)."</td> <td>{$r['faREPUTATION']}</td> <td>[img={$r[]</td></tr>"; } print "</table> <hr width='90%'>> [url='factions.php?step=search']Back[/url]<hr width='90%'>"; } } function faction_apply() { global $ir,$c,$userid,$h; if ($ir['faction']) { print " You are already in a faction at this time. <hr width='90%'>> [url='factions.php']Back[/url]<hr width='90%'>"; } else if (!$_GET['act']) { print " Please type an application to this faction below: <form action='factions.php?step=apply&act=submit&ID={$_GET['ID']}' method='post'> <textarea type='text' name='app' cols='50' rows='8'>Type your application here</textarea> <input type='submit' value='Submit'></form> <hr width='90%'>> [url='factions.php?step=profile&ID={$_GET[']Back[/url]<hr width='90%'>"; } else if ($_GET['act'] == 'submit') { if ($_POST['app']) { $ins = sprintf("INSERT INTO `faction_apps` (`fpID`, `fpUSER`, `fpFACTION`, `fpAPP`, `fpTIME`) VALUES ('NULL','%d', '%d', '%s', '%d')", mysql_real_escape_string($ir['userid']), mysql_real_escape_string($_GET['ID']), mysql_real_escape_string($_POST['app']), time()); mysql_query($ins); print " Your application was submitted! <hr width='90%'>> [url='factions.php?step=profile&ID={$_GET[']Back[/url]<hr width='90%'>"; } else { print " You did not type an application to send! <hr width='90%'>> [url='factions.php?step=apply&ID={$_GET[']Back[/url]<hr width='90%'>"; } } } $h->endpage(); ?>
  19. Re: [mccode] Gangs dude great mod on problem i get this error Warning: Missing argument 4 for headers::userdata(), called in /home/***/public_html/factions.php on line 16 and defined in /home/***/public_html/header.php on line 21 which on that line is } function userdata($ir,$lv,$fm,$cm,$dosessh=1) {
  20. Re: [mccode v2] Not much of a MOD more of a great addon.. Private Messenger o yer lol im very sorry www.chavsterv1.co.cc bit like msn
  21. Re: [mccode v2] Not much of a MOD more of a great addon.. Private Messenger ok guys please dont mess about with it like stupid names but check out my chat www.chavster.co.cc
  22. Re: Add Jail Time to Crimes! well this is what i got <?php /*----------------------------------------------------- -- Mono Country v1.0 BETA -- A product of DBS-entertainment -- Copyright held 2005 by Dabomstew -- 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['c']=abs((int) $_GET['c']); if(!$_GET['c']) { print "Invalid crime"; } else { $q=mysql_query("SELECT * FROM crimes WHERE crimeID={$_GET['c']}",$c); $r=mysql_fetch_array($q); if($ir['brave'] < $r['crimeBRAVE']) { print "You do not have enough Brave to perform this crime."; } else { $ec="\$sucrate=".str_replace(array("LEVEL","EXP","WILL","IQ"), array($ir['level'], $ir['exp'], $ir['will'], $ir['IQ']),$r['crimePERCFORM']).";"; eval($ec); print $r['crimeITEXT']; $ir['brave']-=$r['crimeBRAVE']; mysql_query("UPDATE users SET brave={$ir['brave']} WHERE userid=$userid",$c); if(rand(1,100) <= $sucrate) { print str_replace("{money}",$r['crimeSUCCESSMUNY'],$r['crimeSTEXT']); $ir['money']+=$r['crimeSUCCESSMUNY']; $ir['exp']+=(int) ($r['crimeSUCCESSMUNY']/8); mysql_query("UPDATE users SET money={$ir['money']},exp={$ir['exp']} WHERE userid=$userid",$c); } else { if(rand(1, 2) == 1) { print $r['crimeFTEXT']; } else { print $r['crimeJTEXT']; mysql_query("UPDATE `users` SET `jail` = '$r[crimeJAILTIME]', `jail_reason` = '$r[crimeJREASON]' WHERE `userid` = '$userid'",$c); } } print " [url='docrime.php?c={$_GET[']Try Again[/url] [url='criminal.php']Crimes[/url]"; } } $h->endpage(); ?> i will post all of this mod when it is fixed but this is correct i think
  23. Re: Im trying to do make v1... OK IM ON THE EDGE OF GIVING UP AS THATS NOT HELPING Please add me on msn is ent you pm
  24. Re: Im trying to do make v1... ok here is my docrime.php <?php /*----------------------------------------------------- -- Your Game Name v1.0 BETA -- A product of DBS-entertainment -- Copyright held 2005 by Dabomstew, ColdBlooded -- 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['jail'] or $ir['hospital']) { die("This page cannot be accessed while in jail or hospital."); } $_GET['c']=abs((int) $_GET['c']); if(!$_GET['c']) { print "Invalid crime"; } else { $q=mysql_query("SELECT * FROM crimes WHERE crimeID={$_GET['c']}",$c); $r=mysql_fetch_array($q); if($ir['brave'] < $r['crimeBRAVE']) { print "You do not have enough Brave to perform this crime."; } else { $ec="\$sucrate=".str_replace(array("LEVEL","CRIMEXP","EXP","WILL","IQ"), array($ir['level'], $ir['crimexp'], $ir['exp'], $ir['will'], $ir['IQ']),$r['crimePERCFORM']).";"; eval($ec); print $r['crimeITEXT']; $ir['brave']-=$r['crimeBRAVE']; mysql_query("UPDATE users SET brave={$ir['brave']} WHERE userid=$userid",$c); if(rand(1,100) <= $sucrate) { print str_replace("{money}",$r['crimeSUCCESSMUNY'],$r['crimeSTEXT']); $ir['money']+=$r['crimeSUCCESSMUNY']; $ir['crystals']+=$r['crimeSUCCESSCRYS']; $ir['exp']+=(int) ($r['crimeSUCCESSMUNY']/8); mysql_query("UPDATE users SET money={$ir['money']}, crystals={$ir['crystals']}, exp={$ir['exp']},crimexp=crimexp+{$r['crimeXP']} WHERE userid=$userid",$c); if($r['crimeSUCCESSITEM']) { item_add($userid, $r['crimeSUCCESSITEM'], 1); } } else { if(rand(1, 2) == 1) { print $r['crimeFTEXT']; } else { print $r['crimeJTEXT']; mysql_query("UPDATE `users` SET `jail` = '$r[crimeJAILTIME]', `jail_reason` = '$r[crimeJREASON]' WHERE `userid` = '$userid'"); } } print " [url='docrime.php?c={$_GET[']Try Again[/url] [url='criminal.php']Crimes[/url]"; } } $h->endpage(); ?> btw this isnt th orginal v1 docrime
  25. i am trying to make v1 when you fail a crime you go to jail but have this error on criminal.php Warning: Invalid argument supplied for foreach() in /home/chav1/public_html/criminal.php on line 37 can someone help me i asked nyna and got no reply so here is the part of the code $q=mysql_query("SELECT * FROM crimegroups ORDER by cgORDER ASC"); print "[b]Criminal Centre[/b] <table width='75%' cellspacing=1 class='table'><tr><th>Crime</th><th>Cost</th><th>Do</th></tr>"; while($r=mysql_fetch_array($q)) { print "<tr><td colspan='3' class='h'>{$r['cgNAME']}</td></tr>"; foreach($crimes as $v); { if($v['crimeGROUP'] == $r['cgID']) { print "<tr><td>{$v['crimeNAME']}</td><td>{$v['crimeBRAVE']} Brave</td><td>[url='docrime.php?c={$v[']Do[/url]</td></tr>"; } } }
×
×
  • Create New...