Register for your free account! | Forgot your password?

Go Back   elitepvpers > Other Online Games > Browsergames > DarkOrbit
You last visited: Today at 23:11

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



Dark Planets Ammo Buy

Discussion on Dark Planets Ammo Buy within the DarkOrbit forum part of the Browsergames category.

Closed Thread
 
Old   #1
 
elite*gold: 0
Join Date: Dec 2012
Posts: 42
Received Thanks: 21
Dark Planets Ammo Buy

How to fix ammo buy ?

Ajax/Shop.php

PHP Code:
<?php
require_once '../KERNEL-DOCMS/Init.php';
if (isset(
$_SESSION['server1']['user']['sessionId'])) {
    if (isset(
$_SESSION['pid']) && isset($_SESSION['uid'])) {
        
$shop->setId($_SESSION['uid'], $_SESSION['pid'], $Users->DataRow['premium']);
        
$base->setId($_SESSION['uid'], $_SESSION['pid'], $Users->DataRow['premium']);
    } else {
        
$Users->checkSession();
        
$_SESSION['pid'] = $Users->DataRow['playerID'];
        
$_SESSION['uid'] = $Users->DataRow['ID'];
        
$shop->setId($_SESSION['uid'], $_SESSION['pid'], $Users->DataRow['premium']);
        
$base->setId($_SESSION['uid'], $_SESSION['pid'], $Users->DataRow['premium']);
    }
    if (isset(
$_POST['action']) && $_POST['action'] == "purchase") {
        
$shop->HangarId();
        if (isset(
$_POST['category']) && $_POST['category'] == "ship") {
            if(
$_POST['itemId']==13):                
                echo 
$shop->ship(70);
            elseif(
$_POST['itemId']==12):
                echo 
$shop->ship(49);
            elseif(
$_POST['itemId']==11):
                echo 
$shop->ship(69);
            else:                
                echo 
$shop->ship($_POST['itemId']);
            endif;
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "weapon"){
            echo 
$shop->guns($_POST['amount'], $_POST['itemId']);
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "battery" OR $_POST['category'] == "rocket"){
            echo 
$shop->battery($_POST['amount'], $_POST['itemId']);
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "pet" OR $_POST['itemId'] == "pet_pet10"){
            echo 
$shop->petPet($_POST['amount'], $_POST['itemId'], $_POST['selectedName']);
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "model"){
            echo 
$shop->model($_POST['amount'], $_POST['itemId']);
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "drone"){
            
$w $base->currentDrones();
            if(
$w>=8){
                    
$shop->money();
                    
$noacc '{"result":"error","message":"You can not buy more than 8 drones","userBalance":{"uridium":'.$shop->uridium.',"credits":'.$shop->credits.'},"userShip":{"laserAmmunitionSpace":3420,"rocketSpace":100},"isShipDumpEmpty":true,"itemId":"","hasPet":"true","category":false}';
                    echo 
$noacc;
            }else{           
                echo 
$shop->drone($_POST['itemId']);
            }
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "generator"){
            echo 
$shop->generator($_POST['amount'], $_POST['itemId']);
        }elseif(isset(
$_POST['category']) && $_POST['category'] == "special"){
            echo 
$shop->special($_POST['amount'], $_POST['itemId']);
        }
//        $data = '{"result":"success","message":"Generator purchased You have free slots in your ship. Do you want to auto-equip them or send them to your inventory?","showEquipOption":true,"userBalance":{"uridium":'.$Users->DataRow['uri'].',"credits":'.$Users->DataRow['credits'].'},"userShip":{"laserAmmunitionSpace":0,"rocketSpace":0},"isShipDumpEmpty":true,"itemId":"equipment_generator_speed_g3n-1010","category":"generator"}';
//        echo $data;
    
} else {
        
$shop->money();
        
$noacc '{"result":"error","message":"No or invalid itemId!","userBalance":{"uridium":'.$shop->uridium.',"credits":'.$shop->credits.'},"userShip":{"laserAmmunitionSpace":3420,"rocketSpace":100},"isShipDumpEmpty":true,"itemId":"","hasPet":"true","category":false}';
        echo 
$noacc;
    }
//    $data2 = '{"result":"error","message":"No or invalid itemId!","userBalance":{"uridium":0,"credits":100500},"userShip":{"laserAmmunitionSpace":3420,"rocketSpace":100},"isShipDumpEmpty":true,"itemId":"","hasPet":"true","category":false}';
//    $data = '{"result":"error","message":"No or invalid itemId!","userBalance":{"uridium":'.$Users->DataRow['uri'].',"credits":'.$Users->DataRow['credits'].'},"userShip":{"laserAmmunitionSpace":0,"rocketSpace":0},"isShipDumpEmpty":false,"userPet":{"level":8,"fuel":43156,"maxFuel":50000},"itemId":"","category":false}';
//      
} else {
    echo 
'eyJpc0Vycm9yIjoxLCAiZXJyb3IiOnsibWVzc2FnZSI6IkVycm9yIn19';
}
?>
alperen417 is offline  
Old 01/07/2015, 17:46   #2
 
AchtungPL1's Avatar
 
elite*gold: 0
Join Date: Dec 2012
Posts: 142
Received Thanks: 10
ahahahah 1 milions funny threads about DarkPlanets

Use your own mind man
AchtungPL1 is offline  
Old 01/07/2015, 19:12   #3
 
manulaiko3.0's Avatar
 
elite*gold: 0
Join Date: May 2014
Posts: 662
Received Thanks: 1,154
You must do this:
manulaiko3.0 is offline  
Thanks
2 Users
Old 01/07/2015, 22:42   #4

 
Arby's Avatar
 
elite*gold: 83
Join Date: May 2011
Posts: 11,029
Received Thanks: 6,036
#closed
Arby is offline  
Closed Thread


Similar Threads Similar Threads
Dark Planets ACP
01/07/2015 - DarkOrbit - 21 Replies
ı need help for ACP ı cant join :mad: View image: ad1 View image: Ads?z2 look at this Bau ,cryz35
[In-Orbit][CMS] Dark Planets edition + emu
01/05/2015 - DarkOrbit - 149 Replies
Hey guys, since the year is almost over and much pserver already have most features, I decided to free some bytes.. I dont explain much, because a coder will know what to do. Most Propz go to bau, cryz35 and yoshii aka the green sucker Requirements: Skill a mid-end server with good b/s
Dark Planets?
11/05/2014 - DarkOrbit - 1 Replies
What happened with dark planets? It going to be back? I really miss it :(
Dark Planets idea
10/22/2014 - DarkOrbit - 38 Replies
Hi all :) Maybe do Dark Planets in Hamachi, i think this is good idea.. Who want, can be connected and server in security.. yes or no?
Dark Planets | Private Server
10/18/2014 - DarkOrbit - 2247 Replies
http://darkorbit.tv/darkplanets/DPMailHeader.jpg Welcome to Dark Planets. Before anything else please read this thread/post through. This is a massive project and we have been working around the clock the last week to even get to this stage in the progress. This is no longer a test and we will try to keep up out system for anyone that wants to play. First and foremost special thanks to my brilliant partner in this project, Bau.



All times are GMT +2. The time now is 23:11.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.