This might be very noobish as i am new here,i edited the donator daily reward, so some stuff might look similar but here it is anyways:
First Create a new shop using the staff panel then go to the shop in game and find the ID link to that shop just created.
it should look a little something like this:
http://example.exofire.net/shops.php?shop=1 (found on address bar once in the shop)
Create a file called ddshop.php and put in the following text:
<?php
/*-----------------------------------------------------
Edited By Evolution AKA RiseAK47
-----------------------------------------------------*/
require "globals.php";
if($ir['jail']) { die("<h2>Your in Jail!</h2>Come back in {$ir['jail']} Minutes!"); }
if($ir['hospital']) { die("<h2>Your in Hospital</h2>Come back in {$ir['hospital']} Minutes!"); }
if($ir['donatordays'] == 0)
{
die("Sorry, This Feature is for Donators only!");
}
print "<center><table width=80% class=h border=1><tr><th>Donator Shop</th></tr><tr>
<td>
<center><hr width='70%'>This Feature is only For Donators,
Welcome To The Daily Donator Shop,
Please Take Your Time And You Can Use This When You Like!<hr width='70%'>
";
if($_GET['reward'])
{
if($ir['reward_done'] >= 1)
{
die("<font color=red>Sorry, You Have already shopped here today its closed, Come Back Tomorrow!</font>
</td></tr></th></table><table width=80% class=h border=1><tr><th>[url='ddreward.php']- Go Back -[/url]</th></tr></td></th>
</table>");
}
$num=rand(1, 5);
$db->query("UPDATE users SET reward_done=reward_done+1 WHERE userid=$userid");
$ir['money']-=100;
switch($num)
{
case 1:
$money=rand(30, 1200);
print "<font color=green>You Have Been Rewarded Money!</font>";
$db->query("UPDATE users SET money=money+{$money} WHERE userid={$userid}");
break;
case 2:
print "<font color=green>You Gained Some Brave!</font>";
$db->query("UPDATE users SET brave=maxbrave WHERE userid={$userid}");
break;
case 3:
print "<font color=green>You Gained Some Will!</font>";
$db->query("UPDATE users SET will=maxwill WHERE userid={$userid}");
break;
case 4:
print "<font color=green>You Gained Some Energy!</font>";
$db->query("UPDATE users SET energy=+5 WHERE userid={$userid}");
break;
case 5:
print "<font color=green>You Gained 10 Crystals!</font>";
$db->query("UPDATE users SET crystals=+10 WHERE userid={$userid}");
break;
}
print "
<a href='test.php'><font color=black>- back -</font>
";
}
else
{
print "
</td></tr></th></table><table width=80% class=h border=1><tr><th>[url='http://example.exofire.net/shops.php?shop=1?shop=9?reward=1']<font color=green>- Enter Here -</font>[/url]</th></tr></td></th>
</table>
<table width=80% class=h border=1><tr><th>[url='index.php']- Go To Home -[/url]</th></tr></td></th></table>
";
}
$h->endpage();
?>
Then Open Mainmenu.php And look for this code:
if($ir['donatordays'])
{
print "<hr />
[b]Donators Only[/b]
Replace with this:
if($ir['donatordays'])
{
print "<hr />
[b]Donators Only[/b]
[url='ddshop.php']Daily Donator Shop[/url]
Once This is Done Edit ddshop.php
Find This Text:
print "
</td></tr></th></table><table width=80% class=h border=1><tr><th><a
href='http://example.exofire.net/shops.php?shop=1?reward=1'><font color=green>- Enter Here
-</font></a></th></tr></td></th>
</table>
Replace This Bit With Your own Link to your shop witch your created from the start (Shop ID)
[url]http://example.exofire.net/shops.php?shop=1[/url]
Run This SQL:
ALTER TABLE `users` ADD `reward_done` int(11) NOT NULL default '0';
Open Cron_day.php and find:
$db->query("UPDATE users SET daysold=daysold+1, boxes_opened=0");
Add After
$db->query("UPDATE users SET reward_done=0");
DONE!
add special items to your shop for donators only! using staff panel
Any Problems Please Post but im sure there wont be. :mrgreen:
Please No Harsh comments this is my first time posting here :wink:
Its been tested and works