• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Windows [VIP TIME] Functions

crashston3

New Member
Joined
Mar 25, 2011
Messages
18
Reaction score
0
When I add to a vip player in his account looks like this:

Vip Status: VIP Account, 1309137274 Time left

Ai went to look at the script shopsystem.php lines that added the day of VIP and found this:
PHP:
if($player_vip_time > 0)
         $buy_player_account->setCustomField('vip_time', $player_vip_time + $buy_offer['days'] * 86400);
       else
         $buy_player_account->setCustomField('vip_time', time() + $buy_offer['days'] * 86400);
         $account_logged->setCustomField('premium_points', $user_premium_points-$buy_offer['points']);
         $user_premium_points = $user_premium_points - $buy_offer['points'];

Where there has the code $player_vip_time + $buy_offer['days'] * 86400) is the formula of account? Because I could not understand the formula. No way I could not get to 1309137274.

How do I see the value in days ... example:

Vip Status: VIP Account, 30 Days left

Thanks in advance!
 
You need to edit the characters.php where the time is shown on the page not where it is added.
It probably just shows the unix timestamp and not the days.
 
You need to edit the characters.php where the time is shown on the page not where it is added.
It probably just shows the unix timestamp and not the days.

I took a look at "characters.php"and I think that is not there that has to change. I wish that when I bought "vip" the site was added in "days" in the database and not that huge number that should be in seconds. You or someone here would know the forum help me.

I am grateful!
 
The time is in seconds....
1 day = 86400 seconds... xDDD
Dude, I know that.

What I need is to know how to put this value in days in the database
and also discounted these days is the right way. That is, discount in days and not seconds.

Someone to help me?
 
Back
Top