Jump to content
MakeWebGames

illegalife

Members
  • Posts

    159
  • Joined

  • Last visited

Everything posted by illegalife

  1. Re: [mccode v2] Building [$20.00] so every building you have adds up to your daily income... and you can build those 10 buildings on just one of the places you clicked on the map, or you can just choose some other place and build more buildings there and 10 more on some other place etc?
  2. Re: [mccode v2] Building [$20.00] does every user see the map and if someone has a building everyone sees it? or is it just a mod for every user personally?
  3. Re: [mccode v2] Numbers Game   i have the same problem
  4. Re: *special* McCodes v3 BETA Release i dont think you can legally distribute that ... i mean people paid $300 for v2 and you're giving away ur "V2.9" away, seems unfair for those who purchased the codes.
  5. Re: [mccode] Updated friends, black list & preferences Ok can anyone help me so the friends start on a new line if there's 4 friends on a line allready... here's what i have right now: Here's the code <?php include "globals.php"; if($ir['donatordays'] == 0) { die("This feature is for donators only."); } print "<h3>Friends List</h3>"; switch($_GET['action']) { case "add": add_friend(); break; case "remove": remove_friend(); break; case "ccomment": change_comment(); break; default: friends_list(); break; } function friends_list() { global $db,$db,$ir,$c,$userid; print"<style type='text/css'> .table { FONT-SIZE: small; FONT-FAMILY:sans-serif; background: transparent;} .table TD { border:1px solid black; FONT-SIZE: small; FONT-FAMILY: sans-serif; filter:alpha(opacity=90); -moz-opacity:.90; opacity:.90;} .tr { FONT-SIZE: small; FONT-FAMILY:sans-serif; background: transparent;} .table TR { border:1px solid black; FONT-SIZE: small; FONT-FAMILY: sans-serif; filter:alpha(opacity=75); -moz-opacity:.75; opacity:.75;} </style> [url='friendslist.php?action=add']<font color=green>[b]<u>Add a Friend[/b]</u></font>[/url] These are the people on your friends list. "; $q_y=$db->query("SELECT * FROM friendslist WHERE fl_ADDED=$userid",$c); print $db->num_rows($q_y)." people have added you to their list. Most liked: ["; $q2r=$db->query("SELECT u.username,count( * ) as cnt,fl.fl_ADDED FROM friendslist fl LEFT JOIN users u on fl.fl_ADDED=u.userid GROUP BY fl.fl_ADDED ORDER BY cnt DESC LIMIT 5",$c) or die(mysql_error()); $r=0; while($r2r=mysql_fetch_array($q2r)) { $r++; if($r > 1) { print " | "; } print "[url='viewuser.php?u={$r2r[']{$r2r['username']}[/url]"; } print "] "; print"<table width=25% class='table' cellspacing='3'><tr>"; $q=$db->query("SELECT fl.*,u.* FROM friendslist fl LEFT JOIN users u ON fl.fl_ADDED=u.userid WHERE fl.fl_ADDER=$userid ORDER BY u.username ASC",$c); while($r=mysql_fetch_array($q)) { if($r['laston'] >= time()-15*60) { $on="<font color=green>[b]Online[/b]</font>"; } else { $on="<font color=red>[b]Offline[/b]</font>"; } $d=""; if($r['donatordays']) { $r['username'] = "<font color=red>{$r['username']}</font>";$d="[img=donator.gif]"; } if(!$r['fl_COMMENT']) { $r['fl_COMMENT']="N/A"; } print "<td>$on <a href='viewuser.php?u={$r['userid']}'>"; if($r['display_pic']) { print "[img={$r[]"; } else { print "[img=pic.jpg]"; } print " {$r['username']} $d [{$r['userid']}]</a> [url='friendslist.php?action=ccomment&f={$r[']Change Comment[/url]$fc [url='friendslist.php?action=remove&f={$r['][img=remove.gif]Remove[/url]</td> "; } } function add_friend() { global $db,$ir,$c,$userid; $_POST['ID'] = abs((int) $_POST['ID']); $_POST['comment']=str_replace(array("<",">","\n"),array("<",">"," "), $_POST['comment']); if($_POST['ID']) { $qc=$db->query("SELECT * FROM friendslist WHERE fl_ADDER=$userid AND fl_ADDED={$_POST['ID']}"); $q=$db->query("SELECT * FROM users WHERE userid={$_POST['ID']}"); if($db->num_rows($qc)) { print "You cannot add the same person twice."; } else if($userid==$_POST['ID']) { print "You cannot be so lonely that you have to try and add yourself."; } else if($db->num_rows($q)==0) { print "Oh no, you're trying to add a ghost."; } else { $db->query("INSERT INTO friendslist VALUES('', $userid, {$_POST['ID']}, '{$_POST['comment']}')"); $r=$db->fetch_row($q); $db->query("UPDATE users SET friend_count=friend_count+1 WHERE userid={$_POST['ID']}"); print "{$r['username']} was added to your friends list. [url='friendslist.php']> Back[/url]"; } } else { print "Adding a friend!<form action='friendslist.php?action=add' method='post'> Friend's ID: <input type='text' name='ID' value='{$_GET['ID']}' /> Comment (optional): <textarea name='comment' rows='7' cols='40'></textarea> <input type='submit' value='Add Friend' /></form>"; } } function remove_friend() { global $db,$ir,$c,$userid; $q=$db->query("SELECT * FROM friendslist WHERE fl_ID={$_GET['f']} AND fl_ADDER=$userid"); if($db->num_rows($q) == 0) { die("Cannot remove a nonexistant entry."); } $r=$db->fetch_row($q); $db->query("DELETE FROM friendslist WHERE fl_ID={$_GET['f']} AND fl_ADDER=$userid"); $db->query("UPDATE users SET friend_count=friend_count-1 WHERE userid={$r['fl_ADDED']}"); print "Friends list entry removed! [url='friendslist.php']> Back[/url]"; } function change_comment() { global $db,$ir,$c,$userid; $_POST['f'] = abs((int) $_POST['f']); $_POST['comment']=str_replace(array("<",">","\n"),array("<",">"," "), $_POST['comment']); if($_POST['comment']) { $db->query("UPDATE friendslist SET fl_COMMENT='{$_POST['comment']}' WHERE fl_ID={$_POST['f']} AND fl_ADDER=$userid"); print "Comment for friend changed! [url='friendslist.php']> Back[/url]"; } else { $_GET['f'] = abs((int) $_GET['f']); $q=$db->query("SELECT * FROM friendslist WHERE fl_ID={$_GET['f']} AND fl_ADDER=$userid"); if($db->num_rows($q)) { $r=$db->fetch_row($q); $comment=str_replace(array("<",">"," "), array("<",">","\n"), $r['fl_COMMENT']); print "Changing a comment.<form action='friendslist.php?action=ccomment' method='post'> <input type='hidden' name='f' value='{$_GET['f']}' /> Comment: <textarea rows='7' cols='40' name='comment'>$comment</textarea> <input type='submit' value='Change Comment' /></form>"; } else { print "Stop trying to edit comments that aren't yours."; } } } print"</table>"; $h->endpage(); ?>
  6. Re: [mccode v2] Display Cabinet can anyone fix this ^^^^^^^^^^^^^^
  7. Re: [v2] Will pay for a fix... ok got someone to help me out so its fixed now
  8. I have a custom layout which looks perfect in Mozilla Firefox, but looks messed up in Internet Explorer. I tried everything now and im hoping that someone could fix it for a small price. Mozilla Firefox Screen Shot: http://i42.tinypic.com/5n944z.png Internet Explorer Screen Shot: http://i42.tinypic.com/11rwsbm.png Mail Me ASAP.
  9. Re: [mccodes V2] Free Game Template simple and neat
  10. Re: [mccode v2] Display Cabinet if you just paste this with any item id in the game it will add it to the display even if you dont have it in ur inventory :( displayadd.php?ID=$userid&action=addit&itm=ITEMID
  11. Re: Hospital/Jail Count stuck Hospital <?php include "globals.php"; print "[img=hosp.gif] <table width='75%' class=\"table\" border=\"0\" cellspacing=\"1\"><tr bgcolor=gray><th>Name</th> <th>Level</th> <th>Time</th><th>Reason</th></tr>"; $q=$db->query("SELECT u.*,c.* FROM users u LEFT JOIN gangs c ON u.gang=c.gangID WHERE u.hospital > 0 ORDER BY u.hospital DESC",$c); while($r=$db->fetch_row($q)) { print "\n<tr><td>{$r['gangPREFIX']} [url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td><td align=center> {$r['level']}</td><td align=center>{$r['hospital']} minutes</td><td>{$r['hospreason']}</td></tr>"; } print "</table>"; $h->endpage(); ?>   Jail <?php include "globals.php"; echo "[img=jail.gif]"; if($ir['jail']) { echo " [url='addoffer.php']> Make Bust Offer[/url] "; } echo " <table width='85%' class=\"table\" border=\"0\" cellspacing=\"1\"><th>Name</th> <th>Level</th> <th>Time</th><th>Reason</th> <th> Bust Offer</th> <th>Actions</th></tr>"; $q=$db->query("SELECT u.*,c.* FROM users u LEFT JOIN gangs c ON u.gang=c.gangID WHERE u.jail > 0 ORDER BY u.jail DESC"); while($r=$db->fetch_row($q)) { print "\n<tr><td background=images/th.png>{$r['gangPREFIX']} [url='viewuser.php?u={$r[']{$r['username']}[/url] [{$r['userid']}]</td><td align=center>{$r['level']}</td><td align=center>{$r['jail']} minutes</td><td>{$r['jail_reason']}</td><td>\$".number_format($r['jail_offer'])."</td><td align=center background=images/thgreen.png>[url='jailbust.php?ID={$r['][i][b]<font color='green'>Bust[/b][/i]</font>[/url]</td></tr>"; } print "</table> "; if($ir['jail'] || $ir['user_level']==2) {include_once("jailshout.php");} print" "; $h->endpage(); ?>   <?php global $db,$c,$ir, $set; $hc=$set['hospital_count']; $jc=$set['jail_count']; $ec=$ir['new_events']; $mc=$ir['new_mail']; $zerko=0; if($ir['hospital']) { print "[url='hospital.php']Hospital ($hc)[/url] [url='inventory.php']Inventory[/url] "; } elseif($ir['jail']) { print "[url='jail.php']Jail ($jc)[/url] "; } else { print "[url='index.php']Home[/url] [url='inventory.php']Items[/url] "; } if($ec > 0) { print "[url='events.php']Events ($ec)[/url] "; } else { print "[url='events.php']Events (0)[/url] "; } if($mc > 0) { print "[url='mailbox.php']Mailbox ($mc)[/url] "; } else { print "[url='mailbox.php']Mailbox (0)[/url] "; } if($ir['jail'] and !$ir['hospital']) { print "[url='gym.php']Jail Gym[/url] [url='hospital.php']Hospital ($hc)[/url] "; } else if (!$ir['hospital'] && (!$ir['drunktank'] > $zerko)) { print "[url='explore.php']City[/url] [url='gym.php']Gym[/url] [url='criminal.php']Crimes[/url] [url='job.php']Your Job[/url] [url='bar.php']Bar[/url] [url='education.php']Education[/url] [url='hospital.php']Hospital ($hc)[/url] [url='jail.php']Jail ($jc)[/url] "; } else { print "[url='jail.php']Jail ($jc)[/url] "; } print "[url='forums.php']Forums[/url] "; if($ir['new_announcements']) { print "[url='announcements.php']News ({$ir['new_announcements']})[/url] "; } else { print "[url='announcements.php']News (0)[/url] "; } print " [url='halloffame.php']Hall of Fame[/url] [url='search.php']Search[/url] "; if(!$ir['jail'] && $ir['gang']) { print "[url='yourgang.php']Your Gang[/url] "; } if($ir['user_level'] > 1) { print "<hr /> [url='staff.php']Staff Panel[/url] \n"; print "<hr />[b]Staff Online:[/b] "; $q=$db->query("SELECT * FROM users WHERE laston>(unix_timestamp()-15*60) AND user_level>1 ORDER BY userid ASC"); while($r=$db->fetch_row($q)) { $la=time()-$r['laston']; $unit="secs"; if($la >= 60) { $la=(int) ($la/60); $unit="mins"; } if($la >= 60) { $la=(int) ($la/60); $unit="hours"; if($la >= 24) { $la=(int) ($la/24); $unit="days"; } } print "[url='viewuser.php?u={$r[']{$r['username']}[/url] ($la $unit) "; } } if($ir['donatordays']) { print "<hr /> [b]Donators Only[/b] [url='cgym.php']Point Gym[/url] [url='friendslist.php']Friends List[/url] [url='blacklist.php']Black List[/url]"; } print "<hr /> [url='preferences.php']Preferences[/url] [url='preport.php']Player Report[/url] [url='helptutorial.php']Help Tutorial[/url] [url='gamerules.php']Game Rules[/url] [url='viewuser.php?u={$ir[']My Profile[/url] [url='logout.php']Logout[/url] Time is now "; echo date ('F j, Y')." ".date('g:i:s a'); ?>
  12. Re: [Mccodes V1 & V2] Updated friends, black list & preferences woulld i be able to do it like that so it would be like 2 or 3 columns not all in one column?
  13. Re: [Mccodes V1 & V2] Updated friends, black list & preferences The preferences download link doesnt work :(
  14. the hospital and jail counters are stuck it's always Hospital (2) Jail(0) even if there's different amount of people in them. anyone know how to fix this or at least well should i look to fix this please?
  15. Fatal error: Call to a member function query() on a non-object in /home/illegal/public_html/forums.php on line 703   LINE 703 $q=$db->query("SELECT * FROM forum_topics WHERE ft_id={$_GET['topic']}");   $topic=$db->fetch_row($q); $db->query("DELETE FROM forum_topics WHERE ft_id={$_GET['topic']}"); $db->query("DELETE FROM forum_posts WHERE fp_topic_id={$_GET['topic']}"); print "Deleting topic... Done "; recache_forum($topic['ft_forum_id']); stafflog_add("Deleted topic {$topic['ft_name']}"); } $h->endpage(); ?>
  16. Re: [V2] Inventory Item (x2)   so how do use them ?
  17. Re: [v2] NPC item reward doesn't work ;/
  18. Anyone can help me with making an NPC that gives out an item when he's beaten instead of money? Here's my failed attempt:   $npcs=array( ); if($r['user_level']==0) { $q=$db->query("SELECT * FROM challengebots WHERE cb_npcid={$r['userid']}"); if ($db->num_rows($q)) { $cb=$db->fetch_row($q); $qk=$db->query("SELECT * FROM challengesbeaten WHERE userid=$userid AND npcid={$r['userid']}"); if(!$db->num_rows($qk)) { $m=$cb['cb_money']; $db->query("UPDATE users SET money=money+$m WHERE userid=$userid"); print " You gained \$$m for beating the challenge bot {$r['username']}"; $db->query("INSERT INTO challengesbeaten VALUES($userid, {$r['userid']})"); } else { if ($r['userid']==80) print"You beat the Evil Santa and steal his Santa's Rifle."; $db->query("INSERT INTO inventory VALUES('',32,$userid,1)"); $db->query("INSERT INTO challengesbeaten VALUES($userid, {$r['userid']})"); } } } else { print "You beat Mr. non-existant!"; } } $h->endpage(); ?>
  19. Re: [MOD] V2 Drag n Drop User and Admin System... great mod are you going to release it?
  20. I want the query to give exactly 10% of energy but this is not right $db->query("UPDATE users SET energy=energy+10 WHERE userid=$userid"); $db->query("UPDATE users SET energy=maxenergy WHERE energy > maxenergy"); What do i do so it is the percent not the value?
  21. Re: Internet Explorer Hmm okay it's really hard for me to actually understand the website standards but thanks anyway, about the securing will bbcode in profile signatures help ?
  22. Re: Internet Explorer   hmm do i put that before the <?php   because i did and it didnt solve the problem
  23. Re: Internet Explorer   can i get some advice on how to secure it?
  24. Re: Internet Explorer thanks for the help though i read the page but i still couldnt figure it out :(
  25. Re: [mccode] jail/hosp shoutbox can anyone tell me what i do to like limit the height of the shoutbox so once its like more then 300px height and the scroll bar appears instead of it going longer?
×
×
  • Create New...