
Mike09
Members-
Posts
129 -
Joined
-
Last visited
Never
Content Type
Profiles
Forums
Events
Everything posted by Mike09
-
Re: [V2]Basic Assassination. i have the same amount as you do.. Does that mean you rip mods off? No it doesn't
-
Re: [V2]Basic Assassination. yes strats it is.. @BadGirl grow up and stop pretending to be a girl Alan :]
-
Save the following as "assassin.php" <?php include "globals.php"; if($ir['hospital'] >0 || $ir['jail'] >0) { echo 'You cant access here whilst in jail or hospital'; $h->endpage(); exit; } switch($_GET['action']) { case 'step1': step1(); break; default: index(); break; } function index() { global $ir,$c,$userid,$db; print "<h3>Assassinate a user</h3> [b]<center>Select the user you wish to assassinate. The price for the assassination is \$1000 times the users level.[/b] <form action='assassin.php?action=step1' method='post'> User: ".user_dropdown($c,'user')." <input type='submit' value='Assassinate' /></form></center>"; } function step1() { global $ir,$c,$userid,$db; $a=$db->query("SELECT userid, username, level FROM users WHERE userid={$_POST['user']}"); $assas=$db->fetch_row($a); $cost=$assas['level'] * 1000; if($ir['userid'] == $assas['userid']) { echo 'why are you trying to kill your self?'; $h->endpage(); exit; } if($ir['money'] <$cost) { print "You need \$$cost to assassinate {$assas['username']}"; exit; } $hosp=mt_rand(52,103); $db->query("UPDATE users SET hospital=$hosp,hospreason='Assassinated by <a href=viewuser.php?u={$ir['userid']}>{$ir['username']}</a>' WHERE userid='{$assas['userid']}'"); event_add($assas['userid'],"You was assassinated by [url='viewuser.php?u={$ir[']{$ir['username']}[/url]."); $db->query("UPDATE users SET money=money-$cost WHERE userid='{$ir['userid']}'"); print "You paid \$$cost for your assassin to kill {$assas['username']}"; } ?> Add link in explore: [url='assassin.php']Hire a killer[/url]
-
Re: problem creating new shops show the structure for the shops table..
-
Re: Thank a CE mccode Mod Developer Day I would like to thank a few people... Haunted Dawg- Has helped me quite a bit so thank you and your mods rock :) Karlos- He's like my online brother :) Thank you for making those awesome mods. Magictallguy- For forgiving me for my past and for being you plus your mods are amazing :) Zero-Affect- Some of you may know that my self and zero have a major history so some of you may be going "What the hell" right now xD But the reason i want to thank him is because he gave me the determination to attempt to prove him wrong and that i wouldn't fall at the first hurdle. Although i have still not proved this but if it wasn't for zero i would of left PHP along time ago his remarks about me being a noob and would never succeed made me continue :) All the people above deserve to be thanked they are good developers some of them are great friends and people. Although zero i still dont get on with i just thought he deserved credit.
-
Re: Template Make one? Or look in the paid modification board for paid templates and unique offers.
-
Re: [mccodes V2] Review staff. Thanks zero and MYGUNWARS im still learning so every tip helps.
-
Re: [mccodes V2] Review staff. Here is the fixed and secured version thanks to MTG. <?php include(DIRNAME(__FILE__) . '/globals.php'); $_GET['review'] = abs(@intval($_GET['review'])); if(!$_GET['review']) { echo "Invalid use of file"; $h->endpage(); exit; } $sql = sprintf( "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 gangs g ON (u.gang = g.gangID) " . "LEFT JOIN fedjail f ON (u.userid = f.fed_userid) " . "WHERE (u.userid = %u)", $_GET['review']); $q = $db->query($sql); if(!$db->num_rows($q)) { echo "You cannot review someone who does not exist."; $h->endpage(); exit; } $r = $db->fetch_row($q); if($r['user_level'] == 1) { echo "This user is not staff!"; $h->endpage(); exit; } if(!$ir['review']) { echo "You may only review once a day"; $h->endpage(); exit; } if($ir['daysold'] < 3) { echo "You may not post a review as you are less than 3 days old."; $h->endpage(); exit; } echo sprintf("<h3>Reviewing %s</h3>", stripslashes($r['username'])); echo "Below you may submit a review about a member of staff. Use the drop down menu to give a review of 1 or 9, 1 being the lowest and 9 being the highest. then explain the reason for your low or high review. This is to help pick decent staff and monitor there behaviour. "; $_POST['reason'] = mysql_real_escape_string(htmlspecialchars($_POST['reason'])); $_POST['rating'] = abs(@intval($_POST['rating'])); $sql1 = sprintf("INSERT INTO review VALUES ('', %u, %u, '%s', unix_timestamp())", $_GET['review'], $_POST['rating'], $_POST['reason']); $sql2 = sprintf("UPDATE users SET rating = 0 WHERE (userid = %u)", $userid); $db->query($sql1); $db->query($sql2); echo "[b]You have reviewed this staff member[/b] "; echo sprintf("<form action='review.php?review=%u' method='post'>", $r['userid']); echo " Reason: <textarea rows='7' cols='50' name='reason'></textarea> "; echo "Rate: <select name='rating' type='dropdown'>"; for($i = 1; $i < 10; ++$i) { echo sprintf("<option value='%u'>%u</option>", $i, $i); } echo "</select>"; echo "<input type='submit' name='review' value='Review' />"; echo "</form>"; } $h->endpage(); ?> <?php include(DIRNAME(__FILE__) . '/sglobals.php'); if ($ir['user_level'] != 2) echo "Only admins can view this"; $h->endpage(); exit; } $_GET['action'] = isset($_GET['action']) && ctype_alpha($_GET['action']) ? strtolower(trim($_GET['action'])) : false; switch($_GET['action']) { case 'index': index(); break; case 'clear': clear(); break; default: index(); break; } function index() { global $db, $ir, $h; echo "[url='staff_review.php?action=clear']Delete all[/url] "; echo "<table cellspacing='1' class='table' width='90%'>"; echo "<tr>"; echo "<th>Userid</th>"; echo "<th>Review</th>"; echo "<th>Reason</th>"; echo "<th>Time</th>"; echo "</tr>"; $sql = "SELECT r.*, u.username " . "FROM review r " . "LEFT JOIN users u ON (r.user = u.userid)"; $q1 = $db->query($sql); while($r = $db->fetch_row($q1)) { echo "<tr>"; echo sprintf("<td>[url='viewuser.php?u=%u']%s[/url] [%s]</td>", $r['user'], stripslashes($r['username']), number_format($r['user'])); echo sprintf("<td>%u</td>", $r['review']); echo sprintf("<td>%s</td>", stripslashes(nl2br($r['reason']))); echo sprintf("<td>%s</td>", date('F j Y g:i:s a', $r['time'])); echo "</tr>"; } echo "</table>"; } function clear() { global $db; $db->query("TRUNCATE review"); echo "Cleared!"; } $h->endpage(); ?>
-
Re: [mccodes V2] Review staff. Yeah i took the select * from the viewuser :| lol i should of just done it my self my bad :| and thanks zero :)
-
Re: [mccodes V2] Review staff. Sorry the SQL is CREATE TABLE IF NOT EXISTS `warnings` ( `id` int(11) NOT NULL auto_increment, `user` int (11) NOT NULL default '0', `warning` varchar(266) NOT NULL default 'none', `reason` varchar(266) NOT NULL default 'None', `time` int(11) NOT NULL default '0', PRIMARY KEY (`id`) )
-
Run this SQL CREATE TABLE IF NOT EXISTS `review` ( `id` int(11) NOT NULL auto_increment, `user` int (11) NOT NULL default 0 `review` int(11) NOT NULL default '1', `reason` varchar(266) NOT NULL default 'None', `time` int(11) NOT NULL default '0', PRIMARY KEY (`id`) ) Now create a file called review.php and put this inside <?php //Made by Yubi\\ include "globals.php"; $_GET['review'] = abs((int) $_GET['review']); if(!$_GET['review']) { print "Invalid use of file"; } else { $q=$db->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 gangs g ON g.gangID=u.gang LEFT JOIN fedjail f ON f.fed_userid=u.userid WHERE u.userid={$_GET['review']}"); if($db->num_rows($q) == 0) { print "You cannot review someone who does not exist."; } else { $r=$db->fetch_row($q); If($r['user_level'] == 1) { Echo 'This user is not staff!'; $h->endpage(); } if ($ir['review']==0) { echo 'You may only review once a day'; $h->endpage(); exit; } if($ir['daysold'] <3) { echo 'You may not post a review as you are less than 3 days old.'; $h->endpage(); exit; } print "<h3>Reviewing {$r['username']}</h3> Below you may submit a review about a member of staff. Use the drop down menu to give a review of 1 or 9, 1 being the lowest and 9 being the highest. then explain the reason for your low or high review. This is to help pick decent staff and monitor there behaviour. "; if(isset($_POST['review'])) { $_POST['reason'] = mysql_real_escape_string(htmlspecialchars($_POST['reason'])); $db->query("INSERT INTO review VALUES ('','{$_GET['review']}','".abs(@intval($_POST['rating']))."','{$_POST['reason']}',unix_timestamp())"); $db->query("UPDATE users SET review=0"); } print "[b]You have reviewed this staff member[/b] "; echo '<form action="review.php?review='.$r['userid'].'" method="post">'; print " Reason: <textarea rows='7' cols='50' name='reason'></textarea> "; print 'Rate:<select name="rating">'; for($i = 1; $i < 10; ++$i) { echo ' <option value="'.$i.'">'.$i.'</option>'; } print "<input type='submit' name='review' value='Review' /></form>"; } } $h->endpage(); ?> Now open stafflist.php and find all the <th>Status</th> Replace with <th>Status</th> <th>Review</th> Now find all the <td>$on</td> replace with <td>$on</td><td>[url='review.php?review={$r[']Review[/url]</td> In cron_day.php add $db->query("UPDATE users SET review=1"); Now create a file called staff_review.php and put this inside <?php include 'sglobals.php'; switch($_GET['action']) { case 'index': index(); break; case 'clear': clear(); break; default: case 'index': index(); break; } function index() { global $db,$ir, $c; if ($ir['user_level'] !=2) echo 'Only admins can view this'; $h->endpage(); exit; } print "[url='staff_review.php?action=clear']Delete all[/url] <table cellspacing=1 class='table' width=90%><tr><th>Userid </th><th> Review</th><th>Reason</th><th>Time</th></tr>"; $test = $db->query('SELECT * FROM `review`'); while($r=$db->fetch_row($ql)) { print "<tr><td>{$r['user']}</td><td>{$r['review']}</td><td>{$r['reason']}</td><td>".date('F j Y g:i:s a', $r['time'])."</td>"; } } function clear() { global $db,$ir, $c; if ($ir['user_level'] !=2) echo 'Only admins can view this'; $h->endpage(); exit; } $db->query("TRUNCATE review"); Print "Cleared!"; } $h->endpage(); ?> in smenu.php add somewhere in the user section [url='staff_review']View reviews[/url] and DONE! any issues post below.
-
Re: [mccode v2] Advanced Turns [$15.00] $5 is peanuts :roll:
-
mccode-v2 100% Working Copy Enhanced Schooling
Mike09 replied to Uridium's topic in Free Modifications
Re: [MCCODES V2] 100% Working Copy Enhanced Schooling I have seen a few of your modifications. They are all coded will and I have to say You amaze me! This should definitely be a paid mod! Keep up the good work Illusions. +1 -
Re: [mccode v2] Advanced Turns [$15.00] If thats not included im sure it wouldn't be hard to add if not why dont you give him $5 extra to add it or something :-P
-
Re: Ravan Game Engine They are good to start off i agree but most people dont edit or secure there games and then bitch about getting hacked..
-
Re: Ravan Game Engine Are you being serious?
-
Re: [mccode v2] Monorail Recode Nice modification +1
-
Re: 3 Word Game a dog with
-
Re: 3 Word Game 3 months later
-
Re: 3 Word Game a virgin got
-
Re: [v2]Ctemple That is because i am updating mine he is going off what he has saw from the print shots. Before i started to update this it was 117 lines long.
-
Re: [v2]Ctemple Mine is 327 lines long and being updated as i type this.. All previous buyers will receive the free upgrade just send me your support ticket that i gave you.
-
Re: [v2]Ctemple There are two, No offence but i have also seen a few of your mods and most of them are exploitable or bugged so i wouldn't climb on your high horse mate. Back on topic 6 copies remaining
-
Re: [v2]Ctemple Actually that query would allow the user to gain donator days for free and not lose any crystals if you are going to challenge me atleast get it right.. Most of the modifications on here are easy to make but people buy updates like these because either 1) They cant programme 2) They cannot be bothered 3) they have money to throw away.. Anyway 8 Copies left.
-
Re: [v2]Ctemple 9 Copies remaining.