I got bored so im editing some old modifications
Here's RentASpy for v2
rentaspy.php:
<?php
/*--------------------------------------------------------------
-- RentASpy
-- Compatible: Mono Country Version 2
-- Script Verion: 3.0
-- Made by: Zero-Affect
--------------------------------------------------------------*/
include "globals.php";
// If you want it so anyone can use this modification remove the next 4 lines
$_GET['ID']=abs((int) $_GET['ID']);
$_GET['PAID']=abs((int) $_GET['PAID']);
if(!$ir['donatordays'])
{
echo 'Invalid Command.
Only donators can access this area.
>[url="index.php"]Go Home[/url]';
$h->endpage();
exit;
}
$sql = sprintf('SELECT `level`, `username`, `equip_primary`, `equip_secondary`, `equip_armor`, `money`, `rating`, `bankmoney`, `crimexp`, `crystals` FROM `users` WHERE userid = %u', $_GET['ID']);
$sql = $db->query($sql);
$r=$db->fetch_row($sql);
if($_GET['ID']==$userid)
{
echo 'Invalid Command.
Why would you wanna spy on yourself?
>[url="index.php"]Go Home[/url]';
$h->endpage();
exit;
}
if($_GET['ID'] && $_GET['PAID'])
{
$cost=$r['level']*2000;
if($_GET['PAID']!=$cost)
{
echo 'Invalid Command.
Quit trying to abuse bugs.
>[url="index.php"]Go Home[/url]';
$h->endpage();
exit;
}
if($_GET['PAID']>$ir['money'])
{
echo 'Invalid Command.
You dont have enough money to spy on '.$r['username'].'.
>[url="index.php"]Go Home[/url]';
$h->endpage();
exit;
}
$rand=rand(1,15);
if($rand==1)
{
$ql = sprintf('SELECT `username` FROM users WHERE userid = %u', $userid);
$ql = $db->query($ql);
$n=$db->fetch_row($ql);
$query = sprintf('UPDATE `users` SET money=money-%u WHERE userid = %u', $_GET['PAID'], $userid);
$db->query($query);
print '[b]Your spy has been caught.
Your name may have been mentioned.[/b]';
event_add($_GET['ID'],"[url='viewuser.php?u=$userid']{$n['username']}[/url] tried to rent a spy on you but failed.");
}
else
{
$query = sprintf('UPDATE `users` SET money=money-%u WHERE userid = %u', $_GET['PAID'], $userid);
$db->query($query);
$sta = sprintf('SELECT `strength`, `agility`, `guard`, `labour`, `IQ` FROM userstats WHERE userid = %u', $_GET['ID']);
$sta = $db->query($sta);
$sats=$db->fetch_row($sta);
$we = sprintf('SELECT `itmname` FROM items WHERE itmid = %u', $r['equip_primary']);
$we = $db->query($we);
$pri=$db->fetch_row($we);
$we1 = sprintf('SELECT `itmname` FROM items WHERE itmid = %u', $r['equip_secondary']);
$we1 = $db->query($we1);
$sey=$db->fetch_row($we1);
$we2 = sprintf('SELECT `itmname` FROM items WHERE itmid = %u', $r['equip_armor']);
$we2 = $db->query($we2);
$arm=$db->fetch_row($we2);
if(!$pri['itmname'])
{
$prim="None";
}
else
{
$prim="{$pri['itmname']}";
}
if(!$sey['itmname'])
{
$secon="None";
}
else
{
$secon="{$sey['itmname']}";
}
if(!$arm['itmname'])
{
$arm="None";
}
else
{
$arm="{$arm['itmname']}";
}
if($sats['strength'] > $ir['strength'])
{
$stren="<font color=red>Weaker</font>";
}
elseif($sats['strength'] == $ir['strength'])
{
$stren="<font color=blue>Equal</font>";
}
else
{
$stren="<font color=green>Stronger</font>";
}
if($sats['agility'] > $ir['agility'])
{
$agility="<font color=red>Weaker</font>";
}
elseif($sats['agility'] == $ir['agility'])
{
$agility="<font color=blue>Equal</font>";
}
else
{
$agility="<font color=green>Stronger</font>";
}
if($sats['guard'] > $ir['guard'])
{
$guard="<font color=red>Weaker</font>";
}
elseif($sats['guard'] == $ir['guard'])
{
$guard="<font color=blue>Equal</font>";
}
else
{
$guard="<font color=green>Stronger</font>";
}
if($sats['labour'] > $ir['labour'])
{
$labour="<font color=red>Weaker</font>";
}
elseif($sats['labour'] == $ir['labour'])
{
$labour="<font color=blue>Equal</font>";
}
else
{
$labour="<font color=green>Stronger</font>";
}
if($sats['IQ'] > $ir['IQ'])
{
$IQ="<font color=red>Weaker</font>";
}
else if($sats['IQ'] == $ir['IQ'])
{
$IQ="<font color=blue>Equal</font>";
}
else
{
$IQ="<font color=green>Stronger</font>";
}
$money=number_format($r['money']);
$bmoney=number_format($r['bankmoney']);
echo "<table width='75%' border='1' class='h'>
<tr><th>Primary</th><th>Secondary</th><th>Armor</th></tr>
<tr><td>$prim</td><td>$secon</td><td>$arm</td></tr>
</table>
<table width='75%' border='1' class='h'>
<tr><th>Stats</th> <th>Your Stats</th><th>Compare</th></tr>
<tr><td>Strength: {$sats['strength']}</td><td>Strength: {$ir['strength']}</td><td><center>[b]$stren[/b]</center></td></tr>
<tr><td>Agility: {$sats['agility']}</td><td>Agility: {$ir['agility']}</td><td><center>[b]$agility[/b]</center></td></tr>
<tr><td>Guard: {$sats['guard']}</td><td>Guard: {$ir['guard']}</td><td><center>[b]$guard[/b]</center></td></tr>
<tr><td>Labour: {$sats['labour']}</td><td>Labour: {$ir['labour']}</td><td><center>[b]$labour[/b]</center></td></tr>
<tr><td>IQ: {$sats['IQ']}</td><td>IQ: {$sats['IQ']}</td><td><center>[b]$IQ[/b]</center></td></tr></table>
<table width='75%' border='1'>
<tr><td><center>[url='attack.php?ID={$_GET['][b]Attack?[/b][/url]</center></td></tr>
</table>
<table width='45%' border='1' class='h'>
<tr><th>$$$</th><th>Misc</th></tr>
<tr><td>Money: \${$money}</td><td>Rating: {$r['rating']}</td></tr>
<tr><td>Bank Money: \${$bmoney}</td><td>Crime exp: {$r['crimexp']}</td></tr>
<tr><td>Crystals {$r['crystals']}</td><td>Level: {$r['level']}</td></tr>
</table>
<table width='75%' border='1' class='h'>
<tr><th>Name</th> <th>Ammount</th></tr>";
$z = sprintf('SELECT `inv_itemid`, `inv_qty` FROM inventory WHERE inv_userid = %u ORDER BY inv_itemid DESC', $_GET['ID']);
$z = $db->query($z);
while($e=$db->fetch_row($z))
{
$t = sprintf('SELECT `itmname` FROM items WHERE itmid = %u', $e['inv_itemid']);
$t = $db->query($t);
$itm=$db->fetch_row($t);
print "<tr><td>[b]{$itm['itmname']}[/b]</td><td>[b]{$e['inv_qty']}[/b]</td></tr>";
}
print "</table>
>[url='viewuser.php?u={$_GET[']Back To Profile.[/url]</br>
Created By Zero-Affect";
}
}
else if($_GET['ID'])
{
$cost=$r['level']*2000;
print "[b]You are hiring a spy on {$r['username']}[/b]
It will cost you $$cost for the spys expenses.
But be warned spying is not always 100% successful.
<form action='rentaspy.php' method='get'>
<input type='hidden' name='ID' value='{$_GET['ID']}' />
<input type='hidden' name='PAID' value='$cost' />
<input type='submit' value='Hire Spy'/></form>";
}
$h->endpage();
?>
Open viewuser.php
Find:
}
if($ir['donatordays'] > 0)
{
print "
Add below:
[[url='rentaspy.php?ID={$r[']Rent A Spy[/url]]
Leave Feedback
(EDITED, TESTED AND WORKS)