Register for your free account! | Forgot your password?

Go Back   elitepvpers > Other Online Games > Browsergames > DarkOrbit
You last visited: Today at 05:21

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

Advertisement



Private Server Info and Support Thread

Discussion on Private Server Info and Support Thread within the DarkOrbit forum part of the Browsergames category.

Reply
 
Old 11/19/2014, 03:27   #1186
 
YURI-ELIADE.ITALY's Avatar
 
elite*gold: 15
Join Date: Feb 2014
Posts: 313
Received Thanks: 78
please can anyone help me with the iris database aurora

YURI-ELIADE.ITALY is offline  
Old 11/20/2014, 00:55   #1187
 
elite*gold: 0
Join Date: Nov 2013
Posts: 60
Received Thanks: 4
how can i add pet window in game?
king[amg]ua is offline  
Old 11/20/2014, 07:36   #1188
 
elite*gold: 0
Join Date: Sep 2014
Posts: 148
Received Thanks: 73
Hi, any have a packet for power on the lights of ship police? xD

lCulito is offline  
Old 11/20/2014, 09:22   #1189
 
manulaiko3.0's Avatar
 
elite*gold: 0
Join Date: May 2014
Posts: 663
Received Thanks: 1,154
Quote:
Originally Posted by lCulito View Post
Hi, any have a packet for power on the lights of ship police? xD

There's no packet for that, lights are automatics, if you can't see the lights try to replace ship's swf
manulaiko3.0 is offline  
Thanks
1 User
Old 11/20/2014, 23:25   #1190
 
YURI-ELIADE.ITALY's Avatar
 
elite*gold: 15
Join Date: Feb 2014
Posts: 313
Received Thanks: 78
someone can tell me how you bring rewards to aliens?
YURI-ELIADE.ITALY is offline  
Old 11/21/2014, 00:37   #1191
 
UND3RW0RLD's Avatar
 
elite*gold: 1
Join Date: Jun 2011
Posts: 1,464
Received Thanks: 1,065
on event "npc dead" do some query or poll the data for intervals (every 20 seconds one query instead of 1000 single request to DB). then send packet for the ingame-log. Tada

_____________________

Some time ago I worked on a skylab-class. But I only made the visual stuff.

what do you have:
- all bp-like data (ress per hour, storage, everything)
- you can upgrade moduls
- energy consumption works for 50% (autodisabling moduls not work)
- you will see in the codebox

to-do:
- decrease ressources on upgrade
- transports
- robots
- insta-finish

maybe someone finishes it, and if someone did it I want link.
PHP Code:
<?php
class Skylab
{
    
// basic stuff
    
private $con;
    private 
$uid;
    
    
// player table
    
private $uridium;
    private 
$credits;

    
// skylab_ressources table
    
private $ressources_array;
    
    
// skylab table
    
private $mod_basic;
    private 
$mod_store;
    private 
$mod_solar;
    private 
$collector_prometium;
    private 
$collector_endurium;
    private 
$collector_terbium;
    private 
$refine_prometid;
    private 
$refine_duranium;
    private 
$refine_promerium;
    private 
$refine_seprom;
    private 
$generator_xeno;
    
    public 
$output;
    
    
// generated data
    
public $site_data;


    
    public function 
__construct() {
        
$this->con =  $GLOBALS['DB'];

    }
    
    public function 
getSiteData(){
        return 
$this->site_data;
    }

    public function 
getOutput(){
        return 
$this->output;
    }
    
    
    
    public function 
setId($uid) {
        
$this->uid $uid;
    }
    
    private function 
money(){
        
$stmt $this->con->prepare("SELECT uri, credits FROM server_1_players WHERE userID=:uID");
        
$stmt->bindParam(':uID'$this->uidPDO::PARAM_INT);
        
$stmt->bindParam(':playerID'$this->pidPDO::PARAM_INT);
         if (
$stmt->execute()) {
             
$result $stmt->fetchAll(PDO::FETCH_OBJ);
             
$this->uridium $result[0]->uri;
             
$this->credits $result[0]->credits;
         }
    }  

    public function 
initSkylab()
    {
        
$qry $this->con->prepare("SELECT * FROM skylab WHERE UserID = :uID");
        
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
        if (
$qry->execute()) {
            if (
$qry->rowCount () != 0) {
                
$result $qry->fetchAll(PDO::FETCH_ASSOC);

                
$time = new DateTime();
                
$time $time->getTimestamp();

                
//todo finish transports here
                
                
$basicmod_arr explode("|"$result[0]['basicmod']);
                
$this->mod_basic['level'] = $basicmod_arr[0];
                
$this->mod_basic['status'] = $basicmod_arr[1];
                
$this->mod_basic['upgrade_finished'] = $basicmod_arr[2];
                
                
$storagemod_arr explode("|"$result[0]['storagemod']);
                
$this->mod_store['level'] = $storagemod_arr[0];
                
$this->mod_store['status'] = $storagemod_arr[1];
                
$this->mod_store['upgrade_finished'] = $storagemod_arr[2];
                
                
$solarmod_arr explode("|"$result[0]['solarmod']);
                
$this->mod_solar['level'] = $solarmod_arr[0];
                
$this->mod_solar['status'] = $solarmod_arr[1];
                
$this->mod_solar['upgrade_finished'] = $solarmod_arr[2];

                
$prometiumcol_arr explode("|"$result[0]['prometiumcol']);
                
$this->collector_prometium['level'] = $prometiumcol_arr[0];
                
$this->collector_prometium['status'] = $prometiumcol_arr[1];
                
$this->collector_prometium['upgrade_finished'] = $prometiumcol_arr[2];
                
                
$enduriumcol_arr explode("|"$result[0]['enduriumcol']);
                
$this->collector_endurium['level'] = $enduriumcol_arr[0];
                
$this->collector_endurium['status'] = $enduriumcol_arr[1];
                
$this->collector_endurium['upgrade_finished'] = $enduriumcol_arr[2];
                
                
$terbiumcol_arr explode("|"$result[0]['terbiumcol']);
                
$this->collector_terbium['level'] = $terbiumcol_arr[0];
                
$this->collector_terbium['status'] = $terbiumcol_arr[1];
                
$this->collector_terbium['upgrade_finished'] = $terbiumcol_arr[2];
                
                
$prometidref_arr explode("|"$result[0]['prometidref']);
                
$this->refine_prometid['level'] = $prometidref_arr[0];
                
$this->refine_prometid['status'] = $prometidref_arr[1];
                
$this->refine_prometid['upgrade_finished'] = $prometidref_arr[2];
                
                
$duraniumref_arr explode("|"$result[0]['duraniumref']);
                
$this->refine_duranium['level'] = $duraniumref_arr[0];
                
$this->refine_duranium['status'] = $duraniumref_arr[1];
                
$this->refine_duranium['upgrade_finished'] = $duraniumref_arr[2];
                
                
$promeriumref_arr explode("|"$result[0]['promeriumref']);
                
$this->refine_promerium['level'] = $promeriumref_arr[0];
                
$this->refine_promerium['status'] = $promeriumref_arr[1];
                
$this->refine_promerium['upgrade_finished'] = $promeriumref_arr[2];
                
                
$sepromref_arr explode("|"$result[0]['sepromref']);
                
$this->refine_seprom['level'] = $sepromref_arr[0];
                
$this->refine_seprom['status'] = $sepromref_arr[1];
                
$this->refine_seprom['upgrade_finished'] = $sepromref_arr[2];
                
                
$xenogen_arr explode("|"$result[0]['xenogen']);
                
$this->generator_xeno['level'] = $xenogen_arr[0];
                
$this->generator_xeno['status'] = $xenogen_arr[1];
                
$this->generator_xeno['upgrade_finished'] = $xenogen_arr[2];
                

                
$qryr $this->con->prepare("SELECT * FROM skylab_ressources WHERE LabID = :uID");
                
$qryr->bindParam(':uID'$this->uidPDO::PARAM_INT);
                if (
$qryr->execute()) {
                    
$ress $qryr->fetchAll(PDO::FETCH_ASSOC);
                    
$ress_array = array(
                                    
"prometium" => $ress[0]['prometium'],
                                    
"endurium" => $ress[0]['endurium'],
                                    
"terbium" => $ress[0]['terbium'],
                                    
"prometid" => $ress[0]['prometid'],
                                    
"duranium" => $ress[0]['duranium'],
                                    
"xenomit" => $ress[0]['xenomit'],
                                    
"promerium" => $ress[0]['promerium'],
                                    
"seprom" => $ress[0]['seprom']
                                        );
                    
$this->ressources_array $ress_array;
                    
                    
// update ressources here
                    
                    // check the upgrades after update ressources
                    // 
                    
if($this->mod_basic['status'] == && $this->mod_basic['upgrade_finished'] != 0){
                        if(
$time >= $this->mod_basic['upgrade_finished']){
                            
$this->mod_basic['level'] = $this->mod_basic['level']+1;
                            
$this->mod_basic['status'] = 1;
                            
$this->mod_basic['upgrade_finished'] = 0;
                            
$data implode("|"$this->mod_basic);
                            
$type "basicmod";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }

                    if(
$this->mod_store['status'] == && $this->mod_store['upgrade_finished'] != 0){
                        if(
$time >= $this->mod_store['upgrade_finished']){
                            
$this->mod_store['level'] = $this->mod_store['level']+1;
                            
$this->mod_store['status'] = 1;
                            
$this->mod_store['upgrade_finished'] = 0;
                            
$data implode("|"$this->mod_store);
                            
$type "storagemod";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->mod_solar['status'] == && $this->mod_solar['upgrade_finished'] != 0){
                        if(
$time >= $this->mod_solar['upgrade_finished']){
                            
$this->mod_solar['level'] = $this->mod_solar['level']+1;
                            
$this->mod_solar['status'] = 1;
                            
$this->mod_solar['upgrade_finished'] = 0;
                            
$data implode("|"$this->mod_solar);
                            
$type "solarmod";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->collector_prometium['status'] == && $this->collector_prometium['upgrade_finished'] != 0){
                        if(
$time >= $this->collector_prometium['upgrade_finished']){
                            
$this->collector_prometium['level'] = $this->collector_prometium['level']+1;
                            
$this->collector_prometium['status'] = 1;
                            
$this->collector_prometium['upgrade_finished'] = 0;
                            
$data implode("|"$this->collector_prometium);
                            
$type "prometiumcol";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->collector_endurium['status'] == && $this->collector_endurium['upgrade_finished'] != 0){
                        if(
$time >= $this->collector_endurium['upgrade_finished']){
                            
$this->collector_endurium['level'] = $this->collector_endurium['level']+1;
                            
$this->collector_endurium['status'] = 1;
                            
$this->collector_endurium['upgrade_finished'] = 0;
                            
$data implode("|"$this->collector_endurium);
                            
$type "enduriumcol";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->collector_terbium['status'] == && $this->collector_terbium['upgrade_finished'] != 0){
                        if(
$time >= $this->collector_terbium['upgrade_finished']){
                            
$this->collector_terbium['level'] = $this->collector_terbium['level']+1;
                            
$this->collector_terbium['status'] = 1;
                            
$this->collector_terbium['upgrade_finished'] = 0;
                            
$data implode("|"$this->collector_terbium);
                            
$type "terbiumcol";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->refine_prometid['status'] == && $this->refine_prometid['upgrade_finished'] != 0){
                        if(
$time >= $this->refine_prometid['upgrade_finished']){
                            
$this->refine_prometid['level'] = $this->refine_prometid['level']+1;
                            
$this->refine_prometid['status'] = 1;
                            
$this->refine_prometid['upgrade_finished'] = 0;
                            
$data implode("|"$this->refine_prometid);
                            
$type "prometidref";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->refine_duranium['status'] == && $this->refine_duranium['upgrade_finished'] != 0){
                        if(
$time >= $this->refine_duranium['upgrade_finished']){
                            
$this->refine_duranium['level'] = $this->refine_duranium['level']+1;
                            
$this->refine_duranium['status'] = 1;
                            
$this->refine_duranium['upgrade_finished'] = 0;
                            
$data implode("|"$this->refine_duranium);
                            
$type "duraniumref";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->refine_promerium['status'] == && $this->refine_promerium['upgrade_finished'] != 0){
                        if(
$time >= $this->refine_promerium['upgrade_finished']){
                            
$this->refine_promerium['level'] = $this->refine_promerium['level']+1;
                            
$this->refine_promerium['status'] = 1;
                            
$this->refine_promerium['upgrade_finished'] = 0;
                            
$data implode("|"$this->refine_promerium);
                            
$type "promeriumref";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->refine_seprom['status'] == && $this->refine_seprom['upgrade_finished'] != 0){
                        if(
$time >= $this->refine_seprom['upgrade_finished']){
                            
$this->refine_seprom['level'] = $this->refine_seprom['level']+1;
                            
$this->refine_seprom['status'] = 1;
                            
$this->refine_seprom['upgrade_finished'] = 0;
                            
$data implode("|"$this->refine_seprom);
                            
$type "sepromref";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    
                    if(
$this->generator_xeno['status'] == && $this->generator_xeno['upgrade_finished'] != 0){
                        if(
$time >= $this->generator_xeno['upgrade_finished']){
                            
$this->generator_xeno['level'] = $this->generator_xeno['level']+1;
                            
$this->generator_xeno['status'] = 1;
                            
$this->generator_xeno['upgrade_finished'] = 0;
                            
$data implode("|"$this->generator_xeno);
                            
$type "xenogen";
                            
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                            
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                            
$qry->execute();
                        }
                    }
                    return 
TRUE;
                }
            } else {
                
$time = new DateTime();
                
$time $time->getTimestamp();

                
// level|status|finished-timestamp
                
$qrys $this->con->prepare("INSERT INTO `skylab` 
                                            (`LabID`, `UserID`, `lastvisit`, `basicmod`, `solarmod`, `storagemod`,
                                            `prometiumcol`, `enduriumcol`, `terbiumcol`, `prometidref`, `duraniumref`,
                                            `promeriumref`, `xenogen`, `sepromref`)
                                            VALUES 
                                            (:uID, :uID, :lv, '1|1|0', '1|1|0', '1|1|0', '0|0|0', '0|0|0', '0|0|0', '0|0|0', '0|0|0', '0|0|0', '0|0|0', '0|0|0')"
);
                
$qrys->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qrys->bindParam(':lv'$timePDO::PARAM_INT);
                
$qrys->execute();
                
$qryr $this->con->prepare("INSERT INTO `skylab_ressources`
                                            (`LabID`, `prometium`, `endurium`, `terbium`, `prometid`, `duranium`, `xenomit`, `promerium`, `seprom`) 
                                            VALUES
                                            (:uID, 50000, 50000, 50000, 0, 0, 0, 0, 0)"
);
                
$qryr->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qryr->execute();
                
self::initSkylab();
            }
        }    
    }
    
/* 
        $Skylab['ressources']['prometium']['count'] = $this->ressources_array['prometium'];
        $Skylab['ressources']['endurium']['count'] = $this->ressources_array['endurium'];
        $Skylab['ressources']['terbium']['count'] = $this->ressources_array['terbium'];
        $Skylab['ressources']['prometid']['count'] = $this->ressources_array['prometid'];
        $Skylab['ressources']['duranium']['count'] = $this->ressources_array['duranium'];
        $Skylab['ressources']['xenomit']['count'] = $this->ressources_array['xenomit'];
        $Skylab['ressources']['promerium']['count'] = $this->ressources_array['promerium'];
        $Skylab['ressources']['seprom']['count'] = $this->ressources_array['seprom'];

        $Skylab['ressources']['prometium']['max_storage'] = self::storage('raw', $this->mod_store['level']);
        $Skylab['ressources']['endurium']['max_storage'] = self::storage('raw', $this->mod_store['level']);
        $Skylab['ressources']['terbium']['max_storage'] = self::storage('raw', $this->mod_store['level']);
        $Skylab['ressources']['prometid']['max_storage'] = self::storage('refined', $this->mod_store['level']);
        $Skylab['ressources']['duranium']['max_storage'] = self::storage('refined', $this->mod_store['level']);
        $Skylab['ressources']['xenomit']['max_storage'] = self::storage('proxeno', $this->mod_store['level']);
        $Skylab['ressources']['promerium']['max_storage'] = self::storage('proxeno', $this->mod_store['level']);
        $Skylab['ressources']['seprom']['max_storage'] = self::storage('seprom', $this->mod_store['level']);
                
                
    $this->ressources_array['prometium'];
    $this->ressources_array['endurium'];
    $this->ressources_array['prometium'];
    $this->ressources_array['prometium'];
    */

    
public function ressupdate($mode "out"){
        
$qry $this->con->prepare("SELECT lastvisit FROM Skylab WHERE UserID = :uID");
        
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
        
$qry->execute();
        
$arr $qry->fetchAll(PDO::FETCH_ASSOC);
        
$lv $arr[0]['lastvisit'];
        
        
$time = new DateTime();
        
$time $time->getTimestamp();
        
        
$multi $time-$lv;
    
        if(
$this->collector_prometium['status'] == 1)
            
$prometium_per_sec = (int) self::ressource_generation('raw',$this->collector_prometium['level'])/3600;
        else
            
$prometium_per_sec 0;
            
        if(
$this->collector_endurium['status'] == 1)
            
$endurium_per_sec = (int) self::ressource_generation('raw',$this->collector_endurium['level'])/3600;
        else
            
$endurium_per_sec 0;
        
        if(
$this->collector_terbium['status'] == 1)
            
$terbium_per_sec = (int) self::ressource_generation('raw',$this->collector_terbium['level'])/3600;
        else
            
$terbium_per_sec 0;
        
        if(
$this->refine_prometid['status'] == 1){
            
$prometid_per_sec = (int) self::ressource_generation('refined',$this->refine_prometid['level'])/3600;
            
$prometium_usage $prometid_per_sec*20;
            
$endurium_usage1 $prometid_per_sec*10;
        }else
            
$prometid_per_sec 0;
        
        if(
$this->refine_duranium['status'] == 1){
            
$duranium_per_sec = (int) self::ressource_generation('refined',$this->refine_duranium['level'])/3600;
            
$terbium_usage $duranium_per_sec*20;
            
$endurium_usage2 $duranium_per_sec*10;
        }else
            
$duranium_per_sec 0;
        
        if(
$this->refine_promerium['status'] == 1){
            
$promerium_per_sec = (int) self::ressource_generation('proxeno',$this->refine_promerium['level'])/3600;
            
$prometid_usage $promerium_per_sec*10;
            
$duranium_usage $promerium_per_sec*10;
         }else
            
$promerium_per_sec 0;
            
        if(
$this->refine_seprom['status'] == 1){
            
$seprom_per_sec = (int) self::ressource_generation('seprom',$this->refine_seprom['level'])/3600;
            
$promerium_usage $seprom_per_sec*10;
        }else    
            
$seprom_per_sec 0;
            
        if(
$this->generator_xeno['status'] == 1)
            
$xeno_per_sec = (int) self::ressource_generation('proxeno',$this->generator_xeno['level'])/3600;
        else
            
$xeno_per_sec 0;
        
        if(isset(
$prometium_usage))
            
$prometium_per_sec $prometium_per_sec-$prometium_usage;

        if(isset(
$endurium_usage1) && isset($endurium_usage2))
            
$endurium_per_sec $endurium_per_sec-($endurium_usage1+$endurium_usage2);
        elseif(isset(
$endurium_usage1) && !isset($endurium_usage2))
            
$endurium_per_sec $endurium_per_sec-$endurium_usage1;
        elseif(!isset(
$endurium_usage1) && isset($endurium_usage2))
            
$endurium_per_sec $endurium_per_sec-$endurium_usage2;
        
        if(isset(
$terbium_usage))
            
$terbium_per_sec $terbium_per_sec-$terbium_usage;
        
        if(isset(
$prometid_usage))
            
$prometid_per_sec $prometid_per_sec-$prometid_usage;
        
        if(isset(
$duranium_usage))
            
$duranium_per_sec $duranium_per_sec-$duranium_usage;
        
        if(isset(
$promerium_usage))
            
$promerium_per_sec $promerium_per_sec-$promerium_usage;
        
        
$raw_max self::storage('raw'$this->mod_store['level']);
        
$ref_max self::storage('refined'$this->mod_store['level']);
        
$pro_max self::storage('proxeno'$this->mod_store['level']);
        
$sep_max self::storage('seprom'$this->mod_store['level']);
        
        
$free $raw_max-$this->ressources_array['prometium'];
        
$v01 round($prometium_per_sec*$multi);
        if(
$v01 $free)
            
$v01 $free;
        
        
$freee $raw_max-$this->ressources_array['endurium'];
        
$v02 round($endurium_per_sec*$multi);
        if(
$v02 $freee)
            
$v02 $freee;

        
$freeee $raw_max-$this->ressources_array['terbium'];
        
$v03 round($terbium_per_sec*$multi);
        if(
$v03 $freeee)
            
$v03 $freeee;
        
        
$reeee $ref_max-$this->ressources_array['prometid'];
        
$v04 round($prometid_per_sec*$multi);
        if(
$v04 $reeee)
            
$v04 $reeee;
        
        
$eeeee $ref_max-$this->ressources_array['duranium'];
        
$v05 round($duranium_per_sec*$multi);
        if(
$v05 $eeeee)
            
$v05 $eeeee;
        
        
$yoour $pro_max-$this->ressources_array['xenomit'];
        
$v06 round($xeno_per_sec*$multi);
        if(
$v06 $yoour)
            
$v06 $yoour;
        
        
$mmiii $pro_max-$this->ressources_array['promerium'];
        
$v07 round($promerium_per_sec*$multi);
        if(
$v07 $mmiii)
            
$v07 $mmiii;
        
        
$iinnd $sep_max-$this->ressources_array['seprom'];
        
$v08 round($seprom_per_sec*$multi);
        if(
$v08 $iinnd)
            
$v08 $iinnd;
        
        
        if(
$mode == "out"){
            
$this->output['prometium'] = round($prometium_per_sec*3600);
            
$this->output['endurium'] = round($endurium_per_sec*3600);
            
$this->output['terbium'] = round($terbium_per_sec*3600);
            
$this->output['prometid'] = round($prometid_per_sec*3600);
            
$this->output['duranium'] = round($duranium_per_sec*3600);
            
$this->output['xenomit'] = round($xeno_per_sec*3600);
            
$this->output['promerium'] = round($promerium_per_sec*3600);
            
$this->output['seprom'] = round($seprom_per_sec*3600);
        }elseif(
$mode == "update"){
            
$qry $this->con->prepare("UPDATE skylab, skylab_ressources 
                                          SET skylab.lastvisit = :ts,
                                              skylab_ressources.prometium = skylab_ressources.prometium + :v01,
                                              skylab_ressources.endurium = skylab_ressources.endurium + :v02,
                                              skylab_ressources.terbium = skylab_ressources.terbium + :v03,
                                              skylab_ressources.prometid = skylab_ressources.prometid + :v04,
                                              skylab_ressources.duranium = skylab_ressources.duranium + :v05,
                                              skylab_ressources.xenomit = skylab_ressources.xenomit + :v06,
                                              skylab_ressources.promerium = skylab_ressources.promerium + :v07,
                                              skylab_ressources.seprom = skylab_ressources.seprom + :v08 
                                            WHERE skylab.UserID = :uID AND skylab_ressources.LabID = skylab.UserID"
);
            
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
            
$qry->bindParam(':ts'$timePDO::PARAM_INT);
            
$qry->bindParam(':v01'$v01PDO::PARAM_INT);
            
$qry->bindParam(':v02'$v02PDO::PARAM_INT);
            
$qry->bindParam(':v03'$v03PDO::PARAM_INT);
            
$qry->bindParam(':v04'$v04PDO::PARAM_INT);
            
$qry->bindParam(':v05'$v05PDO::PARAM_INT);
            
$qry->bindParam(':v06'$v06PDO::PARAM_INT);
            
$qry->bindParam(':v07'$v07PDO::PARAM_INT);
            
$qry->bindParam(':v08'$v08PDO::PARAM_INT);
            
$qry->execute();
        }
    }
    
    public function 
displayBuild()
    {
        
//if(self::initSkylab()) {
            
$ret "<div id=\"skylab_shadow\"></div>";
            
            if(
$this->collector_prometium['level'] != 0){
                
$ret .= "<div id=\"backgroundPrometiumCollector\"></div>";
                
$ret .= "<div id=\"uplinkPrometiumCollector\"></div>";
            }

            if(
$this->collector_endurium['level'] != 0){
                
$ret .= "<div id=\"backgroundEnduriumCollector\"></div>";
                
$ret .= "<div id=\"uplinkEnduriumCollector\"></div>";
            }

            if(
$this->collector_terbium['level'] != 0){
                
$ret .= "<div id=\"backgroundTerbiumCollector\"></div>";
                
$ret .= "<div id=\"uplinkTerbiumCollector\"></div>";
            }

            if(
$this->refine_prometid['level'] != 0){
                
$ret .= "<div id=\"backgroundPrometidRefinery\"></div>";
                
$ret .= "<div id=\"uplinkPrometidRefinery\"></div>";
            }

            if(
$this->refine_duranium['level'] != 0){
                
$ret .= "<div id=\"backgroundDuraniumRefinery\"></div>";
                
$ret .= "<div id=\"uplinkDuraniumRefinery\"></div>";
            }

            if(
$this->refine_promerium['level'] != 0){
                
$ret .= "<div id=\"backgroundPromeriumRefinery\"></div>";
                
$ret .= "<div id=\"uplinkPromeriumRefinery\"></div>";
            }

            if(
$this->refine_seprom['level'] != 0){
                
$ret .= "<div id=\"backgroundSepromRefinery\"></div>";
                
$ret .= "<div id=\"uplinkSepromRefinery\"></div>";
            }

            if(
$this->generator_xeno['level'] != 0){
                
$ret .= "<div id=\"backgroundXenoModule\"></div>";
                
$ret .= "<div id=\"uplinkXenoModule\"></div>";
            }
            
            return 
$ret;
        
//}
    
}
    
    public function 
setStatus($module$nst$act){
        if(
$act == "status"){
            if(
$module == "xenoModule"){
                
$type "xenogen";
                
$data "" $this->generator_xeno['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);

                
if($qry->execute()){
                    
$this->generator_xeno['status'] = $nst;
                }
            }elseif(
$module == "prometiumCollector"){
                
$type "prometiumcol";
                
$data "" $this->collector_prometium['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_prometium['status'] = $nst;
                }
            }elseif(
$module == "enduriumCollector"){
                
$type "enduriumcol";
                
$data "" $this->collector_endurium['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_endurium['status'] = $nst;
                }
            }elseif(
$module == "terbiumCollector"){
                
$type "terbiumcol";
                
$data "" $this->collector_terbium['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_terbium['status'] = $nst;
                }
            }elseif(
$module == "prometidRefinery"){
                
$type "prometidref";
                
$data "" $this->refine_prometid['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_prometid['status'] = $nst;
                }
            }elseif(
$module == "duraniumRefinery"){
                
$type "duraniumref";
                
$data "" $this->refine_duranium['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_duranium['status'] = $nst;
                }
            }elseif(
$module == "promeriumRefinery"){
                
$type "promeriumref";
                
$data "" $this->refine_promerium['level'] . "|" $nst "|0";
                
                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_promerium['status'] = $nst;
                }
            }elseif(
$module == "sepromRefinery"){
                
$type "sepromref";
                
$data "" $this->refine_seprom['level'] . "|" $nst "|0";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_seprom['status'] = $nst;
                }
            }
        }elseif(
$act == "upthis"){
        
            
$time = new DateTime();
            
$time $time->getTimestamp();
            
// actions table
            // actionid(AI)(PK)|labid(PK)|actiontype|actiondate|finishedts
        
            
if($module == "xenoModule"){
                
$type "xenogen";
                
$nt = (int) self::upgrade_time('refine',$this->generator_xeno['level']+1);
                
$time $time $nt;
                
$data "" $this->generator_xeno['level'] . "|" $nst "|" $time "";
                
                
/*
                
                private function req_ress($type, $level, $instant = 'no'){
                
                $up_cost_raw = self::upgrade_cost('generator','cost_raw',$this->generator_xeno['level']+1);
                $up_cost_cre = self::upgrade_cost('generator','cost_cre',$this->generator_xeno['level']+1);
                $up_cost_uri = self::upgrade_cost('generator','cost_uri',$this->generator_xeno['level']+1);
                    $raw = ;
                    $cre = ;
                    if($instant != 'no')
                        $uri = ;
                    
                }
                $qry = $this->con->prepare("UPDATE skylab_ressources SET {$type} = :data WHERE UserID = :uID");
                $qry->bindParam(':uID', $this->uid, PDO::PARAM_INT);
                $qry->execute();*/
                
                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
                

                if(
$qry->execute()){
                    
$this->generator_xeno['status'] = $nst;
                }
            }elseif(
$module == "prometiumCollector"){
                
$type "prometiumcol";
                
$nt = (int) self::upgrade_time('collectors',$this->collector_prometium['level']+1);
                
$time $time $nt;
                
$data "" $this->collector_prometium['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_prometium['status'] = $nst;
                }
            }elseif(
$module == "enduriumCollector"){
                
$type "enduriumcol";
                
$nt = (int) self::upgrade_time('collectors',$this->collector_endurium['level']+1);
                
$time $time $nt;
                
$data "" $this->collector_endurium['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_endurium['status'] = $nst;
                }
            }elseif(
$module == "terbiumCollector"){
                
$type "terbiumcol";
                
$nt = (int) self::upgrade_time('collectors',$this->collector_terbium['level']+1);
                
$time $time $nt;
                
$data "" $this->collector_terbium['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->collector_terbium['status'] = $nst;
                }
            }elseif(
$module == "prometidRefinery"){
                
$type "prometidref";
                
$nt = (int) self::upgrade_time('refine',$this->refine_prometid['level']+1);
                
$time $time $nt;
                
$data "" $this->refine_prometid['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_prometid['status'] = $nst;
                }
            }elseif(
$module == "duraniumRefinery"){
                
$type "duraniumref";
                
$nt = (int) self::upgrade_time('refine',$this->refine_duranium['level']+1);
                
$time $time $nt;
                
$data "" $this->refine_duranium['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_duranium['status'] = $nst;
                }
            }elseif(
$module == "promeriumRefinery"){
                
$type "promeriumref";
                
$nt = (int) self::upgrade_time('refine',$this->refine_promerium['level']+1);
                
$time $time $nt;
                
$data "" $this->refine_promerium['level'] . "|" $nst "|" $time "";
                
                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
            
//    $qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_promerium['status'] = $nst;
                }
            }elseif(
$module == "sepromRefinery"){
                
$type "sepromref";
                
$nt = (int) self::upgrade_time('seprom',$this->refine_seprom['level']+1);
                
$time $time $nt;
                
$data "" $this->refine_seprom['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);
                
                
if($qry->execute()){
                    
$this->refine_seprom['status'] = $nst;
                }
            }elseif(
$module == "storageModule"){
                
$type "storagemod";
                
$nt = (int) self::upgrade_time('basic',$this->mod_store['level']+1);
                
$time $time $nt;
                
$data "" $this->mod_store['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);

                
if($qry->execute()){
                    
$this->mod_store['status'] = $nst;
                }
            }elseif(
$module == "solarModule"){
                
$type "solarmod";
                
$nt = (int) self::upgrade_time('basic',$this->mod_solar['level']+1);
                
$time $time $nt;
                
$data "" $this->mod_solar['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);

                
if($qry->execute()){
                    
$this->mod_solar['status'] = $nst;
                }
            }elseif(
$module == "baseModule"){
                
$type "basicmod";
                
$nt = (int) self::upgrade_time('basic',$this->mod_basic['level']+1);
                
$time $time $nt;
                
$data "" $this->mod_basic['level'] . "|" $nst "|" $time "";

                
$qry $this->con->prepare("UPDATE skylab SET {$type} = :data WHERE UserID = :uID");
                
$qry->bindParam(':uID'$this->uidPDO::PARAM_INT);
                
$qry->bindParam(':data'$dataPDO::PARAM_STR);
                
//$qry->bindParam(":type", $type, PDO::PARAM_STR);

                
if($qry->execute()){
                    
$this->mod_basic['status'] = $nst;
                }
            }
        }elseif(
$act == "instaup"){
        
        }
    }
    
    public function 
showModule($module,$srq) {
        if(
$module == "xenoModule"){
            
$req "xenoModule";
            
$name "Xeno Module";
            
$level $this->generator_xeno['level'];
            
$status $this->generator_xeno['status'];
            
$eusage self::energy_usage($this->generator_xeno['level']);
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('generator','cost_raw',$this->generator_xeno['level']+1);
                
$up_cost_cre self::upgrade_cost('generator','cost_cre',$this->generator_xeno['level']+1);
                
$up_cost_uri self::upgrade_cost('generator','cost_uri',$this->generator_xeno['level']+1);
                
$up_time = (int) self::upgrade_time('refine',$this->generator_xeno['level']+1);
            }
            if(
$status == 2)
                
$fts $this->generator_xeno['upgrade_finished'];
        }elseif(
$module == "prometiumCollector"){
            
$req "prometiumCollector";
            
$name "Prometium collector";
            
$level $this->collector_prometium['level'];
            
$status $this->collector_prometium['status'];
            
$eusage self::energy_usage($this->collector_prometium['level']);
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('collectors','cost_raw',$this->collector_prometium['level']+1);
                
$up_cost_cre self::upgrade_cost('collectors','cost_cre',$this->collector_prometium['level']+1);
                
$up_cost_uri self::upgrade_cost('collectors','cost_uri',$this->collector_prometium['level']+1);
                
$up_time = (int) self::upgrade_time('collectors',$this->collector_prometium['level']+1);
            }
            if(
$status == || $status == 2)
                
$cdgens_cnt "0";
            else
                
$cdgens_cnt self::ressource_generation("raw",$this->collector_prometium['level']);
            
            if(
$status == 2)
                
$fts $this->collector_prometium['upgrade_finished'];
        }elseif(
$module == "enduriumCollector"){
            
$req "enduriumCollector";
            
$name "Endurium collector";
            
$level $this->collector_endurium['level'];
            
$status $this->collector_endurium['status'];
            
$eusage self::energy_usage($this->collector_endurium['level']);
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('collectors','cost_raw',$this->collector_endurium['level']+1);
                
$up_cost_cre self::upgrade_cost('collectors','cost_cre',$this->collector_endurium['level']+1);
                
$up_cost_uri self::upgrade_cost('collectors','cost_uri',$this->collector_endurium['level']+1);
                
$up_time = (int) self::upgrade_time('collectors',$this->collector_endurium['level']+1);
            }
            if(
$status == || $status == 2)
                
$cdgens_cnt "0";
            else
                
$cdgens_cnt self::ressource_generation("raw",$this->collector_endurium['level']);

            if(
$status == 2)
                
$fts $this->collector_endurium['upgrade_finished'];
        }elseif(
$module == "terbiumCollector"){
            
$req "terbiumCollector";
            
$name "Terbium collector";
            
$level $this->collector_terbium['level'];
            
$status $this->collector_terbium['status'];
            
$eusage self::energy_usage($this->collector_terbium['level']);
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('collectors','cost_raw',$this->collector_terbium['level']+1);
                
$up_cost_cre self::upgrade_cost('collectors','cost_cre',$this->collector_terbium['level']+1);
                
$up_cost_uri self::upgrade_cost('collectors','cost_uri',$this->collector_terbium['level']+1);
                
$up_time = (int) self::upgrade_time('collectors',$this->collector_terbium['level']+1);
            }
            if(
$status == || $status == 2)
                
$cdgens_cnt "0";
            else
                
$cdgens_cnt self::ressource_generation("raw",$this->collector_terbium['level']);
                
            if(
$status == 2)
                
$fts $this->collector_terbium['upgrade_finished'];
        }elseif(
$module == "prometidRefinery"){
            
$req "prometidRefinery";
            
$name "Prometid refinery";
            
$level $this->refine_prometid['level'];
            
$status $this->refine_prometid['status'];
            
$eusage self::energy_usage($this->refine_prometid['level']);
            
$type "refinery";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('refine','cost_raw',$this->refine_prometid['level']+1);
                
$up_cost_cre self::upgrade_cost('refine','cost_cre',$this->refine_prometid['level']+1);
                
$up_cost_uri self::upgrade_cost('refine','cost_uri',$this->refine_prometid['level']+1);
                
$up_time = (int) self::upgrade_time('refine',$this->refine_prometid['level']+1);
            }
            
$rdtype "3";
            
$rduseone "prometium";
            
$rdusetwo "endurium";
            
$rdgens "prometid";
            if(
$status == || $status == 2){
                
$rduseone_con "0";
                
$rdusetwo_con "0";
                
$rdgens_cnt "0";
            }else{
                
$rdgens_cnt self::ressource_generation("refined",$this->refine_prometid['level']);
                
$rduseone_con $rdgens_cnt*20;
                
$rdusetwo_con $rdgens_cnt*10;
            }
            
            if(
$status == 2)
                
$fts $this->refine_prometid['upgrade_finished'];
        }elseif(
$module == "duraniumRefinery"){
            
$req "duraniumRefinery";
            
$name "Duranium refinery";
            
$level $this->refine_duranium['level'];
            
$status $this->refine_duranium['status'];
            
$eusage self::energy_usage($this->refine_duranium['level']);
            
$type "refinery";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('refine','cost_raw',$this->refine_duranium['level']+1);
                
$up_cost_cre self::upgrade_cost('refine','cost_cre',$this->refine_duranium['level']+1);
                
$up_cost_uri self::upgrade_cost('refine','cost_uri',$this->refine_duranium['level']+1);
                
$up_time = (int) self::upgrade_time('refine',$this->refine_duranium['level']+1);
            }
            
$rdtype "3";
            
$rduseone "endurium";
            
$rdusetwo "terbium";
            
$rdgens "duranium";
            if(
$status == || $status == 2){
                
$rduseone_con "0";
                
$rdusetwo_con "0";
                
$rdgens_cnt "0";
            }else{
                
$rdgens_cnt self::ressource_generation("refined",$this->refine_duranium['level']);
                
$rduseone_con $rdgens_cnt*10;
                
$rdusetwo_con $rdgens_cnt*20;
            }
            
            if(
$status == 2)
                
$fts $this->refine_duranium['upgrade_finished'];
        }elseif(
$module == "promeriumRefinery"){
            
$req "promeriumRefinery";
            
$name "Promerium refinery";
            
$level $this->refine_promerium['level'];
            
$status $this->refine_promerium['status'];
            
$eusage self::energy_usage($this->refine_promerium['level']);
            
$type "refinery";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('refine','cost_raw',$this->refine_promerium['level']+1);
                
$up_cost_cre self::upgrade_cost('refine','cost_cre',$this->refine_promerium['level']+1);
                
$up_cost_uri self::upgrade_cost('refine','cost_uri',$this->refine_promerium['level']+1);
                
$up_time = (int) self::upgrade_time('refine',$this->refine_promerium['level']+1);
            }
            
            
//$rdtype = "4"; // for xeno
            
$rdtype "3";
            
$rduseone "prometid";
            
$rdusetwo "duranium";
            
$rdgens "promerium";
            if(
$status == || $status == 2){
                
$rduseone_con "0";
                
$rdusetwo_con "0";
                
$rdgens_cnt "0";
            }else{
                
$rdgens_cnt self::ressource_generation("proxeno",$this->refine_promerium['level']);
                
$rduseone_con $rdgens_cnt*10;
                
$rdusetwo_con $rdgens_cnt*10;
            }
        
            if(
$status == 2)
                
$fts $this->refine_promerium['upgrade_finished'];
        }elseif(
$module == "sepromRefinery"){
            
$req "sepromRefinery";
            
$name "Seprom refinery";
            
$level $this->refine_seprom['level'];
            
$status $this->refine_seprom['status'];
            
$eusage self::energy_usage($this->refine_seprom['level']);
            
$type "refinery";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('refine_sep','cost_raw',$this->refine_seprom['level']+1);
                
$up_cost_cre self::upgrade_cost('refine_sep','cost_cre',$this->refine_seprom['level']+1);
                
$up_cost_uri self::upgrade_cost('refine_sep','cost_uri',$this->refine_seprom['level']+1);
                
$up_time = (int) self::upgrade_time('seprom',$this->refine_seprom['level']+1);
            }
            
$rdtype "2";
            
$rduseone "promerium";
            
$rdusetwo "";
            
$rdgens "seprom";
            if(
$status == || $status == 2){
                
$rduseone_con "0";
                
$rdusetwo_con "";
                
$rdgens_cnt "0";
            }else{
                
$rdgens_cnt self::ressource_generation("seprom",$this->refine_seprom['level']);
                
$rduseone_con $rdgens_cnt*10;
                
$rdusetwo_con "";
            }
            
            if(
$status == 2)
                
$fts $this->refine_seprom['upgrade_finished'];
        }elseif(
$module == "storageModule"){
            
$req "storageModule";
            
$name "Storage module";
            
$level $this->mod_store['level'];
            
$status $this->mod_store['status'];
            
$eusage self::energy_usage($this->mod_store['level']);
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('store','cost_raw',$this->mod_store['level']+1);
                
$up_cost_cre self::upgrade_cost('store','cost_cre',$this->mod_store['level']+1);
                
$up_cost_uri self::upgrade_cost('store','cost_uri',$this->mod_store['level']+1);
                
$up_time = (int) self::upgrade_time('basic',$this->mod_store['level']+1);
            }
            if(
$status == 2)
                
$fts $this->mod_basic['upgrade_finished'];
        }elseif(
$module == "solarModule"){
            
$req "solarModule";
            
$name "Solar module";
            
$level $this->mod_solar['level'];
            
$status $this->mod_solar['status'];
            
$type "other";
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('solar','cost_raw',$this->mod_solar['level']+1);
                
$up_cost_cre self::upgrade_cost('solar','cost_cre',$this->mod_solar['level']+1);
                
$up_cost_uri self::upgrade_cost('solar','cost_uri',$this->mod_solar['level']+1);
                
$up_time = (int) self::upgrade_time('basic',$this->mod_solar['level']+1);
            }
            
$eusage self::energy_all_usage();
            
$prod self::energy_production($this->mod_solar['level']);

            if(
$status == 2)
                
$fts $this->mod_solar['upgrade_finished'];
        }elseif(
$module == "baseModule"){
            
$req "baseModule";
            
$name "Basic module";
            
$level $this->mod_basic['level'];
            if(
$level 20){
                
$up_cost_raw self::upgrade_cost('basic','cost_raw',$this->mod_basic['level']+1);
                
$up_cost_cre self::upgrade_cost('basic','cost_cre',$this->mod_basic['level']+1);
                
$up_cost_uri self::upgrade_cost('basic','cost_uri',$this->mod_basic['level']+1);
                
$up_time = (int) self::upgrade_time('basic',$this->mod_basic['level']+1);
            }
            
            
$status $this->mod_basic['status'];
            
$eusage self::energy_usage($this->mod_basic['level']);
            
$type "other";
            
            if(
$status == 2)
                
$fts $this->mod_basic['upgrade_finished'];
        }
        
        if(
$module != "solarModule" && $module != "baseModule" && $module != "storageModule")
            
$eusage = ($status == || $status == 2) ? "0" $eusage;

        
$corner_status = ($status == || $status == 2) ? "inactive" "active";
        
$name_status = ($status 0) ? "" "_inactive";
        
$level_icon_status = ($status == 2) ? "level_icon_upgrade" : (($status == 0) ? "level_icon_inactive" "level_icon");
        
$font_level_status = ($status == 0) ? "level skylab_font_level_inactive" "level skylab_font_level";
        
$efficiency = ($status == || $status == 2) ? "0" "100";

        if(
$srq == "smallbox"){
            
$ret "<div id=\"module_" $req "_small\" class=\"module module_small\" onclick=\"Skylab.showModule('" $req "');\"\">";
            
$ret .= "    <table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">";
            
$ret .= "        <tr>";
            
$ret .= "            <td id=\"corner_small_top_left_" $corner_status "\">";
            
$ret .= "                <div class=\"name" $name_status "\">" $name "</div>";
            
$ret .= "            </td>";
            
$ret .= "            <td id=\"corner_small_top_right_" $corner_status "\"></td>";
            
$ret .= "        </tr>";
            
$ret .= "        <tr>";
            
$ret .= "            <td id=\"corner_small_bottom_left_" $corner_status "\">";
            if(
$level 0){
                
$ret .= "        <table cellpadding=\"0\" cellspacing=\"0\">";
                
$ret .= "            <tr>";
                
$ret .= "                <td>";
                
$ret .= "                    <div class=\"" $level_icon_status "\"></div>";
                
$ret .= "                    <div class=\"" $font_level_status "\">" $level "</div>";
                
$ret .= "                </td>";
                
$ret .= "                <td class=\"cellview\">";
                
$ret .= "                    <div class=\"power_icon\"></div>";
                if(
$req != "solarModule")
                    
$ret .= "                   <div class=\"power skylab_font_power\">" $eusage "</div>";
                else
                    
$ret .= "                   <div class=\"power skylab_font_power\">" $eusage " / " $prod "</div>";
                
$ret .= "                </td>";
                if(
$type == "refinery"){
                    
$ret .= "            <td class=\"cellview\">";
                    
$ret .= "                 <div class=\"efficiency_icon\"></div>";
                    
$ret .= "                 <div class=\"efficiency skylab_font_efficiency\">" $efficiency "%</div>";
                    
$ret .= "            </td>";
                }
                
$ret .= "                <td><br /></td>";
                
$ret .= "            </tr>";
                
$ret .= "        </table>";
            }
            
$ret .= "    </td>";
            
$ret .= "    <td id=\"corner_small_bottom_right_" $corner_status "\"></td>";
            
$ret .= "</tr>";
            
$ret .= "</table>";
            
$ret .= "</div>";
        }elseif(
$srq == "refineryDetails"){
            
$ret "<div id=\"module_infobox_" $req "_overview_large\" class=\"tabContent skylab_standard\">";
            
$ret .= "    <div style=\"height:135px;background-image: url(./do_img/global/pilotSheet/skylab/bg_refinery_" $rdtype ".png?__cv=8a7c8d311f248f5e62d247296cbdc300); background-repeat:no-repeat;background-position: center 25px\">";
            
$ret .= "        <div style=\"position:absolute;left:75px;top:90px;\" class=\"ore_" $rduseone "\"><strong>" $rduseone "<br />" $rduseone_con "</strong></div>";
            if(
$req != "sepromRefinery"){
                
$ret .= "        <div style=\"position:absolute;left:235px;top:90px;text-align:right;\" class=\"ore_" $rdusetwo "\"><strong>" $rdusetwo "<br />" $rdusetwo_con "</strong></div>";
            }
            
$ret .= "        <div style=\"position:absolute;left:100px;top:150px;\">" $efficiency "%</div>";
            
$ret .= "        <div style=\"position:absolute;left:155px;top:185px;\" class=\"ore_" $rdgens "\"><strong>" $rdgens "<br />" $rdgens_cnt "</strong></div>";
            
$ret .= "        <div class=\"icon_efficiency icon_efficiency_" $efficiency "\"></div>";
            if(
$efficiency == 0){
                
$ret .= "        <div class=\"icon_attention\"></div>";
            }
            
$ret .= "    </div>";
            
$ret .= "</div>";
        }elseif(
$srq == "collectorDetails"){
            
$ret "<div class=\"collector_info collector_info_" $req "\"> Level: 1 - Production: " $cdgens_cnt "</div>";
        }elseif(
$srq == "upthis"){
            if(
$status != && $level 20)
                
$ret "<div id=\"module_infobox_" $req "_upgrade_large\" class=\"tabContent skylab_standard\" style=\"display: none;\"><table class=\"module_infobox_upgrade\" cellpadding=\"0\" cellspacing=\"0\"><tr><td class=\"firstRow\"><br /></td><td class=\"secondRow\">Instant</td><td class=\"thirdRow skylab_price_normal\" style=\"width:1px;\"><div style=\"position:absolute;width:1px;height:124px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_vertical.jpg?__cv=0f3388b877b7ef4dd20df64be8699800);\"></div><br /></td><td>Normal</td></tr><tr><td colspan=\"4\" style=\"height:1px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_horizontal.jpg?__cv=b7a2175510ce6023a12e11870f954500);background-repeat:no-repeat;background-position: 65px;\"></td></tr><tr><td class=\"firstRow\">Uridium</td><td class=\"secondRow\">" .  $up_cost_uri "</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">0</td></tr><tr><td colspan=\"4\" style=\"height:1px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_horizontal.jpg?__cv=b7a2175510ce6023a12e11870f954500);background-repeat:no-repeat;background-position: 65px;\"></td></tr><tr><td class=\"firstRow\">Credits</td><td class=\"secondRow\">" .  $up_cost_cre "</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">" .  $up_cost_cre "</td></tr><tr><td class=\"firstRow\">Time</td><td class=\"secondRow\">instant</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">" . ($up_time/3600) . "h</td></tr><tr><td class=\"firstRow\">Prometium</td><td class=\"secondRow\">" .  $up_cost_raw "</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">" .  $up_cost_raw "</td></tr><tr><td class=\"firstRow\">Endurium</td><td class=\"secondRow\">" .  $up_cost_raw "</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">" .  $up_cost_raw "</td></tr><tr><td class=\"firstRow\">Terbium</td><td class=\"secondRow\">" .  $up_cost_raw "</td><td><br /></td><td class=\"thirdRow skylab_price_normal\">" .  $up_cost_raw "</td></tr><tr><td colspan=\"4\" style=\"height:1px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_horizontal.jpg?__cv=b7a2175510ce6023a12e11870f954500);background-repeat:no-repeat;background-position: 65px;\"></td></tr><tr><td colspan=\"2\" style=\"padding:8px 3px\"><div class=\"button_standard\" style=\"float:right;\"><a style=\"display:block;\" onfocus=\"this.blur()\" onclick=\"setConfirmButtonText('confirmText', 'OK'); setCancelButtonText('cancelText', 'Cancel'); openConfirm('indexInternal.es?action=internalSkylab&subaction=instantUpgrade&construction=" $req "&reloadToken=1e1064a8fdf038ee6e4c99e2beab4d29', 'Confirm upgrade?')\">Instant build</a></div></td><td colspan=\"2\" style=\"padding:8px 5px\"><div class=\"button_standard\"><a style=\"display:block\" onfocus=\"this.blur()\" href=\"indexInternal.es?action=internalSkylab&subaction=upgrade&construction=" $req "&reloadToken=1e1064a8fdf038ee6e4c99e2beab4d29\">Build</a></div></td></tr></table></div>";
            elseif(
$level >= 20)
                
$ret "<div id=\"module_infobox_" $req "_upgrade_large\" class=\"tabContent skylab_standard\" style=\"\"><div class=\"upgrade_container_max\">Maximum upgrade level attained</div></div>";
            elseif(
$status == 2){
                
$rdy date("m-d-Y h:i a",$fts);
                
$ret "<div id=\"module_infobox_" $req "_upgrade_large\" class=\"tabContent skylab_standard\" style=\"\"><div class=\"upgrade_container_max\">Upgrade until: " $rdy "</div></div>";
            }
                
        }elseif(
$srq == "footer"){
            
$ret "<div id=\"module_infobox_" $req "_footer\" class=\"skylab_module_footer\">";
            
$ret .= "<div class=\"module_info_active_state module_infobox_info\">";
            if((
$module != "baseModule" && $module != "solarModule" && $module != "storageModule") && $status == 1){
                
$ret .= "<img src=\"./do_img/global/pilotSheet/skylab/power_on.png?__cv=4eeda785991deb1830052b0d935d3d00\" width=\"14\" height=\"14\" onclick=\"javascript: do_redirect('indexInternal.es?action=internalSkylab&subaction=setInactive&construction=" $req "&reloadToken=1e1064a8fdf038ee6e4c99e2beab4d29');\" style=\"cursor: pointer\" />";
            }elseif(
$module == "baseModule" || $module == "solarModule" || $module == "storageModule"){
                
$ret .= "<img src=\"./do_img/global/pilotSheet/skylab/power_on.png?__cv=b0a4878430feb41ac03c5a6d796fda00\" width=\"14\" height=\"14\" />";
            }elseif(
$level == 0){
                
$ret .= "<img src=\"./do_img/global/pilotSheet/skylab/power_disabled.png?__cv=b0a4878430feb41ac03c5a6d796fda00\" width=\"14\" height=\"14\" />";
            }else{
                
$ret .= "<img src=\"./do_img/global/pilotSheet/skylab/power_off.png?__cv=58f1b6a316567d6b736c56c2e314ab00\" width=\"14\" height=\"14\" onclick=\"javascript: do_redirect('indexInternal.es?action=internalSkylab&subaction=setActive&construction=" $req "&reloadToken=4de85a941fcd833dd7709715da051258');\" style=\"cursor: pointer\">";
            }
            
$ret .= "</div>";
            
$ret .= "<div class=\"module_info_level module_infobox_info\">";
            
$ret .= " <div class=\"level_icon\">" $level "</div>";
            
$ret .= "</div>";
            if(
$req == "solarModule")
                
$ret .= "<div class=\"module_info_power_usage module_infobox_info\">" $prod "</div>";
            else
                
$ret .= "<div class=\"module_info_power_usage module_infobox_info\">" $eusage "</div>";
            if(
$type == "refinery"){
                
$ret .= "  <div class=\"module_info_efficiency module_infobox_info\">" $efficiency " %</div>";
            }
            
$ret .= "</div>";
        }
        return 
$ret;
    }

    public function 
getAllData()
    {
        if(isset(
$_SESSION['server1']['user']['sessionId'], $_SESSION['server1']['user']['email']) && is_numeric($_SESSION['server1']['user']['sessionId'])){
            
//if(self::initSkylab()) {
                
$Skylab['ressources']['prometium']['count'] = $this->ressources_array['prometium'];
                
$Skylab['ressources']['endurium']['count'] = $this->ressources_array['endurium'];
                
$Skylab['ressources']['terbium']['count'] = $this->ressources_array['terbium'];
                
$Skylab['ressources']['prometid']['count'] = $this->ressources_array['prometid'];
                
$Skylab['ressources']['duranium']['count'] = $this->ressources_array['duranium'];
                
$Skylab['ressources']['xenomit']['count'] = $this->ressources_array['xenomit'];
                
$Skylab['ressources']['promerium']['count'] = $this->ressources_array['promerium'];
                
$Skylab['ressources']['seprom']['count'] = $this->ressources_array['seprom'];

                
$Skylab['ressources']['prometium']['max_storage'] = self::storage('raw'$this->mod_store['level']);
                
$Skylab['ressources']['endurium']['max_storage'] = self::storage('raw'$this->mod_store['level']);
                
$Skylab['ressources']['terbium']['max_storage'] = self::storage('raw'$this->mod_store['level']);
                
$Skylab['ressources']['prometid']['max_storage'] = self::storage('refined'$this->mod_store['level']);
                
$Skylab['ressources']['duranium']['max_storage'] = self::storage('refined'$this->mod_store['level']);
                
$Skylab['ressources']['xenomit']['max_storage'] = self::storage('proxeno'$this->mod_store['level']);
                
$Skylab['ressources']['promerium']['max_storage'] = self::storage('proxeno'$this->mod_store['level']);
                
$Skylab['ressources']['seprom']['max_storage'] = self::storage('seprom'$this->mod_store['level']);

                
$Skylab['ressources']['prometium']['perc'] = number_format(100*$Skylab['ressources']['prometium']['count']/$Skylab['ressources']['prometium']['max_storage'], 0'''');
                
$Skylab['ressources']['endurium']['perc'] = number_format(100*$Skylab['ressources']['endurium']['count']/$Skylab['ressources']['endurium']['max_storage'], 0'''');
                
$Skylab['ressources']['terbium']['perc'] = number_format(100*$Skylab['ressources']['terbium']['count']/$Skylab['ressources']['terbium']['max_storage'], 0'''');
                
$Skylab['ressources']['prometid']['perc'] = number_format(100*$Skylab['ressources']['prometid']['count']/$Skylab['ressources']['prometid']['max_storage'], 0'''');
                
$Skylab['ressources']['duranium']['perc'] = number_format(100*$Skylab['ressources']['duranium']['count']/$Skylab['ressources']['duranium']['max_storage'], 0'''');
                
$Skylab['ressources']['xenomit']['perc'] = number_format(100*$Skylab['ressources']['xenomit']['count']/$Skylab['ressources']['xenomit']['max_storage'], 0'''');
                
$Skylab['ressources']['promerium']['perc'] = number_format(100*$Skylab['ressources']['promerium']['count']/$Skylab['ressources']['promerium']['max_storage'], 0'''');
                
$Skylab['ressources']['seprom']['perc'] = number_format(100*$Skylab['ressources']['seprom']['count']/$Skylab['ressources']['seprom']['max_storage'], 0'''');
                
                
                
$Skylab['modules']['mod_basic']['name'] = "Basic module";
                
$Skylab['modules']['mod_basic']['progressbar'] = (int) 3*$this->mod_basic['level'];
                
$Skylab['modules']['mod_basic']['level'] = $this->mod_basic['level'];
                if(
$this->mod_basic['level'] > 0) {
                    
$Skylab['modules']['mod_basic']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['mod_basic']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['mod_basic']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['mod_basic']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['mod_basic']['energyusage'] = self::energy_usage($this->mod_basic['level']);
                
$Skylab['modules']['mod_basic']['cost_raw'] = self::upgrade_cost('basic','cost_raw',$this->mod_basic['level']);
                
$Skylab['modules']['mod_basic']['cost_cre'] = self::upgrade_cost('basic','cost_cre',$this->mod_basic['level']);
                
$Skylab['modules']['mod_basic']['cost_uri'] = self::upgrade_cost('basic','cost_uri',$this->mod_basic['level']);
                
############################################################
                
$Skylab['modules']['mod_store']['name'] = "Storage module";
                
$Skylab['modules']['mod_store']['progressbar'] = (int) 3*$this->mod_store['level'];
                
$Skylab['modules']['mod_store']['level'] = $this->mod_store['level'];
                if(
$this->mod_store['level'] > 0) {
                    
$Skylab['modules']['mod_store']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['mod_store']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['mod_store']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['mod_store']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['mod_store']['energyusage'] = self::energy_usage($this->mod_store['level']);
                
$Skylab['modules']['mod_store']['cost_raw'] = self::upgrade_cost('store','cost_raw',$this->mod_store['level']);
                
$Skylab['modules']['mod_store']['cost_cre'] = self::upgrade_cost('store','cost_cre',$this->mod_store['level']);
                
$Skylab['modules']['mod_store']['cost_uri'] = self::upgrade_cost('store','cost_uri',$this->mod_store['level']);
                
############################################################
                
$Skylab['modules']['mod_solar']['name'] = "Solar module";
                
$Skylab['modules']['mod_solar']['progressbar'] = (int) 3*$this->mod_solar['level'];
                
$Skylab['modules']['mod_solar']['level'] = $this->mod_solar['level'];
                if(
$this->mod_solar['level'] > 0) {
                    
$Skylab['modules']['mod_solar']['sd_status'] = "ACTIVE";
                } else {
                    
$Skylab['modules']['mod_solar']['sd_status'] = "INACTIVE";
                }
                
$Skylab['modules']['mod_solar']['energy_all_usage'] = self::energy_all_usage();
                
$Skylab['modules']['mod_solar']['energy_production'] = self::energy_production($this->mod_solar['level']);
                
$Skylab['modules']['mod_solar']['cost_raw'] = self::upgrade_cost('solar','cost_raw',$this->mod_solar['level']);
                
$Skylab['modules']['mod_solar']['cost_cre'] = self::upgrade_cost('solar','cost_cre',$this->mod_solar['level']);
                
$Skylab['modules']['mod_solar']['cost_uri'] = self::upgrade_cost('solar','cost_uri',$this->mod_solar['level']);
                
############################################################
                
$Skylab['modules']['collector_prometium']['name'] = "Prometium collector";
                
$Skylab['modules']['collector_prometium']['progressbar'] = (int) 3*$this->collector_prometium['level'];
                
$Skylab['modules']['collector_prometium']['level'] = $this->collector_prometium['level'];
                if(
$this->collector_prometium['level'] > 0) {
                    
$Skylab['modules']['collector_prometium']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['collector_prometium']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['collector_prometium']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['collector_prometium']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['collector_prometium']['energyusage'] = self::energy_usage($this->collector_prometium['level']);
                
$Skylab['modules']['collector_prometium']['cost_raw'] = self::upgrade_cost('collectors','cost_raw',$this->collector_prometium['level']);
                
$Skylab['modules']['collector_prometium']['cost_cre'] = self::upgrade_cost('collectors','cost_cre',$this->collector_prometium['level']);
                
$Skylab['modules']['collector_prometium']['cost_uri'] = self::upgrade_cost('collectors','cost_uri',$this->collector_prometium['level']);
                
############################################################
                
$Skylab['modules']['collector_endurium']['name'] = "Endurium collector";
                
$Skylab['modules']['collector_endurium']['progressbar'] = (int) 3*$this->collector_endurium['level'];
                
$Skylab['modules']['collector_endurium']['level'] = $this->collector_endurium['level'];
                if(
$this->collector_endurium['level'] > 0) {
                    
$Skylab['modules']['collector_endurium']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['collector_endurium']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['collector_endurium']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['collector_endurium']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['collector_endurium']['energyusage'] = self::energy_usage($this->collector_endurium['level']);
                
$Skylab['modules']['collector_endurium']['cost_raw'] = self::upgrade_cost('collectors','cost_raw',$this->collector_endurium['level']);
                
$Skylab['modules']['collector_endurium']['cost_cre'] = self::upgrade_cost('collectors','cost_cre',$this->collector_endurium['level']);
                
$Skylab['modules']['collector_endurium']['cost_uri'] = self::upgrade_cost('collectors','cost_uri',$this->collector_endurium['level']);
                
############################################################
                
$Skylab['modules']['collector_terbium']['name'] = "Terbium collector";
                
$Skylab['modules']['collector_terbium']['progressbar'] = (int) 3*$this->collector_terbium['level'];
                
$Skylab['modules']['collector_terbium']['level'] = $this->collector_terbium['level'];
                if(
$this->collector_terbium['level'] > 0) {
                    
$Skylab['modules']['collector_terbium']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['collector_terbium']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['collector_terbium']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['collector_terbium']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['collector_terbium']['energyusage'] = self::energy_usage($this->collector_terbium['level']);
                
$Skylab['modules']['collector_terbium']['cost_raw'] = self::upgrade_cost('collectors','cost_raw',$this->collector_terbium['level']);
                
$Skylab['modules']['collector_terbium']['cost_cre'] = self::upgrade_cost('collectors','cost_cre',$this->collector_terbium['level']);
                
$Skylab['modules']['collector_terbium']['cost_uri'] = self::upgrade_cost('collectors','cost_uri',$this->collector_terbium['level']);
                
############################################################
                
$Skylab['modules']['refine_prometid']['name'] = "Prometid refinery";
                
$Skylab['modules']['refine_prometid']['progressbar'] = (int) 3*$this->refine_prometid['level'];
                
$Skylab['modules']['refine_prometid']['level'] = $this->refine_prometid['level'];
                if(
$this->refine_prometid['level'] > 0) {
                    
$Skylab['modules']['refine_prometid']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['refine_prometid']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['refine_prometid']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['refine_prometid']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['refine_prometid']['energyusage'] = self::energy_usage($this->refine_prometid['level']);
                
$Skylab['modules']['refine_prometid']['cost_raw'] = self::upgrade_cost('refine','cost_raw',$this->refine_prometid['level']);
                
$Skylab['modules']['refine_prometid']['cost_cre'] = self::upgrade_cost('refine','cost_cre',$this->refine_prometid['level']);
                
$Skylab['modules']['refine_prometid']['cost_uri'] = self::upgrade_cost('refine','cost_uri',$this->refine_prometid['level']);
                
############################################################
                
$Skylab['modules']['refine_duranium']['name'] = "Duranium refinery";
                
$Skylab['modules']['refine_duranium']['progressbar'] = (int) 3*$this->refine_duranium['level'];
                
$Skylab['modules']['refine_duranium']['level'] = $this->refine_duranium['level'];
                if(
$this->refine_duranium['level'] > 0) {
                    
$Skylab['modules']['refine_duranium']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['refine_duranium']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['refine_duranium']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['refine_duranium']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['refine_duranium']['energyusage'] = self::energy_usage($this->refine_duranium['level']);
                
$Skylab['modules']['refine_duranium']['cost_raw'] = self::upgrade_cost('refine','cost_raw',$this->refine_duranium['level']);
                
$Skylab['modules']['refine_duranium']['cost_cre'] = self::upgrade_cost('refine','cost_cre',$this->refine_duranium['level']);
                
$Skylab['modules']['refine_duranium']['cost_uri'] = self::upgrade_cost('refine','cost_uri',$this->refine_duranium['level']);
                
############################################################
                
$Skylab['modules']['refine_promerium']['name'] = "Promerium refinery";
                
$Skylab['modules']['refine_promerium']['progressbar'] = (int) 3*$this->refine_promerium['level'];
                
$Skylab['modules']['refine_promerium']['level'] = $this->refine_promerium['level'];
                if(
$this->refine_promerium['level'] > 0) {
                    
$Skylab['modules']['refine_promerium']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['refine_promerium']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['refine_promerium']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['refine_promerium']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['refine_promerium']['energyusage'] = self::energy_usage($this->refine_promerium['level']);
                
$Skylab['modules']['refine_promerium']['cost_raw'] = self::upgrade_cost('refine','cost_raw',$this->refine_promerium['level']);
                
$Skylab['modules']['refine_promerium']['cost_cre'] = self::upgrade_cost('refine','cost_cre',$this->refine_promerium['level']);
                
$Skylab['modules']['refine_promerium']['cost_uri'] = self::upgrade_cost('refine','cost_uri',$this->refine_promerium['level']);
                
############################################################
                
$Skylab['modules']['refine_seprom']['name'] = "Seprom refinery";
                
$Skylab['modules']['refine_seprom']['progressbar'] = (int) 3*$this->refine_seprom['level'];
                
$Skylab['modules']['refine_seprom']['level'] = $this->refine_seprom['level'];
                if(
$this->refine_seprom['level'] > 0) {
                    
$Skylab['modules']['refine_seprom']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['refine_seprom']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['refine_seprom']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['refine_seprom']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['refine_seprom']['energyusage'] = self::energy_usage($this->refine_seprom['level']);
                
$Skylab['modules']['refine_seprom']['cost_raw'] = self::upgrade_cost('refine_sep','cost_raw',$this->refine_seprom['level']);
                
$Skylab['modules']['refine_seprom']['cost_cre'] = self::upgrade_cost('refine_sep','cost_cre',$this->refine_seprom['level']);
                
$Skylab['modules']['refine_seprom']['cost_uri'] = self::upgrade_cost('refine_sep','cost_uri',$this->refine_seprom['level']);
                
############################################################
                
$Skylab['modules']['generator_xeno']['name'] = "Xeno module";
                
$Skylab['modules']['generator_xeno']['progressbar'] = (int) 3*$this->generator_xeno['level'];
                
$Skylab['modules']['generator_xeno']['level'] = $this->generator_xeno['level'];
                if(
$this->generator_xeno['level'] > 0) {
                    
$Skylab['modules']['generator_xeno']['sd_status'] = "ACTIVE";
                    
$Skylab['modules']['generator_xeno']['solarinfo'] = "";
                } else {
                    
$Skylab['modules']['generator_xeno']['sd_status'] = "INACTIVE";
                    
$Skylab['modules']['generator_xeno']['solarinfo'] = "inactive";
                }
                
$Skylab['modules']['generator_xeno']['energyusage'] = self::energy_usage($this->generator_xeno['level']);
                
$Skylab['modules']['generator_xeno']['cost_raw'] = self::upgrade_cost('generator','cost_raw',$this->generator_xeno['level']);
                
$Skylab['modules']['generator_xeno']['cost_cre'] = self::upgrade_cost('generator','cost_cre',$this->generator_xeno['level']);
                
$Skylab['modules']['generator_xeno']['cost_uri'] = self::upgrade_cost('generator','cost_uri',$this->generator_xeno['level']);
                
                
                
$this->site_data $Skylab;
            
//}
        
}
    }

    private function 
energy_production($level)
    {
        
$energy = array (    "0",
                            
"270",
                            
"310",
                            
"370",
                            
"450",
                            
"550",
                            
"670",
                            
"810",
                            
"970",
                            
"1150",
                            
"1350",
                            
"1570",
                            
"1810",
                            
"2070",
                            
"2350",
                            
"2650",
                            
"2970",
                            
"3310",
                            
"3670",
                            
"4050",
                            
"4450"
                            
);
        return 
$energy[$level];
    }

    private function 
ressource_generation($type,$level)
    {
        
$gen = array (    
                    
"raw" => array ( "0",
                                        
"2200",//1
                                        
"7400",
                                        
"15045",
                                        
"24890",
                                        
"36782",
                                        
"50604",
                                        
"66274",
                                        
"83720",
                                        
"102884",
                                        
"123715",//10
                                        
"146171",
                                        
"170212",
                                        
"195805",
                                        
"222919",
                                        
"251526",
                                        
"281600",
                                        
"313118",
                                        
"346059",
                                        
"380401",
                                        
"416216"),
                                        
                    
"refined" => array( "0",
                                        
"110",//1
                                        
"370",
                                        
"752",
                                        
"1245",
                                        
"1839",
                                        
"2530",
                                        
"3314",
                                        
"4186",
                                        
"5144",
                                        
"6186",//10
                                        
"7309",
                                        
"8511",
                                        
"9790",
                                        
"11146",
                                        
"12013",
                                        
"14080",
                                        
"15656",
                                        
"17303",
                                        
"19020",
                                        
"20806"),
                    
"proxeno" => array( "0",
                                        
"11",//1
                                        
"37",
                                        
"75",
                                        
"124",
                                        
"184",
                                        
"253",
                                        
"331",
                                        
"419",
                                        
"514",
                                        
"619",//10
                                        
"731",
                                        
"851",
                                        
"979",
                                        
"1115",
                                        
"1258",
                                        
"1408",
                                        
"1566",
                                        
"1730",
                                        
"1902",
                                        
"2081"),//20
                    
"seprom" => array( "0"//0
                                        
"1",
                                        
"3",
                                        
"7",
                                        
"11",
                                        
"17",
                                        
"23",
                                        
"30",
                                        
"38",
                                        
"47",
                                        
"56"//10
                                        
"66",
                                        
"77",
                                        
"89",
                                        
"101",
                                        
"114",
                                        
"128",
                                        
"142",
                                        
"157",
                                        
"173",
                                        
"189"), //20
                        
);
        return 
$gen[$type][$level];
    }
    
    private function 
energy_usage($level)
    {
        
$energy = array (    "0",
                            
"16",
                            
"19",
                            
"24",
                            
"31",
                            
"40",
                            
"51",
                            
"64",
                            
"79",
                            
"96",
                            
"115",
                            
"136",
                            
"159",
                            
"184",
                            
"211",
                            
"240",
                            
"271",
                            
"304",
                            
"339",
                            
"376",
                            
"415"
                            
);
        return 
$energy[$level];
    }

    private function 
energy_all_usage()
    {
        
$v01 self::energy_usage($this->mod_basic['level']);
        
$v02 self::energy_usage($this->mod_store['level']);
        
$v03 = ($this->collector_prometium['status'] == 1) ? self::energy_usage($this->collector_prometium['level']) : 0;
        
$v04 = ($this->collector_endurium['status'] == 1) ? self::energy_usage($this->collector_endurium['level']) : 0;
        
$v05 = ($this->collector_terbium['status'] == 1) ? self::energy_usage($this->collector_terbium['level']) : 0;
        
$v06 = ($this->refine_prometid['status'] == 1) ? self::energy_usage($this->refine_prometid['level']) : 0;
        
$v07 = ($this->refine_duranium['status'] == 1) ? self::energy_usage($this->refine_duranium['level']) : 0;
        
$v08 = ($this->refine_promerium['status'] == 1) ? self::energy_usage($this->refine_promerium['level']) : 0;
        
$v09 = ($this->refine_seprom['status'] == 1) ? self::energy_usage($this->refine_seprom['level']) : 0;
        
$v10 = ($this->generator_xeno['status'] == 1) ? self::energy_usage($this->generator_xeno['level']) : 0;
        
$energy $v01+$v02+$v03+$v04+$v05+$v06+$v07+$v08+$v09+$v10;
        return 
$energy+16;  // +16 for transport module
    
}

    private function 
storage($type,$level)
    {
        
$storage = array(
                    
"raw" => array ( "0",
                                        
"105600",
                                        
"355195",
                                        
"722148",
                                        
"1194728",
                                        
"1765474",
                                        
"2429006",
                                        
"3181160",
                                        
"4018569",
                                        
"4938423",
                                        
"5938324",
                                        
"7016186",
                                        
"8170170",
                                        
"9398635",
                                        
"10700104",
                                        
"12073234",
                                        
"13516800",
                                        
"15029673",
                                        
"16610810",
                                        
"18259241",
                                        
"19974063"),
                    
"refined" => array( "0",
                                        
"5280",
                                        
"17760",
                                        
"36107",
                                        
"59736",
                                        
"88274",
                                        
"121450",
                                        
"159058",
                                        
"200928",
                                        
"246921",
                                        
"296916",
                                        
"350809",
                                        
"408509",
                                        
"469932",
                                        
"535005",
                                        
"603662",
                                        
"675840",
                                        
"751484",
                                        
"830540",
                                        
"912962",
                                        
"998703"),
                    
"proxeno" => array( "0",
                                        
" 528",
                                        
"1776",
                                        
"3611",
                                        
"5974",
                                        
"8827",
                                        
"12145",
                                        
"15906",
                                        
"20093",
                                        
"24692",
                                        
"29692",
                                        
"35081",
                                        
"40851",
                                        
"46993",
                                        
"53501",
                                        
"60366",
                                        
"67584",
                                        
"75148",
                                        
"83054",
                                        
"91296",
                                        
"99870"),
                    
"seprom" => array( "0",
                                        
"48",
                                        
"161",
                                        
"328",
                                        
"543",
                                        
"802",
                                        
"1104",
                                        
"1446",
                                        
"1827",
                                        
"2245",
                                        
"2699",
                                        
"3189",
                                        
"3714",
                                        
"4272",
                                        
"4864",
                                        
"5488",
                                        
"6144",
                                        
"6832",
                                        
"7550",
                                        
"8300",
                                        
"9079"),
                        );
        return 
$storage[$type][$level];
    }

    
/*
        // switched to easier system to handle this
        // priority: rework
    private function pretty_time($tins)
    {
        return floor($sec/60)."min:".($sec%60)."secs";
    }*/

    
private function upgrade_time($type,$level)
    {
        
//t in s econds
        
$tinsarr = array(
                    
"basic" => array(    "0"//0
                                        
"3600",
                                        
"14400",
                                        
"28800",
                                        
"43200",
                                        
"57600",
                                        
"72000",
                                        
"86400",
                                        
"100800",
                                        
"115200",
                                        
"129600",//10
                                        
"144000",
                                        
"158400",
                                        
"172800",
                                        
"187200",
                                        
"201600",
                                        
"216000",
                                        
"230400",
                                        
"244800",
                                        
"259200",
                                        
"273600"),//20
                    
"collectors" => array(    "0",
                                        
"3600",
                                        
"14400",
                                        
"28800",
                                        
"43200",
                                        
"57600",
                                        
"72000",
                                        
"86400",
                                        
"100800",
                                        
"115200",
                                        
"129600",
                                        
"144000",
                                        
"158400",
                                        
"172800",
                                        
"187200",
                                        
"201600",
                                        
"216000",
                                        
"230400",
                                        
"244800",
                                        
"259200",
                                        
"273600"),
                    
"refine" => array(    "0",
                                        
"3600",
                                        
"18000",
                                        
"36000",
                                        
"54000",
                                        
"72000",
                                        
"90000",
                                        
"108000",
                                        
"126000",
                                        
"144000",
                                        
"180000",
                                        
"198000",
                                        
"216000",
                                        
"234000",
                                        
"252000",
                                        
"270000",
                                        
"288000",
                                        
"306000",
                                        
"324000",
                                        
"342000",
                                        
"360000"),
                    
"seprom" => array(    "0",
                                        
"3600",
                                        
"21600",
                                        
"43200",
                                        
"64800",
                                        
"86400",
                                        
"108000",
                                        
"129600",
                                        
"151200",
                                        
"172800",
                                        
"194400",
                                        
"216000",
                                        
"237600",
                                        
"259200",
                                        
"280800",
                                        
"302400",
                                        
"324000",
                                        
"345600",
                                        
"367200",
                                        
"388800",
                                        
"410400"),
                        );
        return 
$tinsarr[$type][$level];
    }

    private function 
upgrade_cost($type,$costtype,$level)
    {
        
$cost = array(
                    
"basic" => array( "cost_raw" => array ( "0",
                                                            
"707",
                                                            
"2923",
                                                            
"8000",
                                                            
"17469",
                                                            
"33068",
                                                            
"56718",
                                                            
"90510",
                                                            
"136688",
                                                            
"197642",
                                                            
"275902",
                                                            
"374123",
                                                            
"495087",
                                                            
"641694",
                                                            
"816957",
                                                            
"1024000",
                                                            
"1266051",
                                                            
"1546443",
                                                            
"1868605",
                                                            
"2236068",
                                                            
"3236068"),
                                      
"cost_cre" => array ( "0",
                                                            
"16352",
                                                            
"27144",
                                                            
"38891",
                                                            
"51403",
                                                            
"64560",
                                                            
"78279",
                                                            
"92499",
                                                            
"107171",
                                                            
"122257",
                                                            
"137725",
                                                            
"153550",
                                                            
"169708",
                                                            
"186180",
                                                            
"202949",
                                                            
"220000",
                                                            
"237320",
                                                            
"254896",
                                                            
"272719",
                                                            
"290777",
                                                            
"300000"),
                                      
"cost_uri" => array ( "0",
                                                            
"1487",
                                                            
"2468",
                                                            
"3536",
                                                            
"4673",
                                                            
"5869",
                                                            
"7116",
                                                            
"8409",
                                                            
"9743",
                                                            
"11114",
                                                            
"12520",
                                                            
"13959",
                                                            
"15428",
                                                            
"16925",
                                                            
"18450",
                                                            
"20000",
                                                            
"21575",
                                                            
"23172",
                                                            
"24793",
                                                            
"26434",
                                                            
"30000"),
                                    ),
                    
"store" => array( "cost_raw" => array ( "0",
                                                            
"707",
                                                            
"2923",
                                                            
"8000",
                                                            
"17469",
                                                            
"33068",
                                                            
"56718",
                                                            
"90510",
                                                            
"136688",
                                                            
"197642",
                                                            
"275902",
                                                            
"374123",
                                                            
"495087",
                                                            
"641694",
                                                            
"816957",
                                                            
"1024000",
                                                            
"1266051",
                                                            
"1546443",
                                                            
"1868605",
                                                            
"2236068",
                                                            
"3000000"),
                                      
"cost_cre" => array ( "0",
                                                            
"16352",
                                                            
"27144",
                                                            
"38891",
                                                            
"51403",
                                                            
"64560",
                                                            
"78279",
                                                            
"92499",
                                                            
"107171",
                                                            
"122257",
                                                            
"137725",
                                                            
"153550",
                                                            
"169708",
                                                            
"186180",
                                                            
"202949",
                                                            
"220000",
                                                            
"237320",
                                                            
"254896",
                                                            
"272719",
                                                            
"290777",
                                                            
"300000"),
                                      
"cost_uri" => array ( "0",
                                                            
"1487",
                                                            
"2468",
                                                            
"3536",
                                                            
"4673",
                                                            
"5869",
                                                            
"7116",
                                                            
"8409",
                                                            
"9743",
                                                            
"11114",
                                                            
"12520",
                                                            
"13959",
                                                            
"15428",
                                                            
"16925",
                                                            
"18450",
                                                            
"20000",
                                                            
"21575",
                                                            
"23172",
                                                            
"24793",
                                                            
"26434",
                                                            
"30000"),
                                    ),
                    
"solar" => array( "cost_raw" => array ( "0",
                                                            
"707",
                                                            
"2923",
                                                            
"8000",
                                                            
"17469",
                                                            
"33068",
                                                            
"56718",
                                                            
"90510",
                                                            
"136688",
                                                            
"197642",
                                                            
"275902",
                                                            
"374123",
                                                            
"495087",
                                                            
"641694",
                                                            
"816957",
                                                            
"1024000",
                                                            
"1266051",
                                                            
"1546443",
                                                            
"1868605",
                                                            
"2236068",
                                                            
"2400000"),
                                      
"cost_cre" => array ( "0",
                                                            
"16352",
                                                            
"27144",
                                                            
"38891",
                                                            
"51403",
                                                            
"64560",
                                                            
"78279",
                                                            
"92499",
                                                            
"107171",
                                                            
"122257",
                                                            
"137725",
                                                            
"153550",
                                                            
"169708",
                                                            
"186180",
                                                            
"202949",
                                                            
"220000",
                                                            
"237320",
                                                            
"254896",
                                                            
"272719",
                                                            
"290777",
                                                            
"300000"),
                                      
"cost_uri" => array ( "0",
                                                            
"1487",
                                                            
"2468",
                                                            
"3536",
                                                            
"4673",
                                                            
"5869",
                                                            
"7116",
                                                            
"8409",
                                                            
"9743",
                                                            
"11114",
                                                            
"12520",
                                                            
"13959",
                                                            
"15428",
                                                            
"16925",
                                                            
"18450",
                                                            
"20000",
                                                            
"21575",
                                                            
"23172",
                                                            
"24793",
                                                            
"26434",
                                                            
"30000"),
                                    ),
                    
"collectors" => array( "cost_raw" => array ( "0",
                                                                
"50",
                                                                
"566",
                                                                
"2338",
                                                                
"6400",
                                                                
"13975",
                                                                
"26454",
                                                                
"45375",
                                                                
"72408",
                                                                
"109350",
                                                                
"158114",
                                                                
"220721",
                                                                
"299298",
                                                                
"396070",
                                                                
"513355",
                                                                
"653566",
                                                                
"819200",
                                                                
"1012841",
                                                                
"1237154",
                                                                
"1494884",
                                                                
"1788854"),
                                          
"cost_cre" => array ( "0",
                                                                
"5500",
                                                                
"13081",
                                                                
"21715",
                                                                
"31113",
                                                                
"41122",
                                                                
"51648",
                                                                
"62623",
                                                                
"73999",
                                                                
"85737",
                                                                
"97805",
                                                                
"110180",
                                                                
"122840",
                                                                
"135766",
                                                                
"148944",
                                                                
"162359",
                                                                
"176000",
                                                                
"189856",
                                                                
"203917",
                                                                
"218175",
                                                                
"232622"),
                                          
"cost_uri" => array ( "0",
                                                                
"500",
                                                                
"1189",
                                                                
"1974",
                                                                
"2828",
                                                                
"3738",
                                                                
"4695",
                                                                
"5693",
                                                                
"6727",
                                                                
"7794",
                                                                
"8891",
                                                                
"10016",
                                                                
"11167",
                                                                
"12342",
                                                                
"13540",
                                                                
"14760",
                                                                
"16000",
                                                                
"17260",
                                                                
"18538",
                                                                
"19834",
                                                                
"21147"),
                                    ),
                    
"refine" => array( "cost_raw" => array ( "0",
                                                            
"75",
                                                            
"849",
                                                            
"3507",
                                                            
"9600",
                                                            
"20963",
                                                            
"39682",
                                                            
"68062",
                                                            
"108612",
                                                            
"164025",
                                                            
"237171",
                                                            
"331082",
                                                            
"448948",
                                                            
"594205",
                                                            
"770033",
                                                            
"980349",
                                                            
"1228800",
                                                            
"1519261",
                                                            
"1855731",
                                                            
"2242327",
                                                            
"2683282"),
                                        
"cost_cre" => array( "0",
                                                            
"8250",
                                                            
"19622",
                                                            
"32573",
                                                            
"46669",
                                                            
"61683",
                                                            
"77472",
                                                            
"93935",
                                                            
"110998",
                                                            
"128605",
                                                            
"146708",
                                                            
"165270",
                                                            
"184260",
                                                            
"203649",
                                                            
"223416",
                                                            
"243539",
                                                            
"264000",
                                                            
"284784",
                                                            
"305875",
                                                            
"327262",
                                                            
"348933"),
                                        
"cost_uri" => array( "0",
                                                            
"750",
                                                            
"1784",
                                                            
"2961",
                                                            
"4243",
                                                            
"5608",
                                                            
"7043",
                                                            
"8540",
                                                            
"10091",
                                                            
"11691",
                                                            
"13337",
                                                            
"15025",
                                                            
"16751",
                                                            
"18514",
                                                            
"20311",
                                                            
"22140",
                                                            
"24000",
                                                            
"25889",
                                                            
"27807",
                                                            
"29751",
                                                            
"31721"),
                                    ),
                    
"refine_sep" => array( "cost_raw" => array ( "0",
                                                                
"250",
                                                                
"2828",
                                                                
"11691",
                                                                
"32000",
                                                                
"69877",
                                                                
"132271",
                                                                
"226873",
                                                                
"362039",
                                                                
"546750",
                                                                
"790569",
                                                                
"1103607",
                                                                
"1496492",
                                                                
"1980349",
                                                                
"2566777",
                                                                
"3267830",
                                                                
"4096000",
                                                                
"5064204",
                                                                
"6185770",
                                                                
"7474422",
                                                                
"8944272"),
                                            
"cost_cre" => array( "0",
                                                                
"27500",
                                                                
"65406",
                                                                
"108576",
                                                                
"155563",
                                                                
"205610",
                                                                
"258239",
                                                                
"313116",
                                                                
"369994",
                                                                
"428683",
                                                                
"489027",
                                                                
"550901",
                                                                
"614199",
                                                                
"678831",
                                                                
"744720",
                                                                
"811796",
                                                                
"880000",
                                                                
"949279",
                                                                
"1019585",
                                                                
"1090874",
                                                                
"1163108"),
                                            
"cost_uri" => array( "0",
                                                                
"2500",
                                                                
"5946",
                                                                
"9871",
                                                                
"14142",
                                                                
"18692",
                                                                
"23476",
                                                                
"28465",
                                                                
"33636",
                                                                
"38971",
                                                                
"44457",
                                                                
"50082",
                                                                
"55836",
                                                                
"61712",
                                                                
"67702",
                                                                
"73800",
                                                                
"80000",
                                                                
"86298",
                                                                
"92690",
                                                                
"99170",
                                                                
"105737"),
                                    ),
                    
"generator" => array( "cost_raw" => array ( "0",
                                                            
"75",
                                                            
"849",
                                                            
"3507",
                                                            
"9600",
                                                            
"20963",
                                                            
"39682",
                                                            
"68062",
                                                            
"108612",
                                                            
"164025",
                                                            
"237171",
                                                            
"331082",
                                                            
"448948",
                                                            
"594205",
                                                            
"770033",
                                                            
"980349",
                                                            
"1228800",
                                                            
"1519261",
                                                            
"1855731",
                                                            
"2242327",
                                                            
"2683282"),
                                        
"cost_cre" => array( "0",
                                                            
"8250",
                                                            
"19622",
                                                            
"32573",
                                                            
"46669",
                                                            
"61683",
                                                            
"77472",
                                                            
"93935",
                                                            
"110998",
                                                            
"128605",
                                                            
"146708",
                                                            
"165270",
                                                            
"184260",
                                                            
"203649",
                                                            
"223416",
                                                            
"243539",
                                                            
"264000",
                                                            
"284784",
                                                            
"305875",
                                                            
"327262",
                                                            
"348933"),
                                        
"cost_uri" => array( "0",
                                                            
"750",
                                                            
"1784",
                                                            
"2961",
                                                            
"4243",
                                                            
"5608",
                                                            
"7043",
                                                            
"8540",
                                                            
"10091",
                                                            
"11691",
                                                            
"13337",
                                                            
"15025",
                                                            
"16751",
                                                            
"18514",
                                                            
"20311",
                                                            
"22140",
                                                            
"24000",
                                                            
"25889",
                                                            
"27807",
                                                            
"29751",
                                                            
"31721"),
                                    ),
);
        return 
$cost[$type][$costtype][$level];
    }
}
?>
UND3RW0RLD is offline  
Old 11/21/2014, 01:17   #1192
 
UND3RW0RLD's Avatar
 
elite*gold: 1
Join Date: Jun 2011
Posts: 1,464
Received Thanks: 1,065
Frontend
PHP Code:
<?php

/*if(isset($_POST['subAction']) && $_POST['subAction']=="addShipToHangar"){
    $base->changeShip($_POST['hangarId'], $_POST['inventoryId']);
}*/

// set id
// $Skylab->setId($Users->DataRow['ID']);

// init the thingy
//$Skylab->initSkylab();
$Skylab->ressupdate("update");
$Lab $Skylab->getSiteData();

?>

<script language="javascript" type="text/javascript" src="./js/skylab.js"></script>
</head>
<body onLoad="" >

<!-- /////////////////////////////////////////////////////////////////////////////////// -->

<!-- affiliateStartTag -->


<script type="text/javascript">window.name = "do_webpage";</script>



<!.. user context info layer -->
<div id="userInfoLayer" style="display:none;position:absolute;z-index:100;"></div>
<!-- hangar context info layer -->
<div id="hangarInfoLayer" style="display:none;position:absolute;z-index:100;"></div>
<!-- clan info layer -->
<div id="clanInfoLayer" style="display:none;position:absolute;z-index:100;"></div>
<!-- seitenabdecker -->



<div id="generalInfoPopup" class="fliess13px-grey">
    <div class="popup_headcontainer">
        <a id="general_popup_close" class="popup_close" href="#" ></a>
    </div>
    <div id="general_popup_question" class="question">
        <img src="./do_img/global/popups/general/success_icon.png?__cv=7ea7548d2cb4149555faab27c783e500" id="general_popup_success" class="success" />
        <img src="./do_img/global/popups/general/error_icon.png?__cv=abbabc79fb0ffe608c13a681aa9db900" id="general_popup_error" class="error" />
        <p id="general_popup_question_text">this text will be replace on xajax call</p>
    </div>
    <div class="popup_contentcontainer">
        <div class="popup_footcontainer">
            <div id="general_popup_close_button" class="popup_close_button">
                <img src="http://www.elitepvpers.com/forum/do_img/global/text_tf.esg?l=en&s=12&t=ok&f=eurostyle_thea&color=white&bgcolor=grey" />
            </div>
        </div>
    </div>
</div>


<div id="busy_layer"></div>
<div id="instanceList"></div>
<div id="spinner" class="hidden"></div>


<!-- seitenabdecker -->

<style type="text/css" media="screen">    @import "./css/cdn/includeInfoLayer.css?__cv=a0a813df090fdb3002c3891307238000";</style>
<script type="text/javascript">
infoText = '';
icon = '';
</script>
<script type="text/javascript" src="./js/infoLayer.js?__cv=49d5cbe0b1125ad7d3c272d67c3f4d00"></script>

<div id="infoLayer" class="confirmInfoLayer fliess13px-grey">
    <div class="popup_shop_headcontainer">
        <a class="popup_shop_close" href="javascript: void(0);" onclick="closeInfoLayer()"></a>
    </div>
    <div class="popup_shop_contentcontainer">
        <br>
        <div class="question"></div>
        <div class="popup_shop_footcontainer">
            <div id="infoLayerConfirm">
                <div class="popup_shop_confirm_button">
                    <div id="infoLayer_link_confirm"
                         class="popup_shop_confirm_text"
                         style="background-image: url(
                            '../do_img/global/text_tf.esg?l=en&s=12&t=ok&f=eurostyle_thea&color=white&bgcolor=grey'
                         );">
                    </div>
                </div>
                <div class="popup_shop_abort_button">
                    <div class="popup_shop_abort_text"
                         style="background-image: url(
                            '../do_img/global/text_tf.esg?l=en&s=12&t=confirmBox_cancel&f=eurostyle_thea&color=white&bgcolor=grey'
                         );"
                         onclick="closeInfoLayer();">
                    </div>
                </div>
            </div>

            <div id="infoLayerInfo">
                <div class="popup_shop_close_button">
                    <div class="popup_shop_close_text"
                         style='background-image: url("../do_img/global/text_tf.esg?l=en&s=12&t=ok&f=eurostyle_thea&color=white&bgcolor=grey");'
                         onclick="closeInfoLayer();"></div>
                </div>
            </div>
        </div>
    </div>
</div>
<script type="text/javascript">
</script>
<?php require GLOBALS 'internalHelpLayer.php'; require GLOBALS 'internalNews.php'?>
                  
<div class="backgroundImageContainer" style="background-image: url(./do_img/global/bg_standard_vru.jpg?__cv=4aa3437fda694ce7dc5665697c466900)">
<div class="overallContainer">

<div class="outerContainer fliess11px-gelb">

        <?php require GLOBALS 'internalHeaderIntern.php'?>



<div class="bodyContainer">
    <div class="frameTop"></div>
    <div class="frameLeft_top"></div>
    <div class="frameRight_top"></div>
<div class="contentFrame">
<div class="realContainer">


                <style  type="text/css">

.tabLabelSkylabActive {
    background-image: url("text?t=SKYLAB&w=5&s=9&color=black&b=lightestBlue");
}
.tabLabelSkylabInActive {
    background-image: url(text?t=SKYLAB&w=5&s=9&color=white&b=grey);
}
.tabLabelTechFactoryActive {
    background-image: url("./text?t=TECH CENTER&w=9&s=9&color=black&b=lightestBlue");
}
.tabLabelTechFactoryInActive {
    background-image: url("text?t=TECH CENTER&w=9&s=9&color=white&b=grey");
}
.tabLabelItemUpgradeSystemActive {
    background-image: url("./text?t=ITEM UPGRADING&w=12&s=9&color=black&b=lightestBlue");
}
.tabLabelItemUpgradeSystemInActive {
    background-image: url("text?t=ITEM UPGRADING&w=12&s=9&color=white&b=grey");
}

</style>

<script language="javascript" type="text/javascript" src="./js/skylab.js?__cv=877e5fd9712d685bb42272356ba58100"></script>

<script language="javascript" type="text/javascript">
    currentTime = 1408480318;
    var rid = '1e1064a8fdf038ee6e4c99e2beab4d29';
</script>

<input type="hidden" id="videoAvailable" value="1" />
<input type="hidden" id="videoURL" value="https://api.tokenads.com/TAS/script.jsf?s=5132_0ea211feae7a0626d7064815d74d509d&a=87040&_token=6a6713a61f957ccab2a907b3380d10d2" />
<input type="hidden" id="videoSize" value="700x500" />
<style type="text/css">

    #brand_cinema_layer {
        position: fixed;
        top: 0;
        left: 0;
        background: #000000;
        color: #FFFFFF;
        z-index: 30;
        display: none;
    }

    #brand_cinema_hint {
        text-align: center;
        font-size: 10px;
        margin: 0 40px 10px;
        padding-top: 10px;
    }

    #brand_cinema_layer iframe {
        border: 1px solid #FFFFFF;
        margin: 10px auto 15px;
        display: block;
        border-left: 15px solid #000000;
        border-right: 15px solid #000000;
    }

    #brand_cinema_layer .close_button {
        position: absolute;
        top: 5px;
        right: 5px;
        cursor: pointer;
        width: 24px;
        height: 24px;
        background: url(./do_img/global/skylab/modules_large/close_button_sprite.png?__cv=fa1f7ef0f89ab04212dbf02f3424d700) no-repeat center -24px;
    }
    #brand_cinema_layer .close_button:hover {
        background-position: center 0;
    }

</style>

<div id="brand_cinema_layer">
    <div class="close_button" onclick="BrandCinema.closeVideoLayer()"></div>
    <div id="brand_cinema_hint">You have to watch the full video to get an incentive. Please disable your adblocker!</div>

    <iframe src="" height="300" width="300" scrolling="no" frameborder="0">
        Your browser does not support embedded frames.
    </iframe>
</div>

<script type="text/javascript" language="javascript">

    var BrandCinema = {
        iFrameWidth: 100,
        iFrameHeight: 100,
        iFrameUrl: '',

        openVideoLayer: function()
        {
            showBusyLayer();

            var layerElm = jQuery('#brand_cinema_layer');

            layerElm.show();

            // set up the iFrame
            var videoContent = jQuery('#brand_cinema_layer iframe');
            videoContent.attr('src', this.iFrameUrl);
            videoContent.attr('width', this.iFrameWidth);
            videoContent.attr('height', this.iFrameHeight);

            // center the layer relative to it's parent element
            bodyOffsetWidth     = document.documentElement.offsetWidth,
            objectWidth         = layerElm.width(),
        // Take the banner (and it's margin) on the right hand side into account
            widthWithBanner     = objectWidth + 120,
            objectLeft          = (bodyOffsetWidth / 2) - (widthWithBanner / 2),
            bodyOffsetHeight    = document.documentElement.offsetHeight,
            objectHeight        = layerElm.height(),
            objectTop           = (bodyOffsetHeight / 2) - (objectHeight / 2);

            layerElm.css({
                top     : objectTop  + 'px',
                left    : objectLeft + 'px'
            });
        },

        closeVideoLayer: function()
        {
//            hideBusyLayer();
//            jQuery('#brand_cinema_layer').hide();
            do_redirect('/indexInternal.es?action=internalSkylab');
        }
    };

</script>    
<div id="skylab">
    <?php echo $Skylab->displayBuild(); ?>
<div id="subnav">
    <div id="tabButton1" class="tabButtonActive"
        onmouseover="buttonHandler.toggleButtons('tabButton1', 'tabButton', 'tabLabel1', 'tabLabel')"
        onmouseout="buttonHandler.toggleButtons('tabButton1', 'tabButton', 'tabLabel1', 'tabLabel')"
        onclick="do_redirect('indexInternal.es?action=internalSkylab');"
        style='cursor: pointer; float: left; width: 184px; height: 25px;'>
        <div id="tabLabel1" class="tabLabelInActive tabLabelSkylabActive"></div>
    </div>
    <div id="tabButton2" class="tabButtonInActive"
        onmouseover="buttonHandler.toggleButtons('tabButton2', 'tabButton', 'tabLabel2', 'tabLabel')"
        onmouseout="buttonHandler.toggleButtons('tabButton2', 'tabButton', 'tabLabel2', 'tabLabel')"
        onclick="do_redirect('indexInternal.es?action=internalNanoTechFactory');"
        style='cursor: pointer; float: left; width: 184px; height: 25px;'>
        <div id="tabLabel2" class="tabLabelInActive tabLabelTechFactoryInActive"></div>
    </div>
        <div id="tabButton3" class="tabButtonInActive"
        onmouseover="buttonHandler.toggleButtons('tabButton3', 'tabButton', 'tabLabel3', 'tabLabel')"
        onmouseout="buttonHandler.toggleButtons('tabButton3', 'tabButton', 'tabLabel3', 'tabLabel')"
        onclick="do_redirect('indexInternal.es?action=internalItemUpgradeSystem');"
        style='cursor: pointer; float: left; width: 184px; height: 25px;'>
        <div id="tabLabel3" class="tabLabelInActive tabLabelItemUpgradeSystemInActive"></div>
    </div>
    </div>
    <div id="view_prometium" class="view_generally">
        <div id="view_prometium_stock">
            <span class="ore_prometium">Prometium:</span><br />
            <?php echo $Lab['ressources']['prometium']['count']; ?>
        </div>
        <div id="view_prometium_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['prometium']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['prometium']['max_storage']?></div>
        </div>
    </div>
    <div id="view_endurium" class="view_generally">
        <div id="view_endurium_stock">
            <span class="ore_endurium">Endurium:</span><br />
            <?php echo $Lab['ressources']['endurium']['count']; ?>
        </div>
        <div id="view_endurium_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['endurium']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['endurium']['max_storage']?></div>
        </div>
    </div>
    <div id="view_terbium" class="view_generally">
        <div id="view_terbium_stock">
            <span class="ore_terbium">Terbium:</span><br />
            <?php echo $Lab['ressources']['terbium']['count']; ?>
        </div>
        <div id="view_terbium_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['terbium']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['terbium']['max_storage']?></div>
        </div>
    </div>
    <div id="view_prometid" class="view_generally">
        <div id="view_prometid_stock">
            <span class="ore_prometid">Prometid:</span><br />
            <?php echo $Lab['ressources']['prometid']['count']; ?>
        </div>
        <div id="view_prometid_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['prometid']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['prometid']['max_storage']?></div>
        </div>
    </div>
    <div id="view_duranium" class="view_generally">
        <div id="view_duranium_stock">
            <span class="ore_duranium">Duranium:</span><br />
            <?php echo $Lab['ressources']['duranium']['count']; ?>
        </div>
        <div id="view_duranium_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['duranium']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['duranium']['max_storage']?></div>
        </div>
    </div>
    <div id="view_xenomit" class="view_generally">
        <div id="view_xenomit_stock">
            <span class="ore_xenomit">Xenomit:</span><br />
            <?php echo $Lab['ressources']['xenomit']['count']; ?>
        </div>
        <div id="view_xenomit_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['xenomit']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['xenomit']['max_storage']?></div>
        </div>
    </div>
    <div id="view_promerium" class="view_generally">
        <div id="view_promerium_stock">
            <span class="ore_promerium">Promerium:</span><br />
            <?php echo $Lab['ressources']['promerium']['count']; ?>
        </div>
        <div id="view_promerium_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['promerium']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_promerium_maximal_number"><?php echo $Lab['ressources']['promerium']['max_storage']?></div>
        </div>
    </div>
    <div id="view_seprom" class="view_generally">
        <div id="view_seprom_stock">
            <span class="ore_seprom">Seprom:</span><br />
            <?php echo $Lab['ressources']['seprom']['count']; ?>
        </div>
        <div id="view_seprom_maximal">
            <div class="view_generally_maximal_bg" style="width: <?php echo $Lab['ressources']['seprom']['perc']?>%;"></div>
            <div class="view_generally_maximal_number view_seprom_maximal_number"><?php echo $Lab['ressources']['seprom']['max_storage']?></div>
        </div>
    </div>


    <div id="skylabReloader" onclick="javascript: do_redirect('indexInternal.es?action=internalSkylab');"></div>
    <!--<div id="blueprint"></div>-->
        <div id="modules">

<?php echo $Skylab->showModule("baseModule","smallbox"); ?>

<div id="module_baseModule_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Basic module</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_baseModule" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'baseModule')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'baseModule')">Upgrade</div>
                </div>

        <div id="module_infobox_baseModule_content" class="skylab_module_content">
            <div id="module_infobox_baseModule_overview_large" class="tabContent skylab_standard">
                            <table class="module_infobox_baseModule" cellpadding="2" cellspacing="0">
    <tr>
        <td style="width:160px"><strong><?php echo $Lab['modules']['mod_basic']['name']; ?></strong></td>
        <td style="width:65px;">
            <div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['mod_basic']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div>
            <div style="width:<?php echo $Lab['modules']['mod_basic']['progressbar']; ?>px;position:absolute;height:172px;margin-top:-6px;border-right:1px solid #989898;z-index:100;"></div>
        </td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['mod_basic']['sd_status']?>"><strong><?php echo $Lab['modules']['mod_basic']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['mod_solar']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['mod_solar']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['mod_solar']['sd_status']?>"><strong><?php echo $Lab['modules']['mod_solar']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['mod_store']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['mod_store']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['mod_store']['sd_status']?>"><strong><?php echo $Lab['modules']['mod_store']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['generator_xeno']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['generator_xeno']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['generator_xeno']['sd_status']?>"><strong><?php echo $Lab['modules']['generator_xeno']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['collector_prometium']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['collector_prometium']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['collector_prometium']['sd_status']?>"><strong><?php echo $Lab['modules']['collector_prometium']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['collector_endurium']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['collector_endurium']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['collector_endurium']['sd_status']?>"><strong><?php echo $Lab['modules']['collector_endurium']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['collector_terbium']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['collector_terbium']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['collector_terbium']['sd_status']?>"><strong><?php echo $Lab['modules']['collector_terbium']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['refine_prometid']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['refine_prometid']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['refine_prometid']['sd_status']?>"><strong><?php echo $Lab['modules']['refine_prometid']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['refine_duranium']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['refine_duranium']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['refine_duranium']['sd_status']?>"><strong><?php echo $Lab['modules']['refine_duranium']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['refine_promerium']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['refine_promerium']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['refine_promerium']['sd_status']?>"><strong><?php echo $Lab['modules']['refine_promerium']['level']; ?></strong></td>
    </tr>
    <tr>
        <td><strong><?php echo $Lab['modules']['refine_seprom']['name']; ?></strong></td>
        <td><div class="iteminfo_overview_progressbar" style="width:<?php echo $Lab['modules']['refine_seprom']['progressbar']; ?>px;"></div>
            <div class="iteminfo_overview_progressgrid"></div></td>
        <td class="baseModul_level baseModul_level_<?php echo $Lab['modules']['refine_seprom']['sd_status']?>"><strong><?php echo $Lab['modules']['refine_seprom']['level']; ?></strong></td>
    </tr>
</table>
                        </div>
<?php echo $Skylab->showModule("baseModule","upthis"); ?>
            <div id="module_infobox_baseModule_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_baseModule_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_baseModule_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

    <?php echo $Skylab->showModule("baseModule","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("solarModule","smallbox"); ?>

<div id="module_solarModule_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Solar module</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_solarModule" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'solarModule')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'solarModule')">Upgrade</div>
                </div>

        <div id="module_infobox_solarModule_content" class="skylab_module_content">
            <div id="module_infobox_solarModule_overview_large" class="tabContent skylab_standard">
                            <table id="solarModul_overview_content" cellpadding="0" cellspacing="0">
    <tr>
        <td class="firstRow label">Total energy consumption:</td>
        <td class="secondRow value"><?php echo $Lab['modules']['mod_solar']['energy_all_usage']; ?> / <?php echo $Lab['modules']['mod_solar']['energy_production']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['mod_basic']['solarinfo']; ?> label">Basic module:</td>
        <td class="secondRow <?php echo $Lab['modules']['mod_basic']['solarinfo']; ?> value"><?php echo $Lab['modules']['mod_basic']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['mod_store']['solarinfo']; ?> label">Storage module:</td>
        <td class="secondRow <?php echo $Lab['modules']['mod_store']['solarinfo']; ?> value"><?php echo $Lab['modules']['mod_store']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow label">Transport module:</td>
        <td class="secondRow value">16</td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['collector_prometium']['solarinfo']; ?> label">Prometium collector:</td>
        <td class="secondRow <?php echo $Lab['modules']['collector_prometium']['solarinfo']; ?> value"><?php echo $Lab['modules']['collector_prometium']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['collector_endurium']['solarinfo']; ?> label">Endurium collector:</td>
        <td class="secondRow <?php echo $Lab['modules']['collector_endurium']['solarinfo']; ?> value"><?php echo $Lab['modules']['collector_endurium']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['collector_terbium']['solarinfo']; ?> label">Terbium collector:</td>
        <td class="secondRow <?php echo $Lab['modules']['collector_terbium']['solarinfo']; ?> value"><?php echo $Lab['modules']['collector_terbium']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['refine_prometid']['solarinfo']; ?> label">Prometid refinery:</td>
        <td class="secondRow <?php echo $Lab['modules']['refine_prometid']['solarinfo']; ?> value"><?php echo $Lab['modules']['refine_prometid']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['refine_duranium']['solarinfo']; ?> label">Duranium refinery:</td>
        <td class="secondRow <?php echo $Lab['modules']['refine_duranium']['solarinfo']; ?> value"><?php echo $Lab['modules']['refine_duranium']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['refine_promerium']['solarinfo']; ?> label">Promerium refinery:</td>
        <td class="secondRow <?php echo $Lab['modules']['refine_promerium']['solarinfo']; ?> value"><?php echo $Lab['modules']['refine_promerium']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['refine_seprom']['solarinfo']; ?> label">Seprom refinery:</td>
        <td class="secondRow <?php echo $Lab['modules']['refine_seprom']['solarinfo']; ?> value"><?php echo $Lab['modules']['refine_seprom']['energyusage']; ?></td>
    </tr>
    <tr>
        <td class="firstRow <?php echo $Lab['modules']['generator_xeno']['solarinfo']; ?> label">Xeno module:</td>
        <td class="secondRow <?php echo $Lab['modules']['generator_xeno']['solarinfo']; ?> value"><?php echo $Lab['modules']['generator_xeno']['energyusage']; ?></td>
    </tr>
</table>                        </div>

<?php echo $Skylab->showModule("solarModule","upthis"); ?>
        
            <div id="module_infobox_solarModule_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_solarModule_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_solarModule_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

    <?php echo $Skylab->showModule("solarModule","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("storageModule","smallbox"); ?>

<div id="module_storageModule_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Storage module</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_storageModule" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'storageModule')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'storageModule')">Upgrade</div>
                </div>

        <div id="module_infobox_storageModule_content" class="skylab_module_content">
            <div id="module_infobox_storageModule_overview_large" class="tabContent skylab_standard">
                            <table>
    <tr>
    <?php $Skylab->ressupdate("out");
    
$output $Skylab->getOutput(); 
    
    
$vc1 = ($output['prometium'] >= 0) ? "#69bf67" "#ff0000";
    
$vc2 = ($output['endurium'] >= 0) ? "#69bf67" "#ff0000";
    
$vc3 = ($output['terbium'] >= 0) ? "#69bf67" "#ff0000";
    
$vc4 = ($output['prometid'] >= 0) ? "#69bf67" "#ff0000";
    
$vc5 = ($output['duranium'] >= 0) ? "#69bf67" "#ff0000";
    
$vc6 = ($output['promerium'] >= 0) ? "#69bf67" "#ff0000";
    
$vc7 = ($output['seprom'] >= 0) ? "#69bf67" "#ff0000";?>
        <td width="140px"><strong>Prometium</strong></td>
        <td width="76px"><?php echo $Lab['ressources']['prometium']['count']; ?></td>
        <td width="54px"><span style="color: <?=$vc1?>"><?php echo $output['prometium'];?></span></td>
    </tr>
    <tr>
        <td><strong>Endurium</strong></td>
        <td><?php echo $Lab['ressources']['endurium']['count']?></td>
        <td><span style="color: <?=$vc2?>"><?php echo $output['endurium'];?></span></td>
    </tr>
    <tr>
        <td><strong>Terbium</strong></td>
        <td><?php echo $Lab['ressources']['terbium']['count']?></td>
        <td><span style="color: <?=$vc3?>"><?php echo $output['terbium'];?></span></td>
    </tr>
    <tr>
        <td><strong>Prometid</strong></td>
        <td><?php echo $Lab['ressources']['prometid']['count']?></td>
        <td><span style="color: <?=$vc4?>"><?php echo $output['prometid'];?></span></td>
    </tr>
    <tr>
        <td><strong>Duranium</strong></td>
        <td><?php echo $Lab['ressources']['duranium']['count']?></td>
        <td><span style="color: <?=$vc5?>"><?php echo $output['duranium'];?></span></td>
    </tr>
    <tr>
        <td><strong>Promerium</strong></td>
        <td><?php echo $Lab['ressources']['promerium']['count']?></td>
        <td><span style="color: <?=$vc6?>"><?php echo $output['promerium'];?></span></td>
    </tr>
    <tr>
        <td><strong>Seprom</strong></td>
        <td><?php echo $Lab['ressources']['seprom']['count']?></td>
        <td><span style="color: <?=$vc7?>"><?php echo $output['seprom'];?></span></td>
    </tr>
</table>                        </div>

<?php echo $Skylab->showModule("storageModule","upthis"); ?>
        
            <div id="module_infobox_storageModule_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_storageModule_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_storageModule_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("storageModule","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<div id="module_transportModule_small" class="module module_small" onclick="Skylab.showModule('transportModule');"">
    <table cellpadding="0" cellspacing="0" border="0">
        <tr>
            <td id="corner_small_top_left_active">
                <div class="name">Transport module</div>
            </td>
            <td id="corner_small_top_right_active"></td>
        </tr>
        <tr>
            <td id="corner_small_bottom_left_active">
               <table cellpadding="0" cellspacing="0">
                    <tr>
                        <td>
                                                            <div class="level_icon"></div>
                                                        <div class="level skylab_font_level">1</div>
                        </td>
                        <td class="cellview">
                            <div class="power_icon"></div>
                            <div class="power skylab_font_power">16</div>
                        </td>
                                                <td><br /></td>
                                            </tr>
                </table>
            </td>
            <td id="corner_small_bottom_right_active"></td>
        </tr>
    </table>
</div>

<div id="module_transportModule_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Transport module</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_transportModule" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'transportModule')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'transportModule')">Upgrade</div>
                </div>

        <div id="module_infobox_transportModule_content" class="skylab_module_content">
            <div id="module_infobox_transportModule_overview_large" class="tabContent skylab_standard">
                            

<div id="boxTimeForTransport" style="padding:30px 0 0 3px;">Arriving in: <span id="timeForTransport">?</span></div>

<form name="sendTransport" id="sendTransport" action="indexInternal.es" method="post"><input type="hidden" name="reloadToken" value="1e1064a8fdf038ee6e4c99e2beab4d29"><input type="hidden" name="reloadToken" value="1e1064a8fdf038ee6e4c99e2beab4d29">
<input type="hidden" name="action" value="internalSkylab">
<input type="hidden" name="subaction" value="startTransport">
<input type="hidden" id="mode" name="mode" value="normal">
<input type="hidden" id="construction" name="construction" value="TRANSPORT_MODULE">


<div id="transport_left">
    <table class="module_infobox_transportModule">
    <tr>
        <td style="width:83px;"><label for="count_prometium">Prometium:</label></td>
        <td style="width:49px;"><input type="text" name="count_prometium" id="count_prometium" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_endurium">Endurium:</label></td>
        <td><input type="text" name="count_endurium" id="count_endurium" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_terbium">Terbium:</label></td>
        <td><input type="text" name="count_terbium" id="count_terbium" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_prometid">Prometid:</label></td>
        <td><input type="text" name="count_prometid" id="count_prometid" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_duranium">Duranium:</label></td>
        <td><input type="text" name="count_duranium" id="count_duranium" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_xenomit">Xenomit:</label></td>
        <td><input type="text" name="count_xenomit" id="count_xenomit" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_promerium">Promerium:</label></td>
        <td><input type="text" name="count_promerium" id="count_promerium" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
    <tr>
        <td><label for="count_seprom">Seprom:</label></td>
        <td><input type="text" name="count_seprom" id="count_seprom" onkeyup="checkTransportTime(0.12, 0);" class="skylab_standard" value="0" autocomplete="off" /></td>
    </tr>
</table>
</div>

<div id="transport_right">
    <table>
        <tr>
            <td style="width:41px;"><img id="to_skylab" src="./do_img/global/pilotSheet/skylab/to_skylab_0.png?__cv=1f08c141b032cd3f3800247fe3f58100" width="41" height="36"></td>
            <td style="width:23px;"><img id="but_to_skylab" src="./do_img/global/pilotSheet/skylab/but_right_0.png?__cv=ac1391c5509c09a46cc9bd5e36c51400" width="17" height="17"></td>
            <td style="width:29px"><img id="to_ship" src="./do_img/global/pilotSheet/skylab/to_ship_0.png?__cv=b76cfb40c24b488ac9f685627faad600" width="29" height="36"></td>
        </tr>
        <tr>
            <td colspan="3" style="padding-top:20px;">
                <div class="button_standard">
                    <a style="display:block" onfocus="this.blur()" href="javascript:Skylab.sendTransport('fast', 'Confirm transport?','OK','Cancel');">Instant send</a>
                </div>
            </td>
        </tr>
        <tr>
            <td colspan="3" style="padding-top:5px;"><strong>1250 U.</strong></td>
        </tr>
        <tr>
            <td colspan="3" style="padding-top:25px;">
                <div class="button_standard">
                    <a style="display:block" onfocus="this.blur()" href="javascript:Skylab.sendTransport('normal');">Send</a>
                </div></td>
        </tr>
    </table>
</div>
<div class="clearMe"></div>
</form>

                        </div>

            <div id="module_infobox_transportModule_upgrade_large" class="tabContent skylab_standard" style="display: none;">
                    <div class="upgrade_container_max">
        Maximum upgrade level attained
    </div>
            </div>
        
            <div id="module_infobox_transportModule_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_transportModule_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_transportModule_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

        <div id="module_infobox_transportModule_footer" class="skylab_module_footer">
            <div class="module_info_active_state module_infobox_info">
                            <img src="./do_img/global/pilotSheet/skylab/power_disabled.png?__cv=b0a4878430feb41ac03c5a6d796fda00" width="14" height="14" />
                        </div>

            <div class="module_info_level module_infobox_info">
                            <div class="level_icon">1</div>
                        </div>

            <div class="module_info_power_usage module_infobox_info">
                16
            </div>

                </div>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("xenoModule","smallbox"); ?>

<div id="module_xenoModule_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Xeno module</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_xenoModule" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'xenoModule')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'xenoModule')">Upgrade</div>
                </div>

        <div id="module_infobox_xenoModule_content" class="skylab_module_content">
            <div id="module_infobox_xenoModule_overview_large" class="tabContent skylab_standard">
                                        <table class="module_infobox_xenoModule" cellpadding="0" cellspacing="0">
                <tr>
                    <td class="firstRow"><strong>Xeno module</strong></td>
                    <td class="secondRow"><strong>Active</strong></td>
                    <td class="thirdRow skylab_price_normal">
                        <div style="position:absolute;width:1px;height:124px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_vertical_short.png?__cv=b73ea38fd4a85fa2799b1ebde1973a00);background-repeat: no-repeat;background-position: 0px 5px"></div>
                        <strong>Inactive</strong></td>
                </tr>
                <tr>
                    <td></td>
                    <td colspan="2" style="height:1px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_horizontal.jpg?__cv=b7a2175510ce6023a12e11870f954500);background-repeat:no-repeat;"></td>
                </tr>
                <tr>
                    <td class="firstRow"><strong>Xenomit consumption:</strong></td>
                    <td class="secondRow"><strong>0</strong></td>
                    <td class="thirdRow skylab_price_normal"><strong>0</strong></td>
                </tr>
                <tr>
                    <td class="firstRow"><strong>Efficiency:</strong></td>
                    <td class="secondRow"><strong>100%</strong></td>
                    <td class="thirdRow skylab_price_normal"><strong>0%</strong></td>
                </tr>
                <tr>
                    <td class="firstRow"><strong>Energy:</strong></td>
                    <td class="secondRow"><strong>0</strong></td>
                    <td class="thirdRow skylab_price_normal"><strong>0</strong></td>
                </tr>
                <tr>
                    <td></td>
                    <td colspan="2" style="height:1px;background-image: url(./do_img/global/pilotSheet/skylab/seperator_horizontal.jpg?__cv=b7a2175510ce6023a12e11870f954500);background-repeat:no-repeat;"></td>
                </tr>
            </table>
                        </div>

<?php echo $Skylab->showModule("xenoModule","upthis"); ?>
        
            <div id="module_infobox_xenoModule_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_xenoModule_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_xenoModule_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("xenoModule","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("prometiumCollector","smallbox"); ?>

<div id="module_prometiumCollector_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Prometium collector</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_prometiumCollector" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'prometiumCollector')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'prometiumCollector')">Upgrade</div>
                    <div class="tab_third skylab_module_tab" onclick="Skylab.changeToTab('third', 'prometiumCollector')">Productivity</div>
                </div>

        <div id="module_infobox_prometiumCollector_content" class="skylab_module_content">
            <div id="module_infobox_prometiumCollector_overview_large" class="tabContent skylab_standard">
                <?php echo $Skylab->showModule("prometiumCollector","collectorDetails"); ?>
            </div>

 <?php echo $Skylab->showModule("prometiumCollector","upthis"); ?>
                    <div id="module_infobox_prometiumCollector_productivity_large" class="tabContent skylab_standard" style="display: none;">
                
<script>
jQuery(document).ready(function(){
    jQuery('#tdActiveRobts, #prometiumCollector_showActiveRobots').mouseover(function(){
        jQuery('#prometiumCollector_showActiveRobots').show();
    });
    jQuery('#tdActiveRobts, #prometiumCollector_showActiveRobots').mouseout(function(){
        jQuery('#prometiumCollector_showActiveRobots').hide();
    });
});
</script>

<div id="productivity_container">


    <div id="prometiumCollector_showActiveRobots" class="showActiveRobots" style="display:none;">
        
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            <br class="clearMe" />
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
            </div>

    <table cellpadding="0" cellspacing="1">
        <tr>
            <td colspan="2">Efficiency:</td>
            <td>Bonus:</td>
            <td style="text-align:right;">Robots:</td>
            <td><br /></td>
        </tr>
        <tr>
            <td style="width:70px;background-color:#1f2022;padding-left:5px;cursor:pointer;">100%</td>
            <td style="width:15px;cursor:pointer;">+</td>
            <td style="width:50px;background-color:#1f2022;padding-left:5px;cursor:pointer;color:#23fd10"><span id="prometiumCollector_skylabRobotBonus">0</span>%</td>
            <td style="width:70px;text-align:right;padding-right:3px;cursor:pointer;">Active</td>
            <td id="tdActiveRobts" style="width:45px;background-color:#1f2022;text-align:center;cursor:pointer;"><span id="prometiumCollector_skylabActiveRobots" style="color:#23fd10">0</span>/12</td>
        </tr>
        <tr>
            <td colspan="4" style="text-align:right;padding-right:3px;">in storage</td>
            <td style="background-color:#1f2022;text-align:center;" id="prometiumCollector_skylabPendingRobots">0</td>
        </tr>
    </table>

    <div class="productivity_robotShop">
        <div class="productivity_robotShop_credits">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big.png?__cv=29d973635304fd6902b88e3678b88400" width="66" height="57">
            <div class="skylab_robot_price">250 Credits</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('1','prometiumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
        <div class="productivity_robotShop_uridium">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big_elite.png?__cv=8d70dd00ac084d814c347beb80267400" width="66" height="57">
            <div class="skylab_robot_price">50 Uridium</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('2','prometiumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
    </div>

</div>            </div>
        
            <div id="module_infobox_prometiumCollector_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_prometiumCollector_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_prometiumCollector_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("prometiumCollector","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("enduriumCollector","smallbox"); ?>

<div id="module_enduriumCollector_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Endurium collector</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_enduriumCollector" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'enduriumCollector')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'enduriumCollector')">Upgrade</div>
                    <div class="tab_third skylab_module_tab" onclick="Skylab.changeToTab('third', 'enduriumCollector')">Productivity</div>
                </div>

        <div id="module_infobox_enduriumCollector_content" class="skylab_module_content">
            <div id="module_infobox_enduriumCollector_overview_large" class="tabContent skylab_standard">
                <?php echo $Skylab->showModule("enduriumCollector","collectorDetails"); ?>
            </div>

 <?php echo $Skylab->showModule("enduriumCollector","upthis"); ?>
                    <div id="module_infobox_enduriumCollector_productivity_large" class="tabContent skylab_standard" style="display: none;">
                
<script>
jQuery(document).ready(function(){
    jQuery('#tdActiveRobts, #enduriumCollector_showActiveRobots').mouseover(function(){
        jQuery('#enduriumCollector_showActiveRobots').show();
    });
    jQuery('#tdActiveRobts, #enduriumCollector_showActiveRobots').mouseout(function(){
        jQuery('#enduriumCollector_showActiveRobots').hide();
    });
});
</script>

<div id="productivity_container">


    <div id="enduriumCollector_showActiveRobots" class="showActiveRobots" style="display:none;">
        
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            <br class="clearMe" />
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
            </div>

    <table cellpadding="0" cellspacing="1">
        <tr>
            <td colspan="2">Efficiency:</td>
            <td>Bonus:</td>
            <td style="text-align:right;">Robots:</td>
            <td><br /></td>
        </tr>
        <tr>
            <td style="width:70px;background-color:#1f2022;padding-left:5px;cursor:pointer;">100%</td>
            <td style="width:15px;cursor:pointer;">+</td>
            <td style="width:50px;background-color:#1f2022;padding-left:5px;cursor:pointer;color:#23fd10"><span id="enduriumCollector_skylabRobotBonus">0</span>%</td>
            <td style="width:70px;text-align:right;padding-right:3px;cursor:pointer;">Active</td>
            <td id="tdActiveRobts" style="width:45px;background-color:#1f2022;text-align:center;cursor:pointer;"><span id="enduriumCollector_skylabActiveRobots" style="color:#23fd10">0</span>/12</td>
        </tr>
        <tr>
            <td colspan="4" style="text-align:right;padding-right:3px;">in storage</td>
            <td style="background-color:#1f2022;text-align:center;" id="enduriumCollector_skylabPendingRobots">0</td>
        </tr>
    </table>

    <div class="productivity_robotShop">
        <div class="productivity_robotShop_credits">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big.png?__cv=29d973635304fd6902b88e3678b88400" width="66" height="57">
            <div class="skylab_robot_price">250 Credits</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('1','enduriumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
        <div class="productivity_robotShop_uridium">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big_elite.png?__cv=8d70dd00ac084d814c347beb80267400" width="66" height="57">
            <div class="skylab_robot_price">50 Uridium</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('2','enduriumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
    </div>

</div>            </div>
        
            <div id="module_infobox_enduriumCollector_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_enduriumCollector_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_enduriumCollector_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

 <?php echo $Skylab->showModule("enduriumCollector","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("terbiumCollector","smallbox"); ?>
<div id="module_terbiumCollector_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Terbium collector</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_terbiumCollector" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'terbiumCollector')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'terbiumCollector')">Upgrade</div>
                    <div class="tab_third skylab_module_tab" onclick="Skylab.changeToTab('third', 'terbiumCollector')">Productivity</div>
                </div>

        <div id="module_infobox_terbiumCollector_content" class="skylab_module_content">
            <div id="module_infobox_terbiumCollector_overview_large" class="tabContent skylab_standard">
                <?php echo $Skylab->showModule("terbiumCollector","collectorDetails"); ?>
            </div>

 <?php echo $Skylab->showModule("terbiumCollector","upthis"); ?>
                    <div id="module_infobox_terbiumCollector_productivity_large" class="tabContent skylab_standard" style="display: none;">
                
<script>
jQuery(document).ready(function(){
    jQuery('#tdActiveRobts, #terbiumCollector_showActiveRobots').mouseover(function(){
        jQuery('#terbiumCollector_showActiveRobots').show();
    });
    jQuery('#tdActiveRobts, #terbiumCollector_showActiveRobots').mouseout(function(){
        jQuery('#terbiumCollector_showActiveRobots').hide();
    });
});
</script>

<div id="productivity_container">


    <div id="terbiumCollector_showActiveRobots" class="showActiveRobots" style="display:none;">
        
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            <br class="clearMe" />
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
                    <div class="container_robot_small">
                            <img src="./do_img/global/pilotSheet/skylab/icon_robot_empty.png?__cv=f7ff82658232a01263ae70afb4011400" width="39" height="34">
                <div style="width:33px;text-align:center;margin-left:5px;"><br /></div>
                        </div>
            
            </div>

    <table cellpadding="0" cellspacing="1">
        <tr>
            <td colspan="2">Efficiency:</td>
            <td>Bonus:</td>
            <td style="text-align:right;">Robots:</td>
            <td><br /></td>
        </tr>
        <tr>
            <td style="width:70px;background-color:#1f2022;padding-left:5px;cursor:pointer;">100%</td>
            <td style="width:15px;cursor:pointer;">+</td>
            <td style="width:50px;background-color:#1f2022;padding-left:5px;cursor:pointer;color:#23fd10"><span id="terbiumCollector_skylabRobotBonus">0</span>%</td>
            <td style="width:70px;text-align:right;padding-right:3px;cursor:pointer;">Active</td>
            <td id="tdActiveRobts" style="width:45px;background-color:#1f2022;text-align:center;cursor:pointer;"><span id="terbiumCollector_skylabActiveRobots" style="color:#23fd10">0</span>/12</td>
        </tr>
        <tr>
            <td colspan="4" style="text-align:right;padding-right:3px;">in storage</td>
            <td style="background-color:#1f2022;text-align:center;" id="terbiumCollector_skylabPendingRobots">0</td>
        </tr>
    </table>

    <div class="productivity_robotShop">
        <div class="productivity_robotShop_credits">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big.png?__cv=29d973635304fd6902b88e3678b88400" width="66" height="57">
            <div class="skylab_robot_price">250 Credits</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('1','terbiumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
        <div class="productivity_robotShop_uridium">
            <img src="./do_img/global/pilotSheet/skylab/icon_robot_big_elite.png?__cv=8d70dd00ac084d814c347beb80267400" width="66" height="57">
            <div class="skylab_robot_price">50 Uridium</div>
            <div class="button_standard" style="margin: auto;">
                <a style="display: block;" onfocus="this.blur()" onclick="xajax_buySkylabRobot('2','terbiumCollector');" href="javascript:void(0);">Buy</a>
            </div>
        </div>
    </div>

</div>            </div>
        
            <div id="module_infobox_terbiumCollector_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_terbiumCollector_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_terbiumCollector_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>
<?php echo $Skylab->showModule("terbiumCollector","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("prometidRefinery","smallbox"); ?>

<div id="module_prometidRefinery_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Prometid refinery</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_prometidRefinery" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'prometidRefinery')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'prometidRefinery')">Upgrade</div>
                </div>

        <div id="module_infobox_prometidRefinery_content" class="skylab_module_content">
<?php echo $Skylab->showModule("prometidRefinery","refineryDetails"); ?>

 <?php echo $Skylab->showModule("prometidRefinery","upthis"); ?>
        
            <div id="module_infobox_prometidRefinery_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_prometidRefinery_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_prometidRefinery_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("prometidRefinery","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("duraniumRefinery","smallbox"); ?>

<div id="module_duraniumRefinery_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Duranium refinery</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_duraniumRefinery" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'duraniumRefinery')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'duraniumRefinery')">Upgrade</div>
                </div>

        <div id="module_infobox_duraniumRefinery_content" class="skylab_module_content">
            <?php echo $Skylab->showModule("duraniumRefinery","refineryDetails"); ?>

 <?php echo $Skylab->showModule("duraniumRefinery","upthis"); ?>
        
            <div id="module_infobox_duraniumRefinery_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_duraniumRefinery_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_duraniumRefinery_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("duraniumRefinery","footer"); ?>
    </div>

</div>
<script type="text/javascript">
</script>
<?php echo $Skylab->showModule("promeriumRefinery","smallbox"); ?>

<div id="module_promeriumRefinery_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Promerium refinery</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_promeriumRefinery" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'promeriumRefinery')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'promeriumRefinery')">Upgrade</div>
                </div>

        <div id="module_infobox_promeriumRefinery_content" class="skylab_module_content">
<?php echo $Skylab->showModule("promeriumRefinery","refineryDetails"); ?>

 <?php echo $Skylab->showModule("promeriumRefinery","upthis"); ?>
        
            <div id="module_infobox_promeriumRefinery_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_promeriumRefinery_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_promeriumRefinery_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("promeriumRefinery","footer"); ?>
    </div>

</div>
<script type="text/javascript">
    jQuery('#module_infobox_promeriumRefinery_infomessage').html("Before you upgrade your Promerium refinery, you should build Prometid and Duranium refineries as well as a Xeno module so that you'll have enough resources to refine. These refineries are located on the right in the Skylab.");
    jQuery('#module_infobox_promeriumRefinery_resourceWarning_large').show();
</script>
<?php echo $Skylab->showModule("sepromRefinery","smallbox"); ?>

<div id="module_sepromRefinery_large" class="module module_large" style="display: none;">
    <div class="skylab_module_header">
        <div class="name">Seprom refinery</div>
        <div class="skylab_module_close"></div>
    </div>

    <div id="module_infobox_sepromRefinery" class="skylab_module_middle">
        <div class="skylab_module_tabs">
            <div class="tab_first skylab_module_tab tab_active" onclick="Skylab.changeToTab('first', 'sepromRefinery')">Info</div>
            <div class="tab_second skylab_module_tab" onclick="Skylab.changeToTab('second', 'sepromRefinery')">Upgrade</div>
                </div>

        <div id="module_infobox_sepromRefinery_content" class="skylab_module_content">
<?php 
    
echo $Skylab->showModule("sepromRefinery","refineryDetails");
    echo 
$Skylab->showModule("sepromRefinery","upthis");
?>
        
            <div id="module_infobox_sepromRefinery_resourceWarning_large" class="tabContent skylab_standard module_resourceWarning">
                <div id="module_infobox_sepromRefinery_infomessage" class="module_resourceWarning_text"></div>
                <div class="button_standard module_resourceWarning_button">
                    <a style="display: block;" onfocus="this.blur()" onclick="jQuery('#module_infobox_sepromRefinery_resourceWarning_large').hide();" href="#">
                        <strong>OK</strong>
                    </a>
                </div>
            </div>
        </div>

<?php echo $Skylab->showModule("sepromRefinery","footer"); ?>
    </div>
    </div>

<script type="text/javascript">
$('module_infobox_sepromRefinery_infomessage').innerHTML = "Before you upgrade your Seprom refinery, you should build a Promerium refinery so that you'll have enough resources to refine. This refinery is located on the right in the Skylab.";
$('module_infobox_sepromRefinery_resourceWarning_large').show();
</script>    </div>
   </div>
</div><!-- END contentFrame -->
</div><!-- END realContainer -->

<div class="footerContainer">
    <div class="frameLeft_bottom"></div>
    <div class="frameRight_bottom"></div>
    <div class="frameBottom"></div>

<div id="alertBox" class="fliesstext"></div>
<div id="imprint" style="width:523px;height:600px;" class="fliesstext">
    <div id="imprint_close"><a href="javascript:void(0);" onclick="closeInfo('imprint');"><img src="./do_img/global/intro/but_close.png?__cv=4addfeeb6d889c0632072f85386d1900" alt="" /></a></div>
    <div id="imprint_text"><b>Bigpoint S.ŕ.r.l. and Co, SCS</b><br>Building Vertigo - Polaris<br>2-4 rue Eugčne Ruppert<br>L-2453 Luxemburg<br><br><b>Our business portal</b><br><a class="" href="http://www.bigpoint.net" target="_blank">http://www.bigpoint.net</a><br><br><b>Corporate information</b><br>CEO: Bigpoint S.ŕ.r.l.<br>Jeronimo Folgueira<br>Court of registry: R.C.S. Luxemburg<br>Trade register number: B 167809<br>VAT number: LU 25331016<br><br><b>Disclaimer</b><br>Although every effort is made to present current and accurate information, we cannot assume responsibility for information from external links. The author of each web page is solely responsible for the content of that page.<br><br><b>Contact</b><br>Telephone <b>(no Support)</b>: +352 261 911 3515<br>Fax: +352 49 48 48 6606<br><br><b>Questions or problems? Contact Support</b><br>E-mail: <a class="gl_imprint_support_link" href="/index.es?action=support">Support form</a><br>Internet: http://www.bigpoint.com<br><br><b>Commissioner for Youth Protection</b><br>Lawyer Dr. Andreas Lober<br>SCHULTE RIESENKAMPFF Rechtsanwaltsgesellschaft mbH<br />An der Hauptwache 7<br />60313 Frankfurt am Main<br>E-mail: <br><br><b>Data protection officer</b><br>E-mail: <br><a style="text-decoration: underline" class="" href="/index.es?action=info&subAction=privacyPolicy" target="_blank">Data Privacy Policy</a></div>
</div>
<?php require GLOBALS 'credits.php';?>

<script type="text/javascript" id="sourcecode">

    jQuery(function()
    {
        jQuery('#teamCredits_text').jScrollPane({autoReinitialise: true, showArrows: true});
    });

</script>

    <div id="imprint_ingame" class="fliesstext"
         style="position:absolute; left:40px; top:24px; height:15px;">
                    <a href="javascript:void(0);" onclick="showFooterLayer('imprint');">
                Legal information</a> |
                <a href="javascript:void(0);" onclick="showFooterLayer('teamCreditsBox')">Credits</a> |
        <a href="/GameAPI.php?action=portal.redirectToBoard" target="_blank">Forum</a>
    </div>


    


    </div><!-- End footerContainer -->
</div><!-- End bodyContainer -->
</div><!-- End outerContainer -->
</div><!-- End overallContainer -->
</div>

<script type="text/javascript">
    Dialog.alert('<ul><li>Alpha-Version!!!</li></ul>', { width:300 } );
</script>





<script type="text/javascript">
    
    if (jQuery('#toolbar').length > 0) {
        jQuery('#toolbar').css('float', 'none');
        jQuery('body').css('background-position', 'center 30px');
    }
    
</script>
<link rel="stylesheet" type="text/css" href="./resources/css/popup.css?__cv=4e58da2dec4df33ee5f4c239848dda00" />
<div id="popup">
    <div class="header">
        <div class="button-close"></div>
    </div>
    <div class="body">
        <div class="icon icon-question"></div>
        <div class="icon icon-error"></div>
        <div class="icon icon-success"></div>
        <div class="content fliess13px-grey"></div>
    </div>
    <div class="footer single-button">
        <div class="button button-green">
            <div class="text" style="background-image: url(/do_img/global/text_tf.esg?s=12&t=ok&f=eurostyle_thea&color=white&bgcolor=grey);"></div>
        </div>
        <div class="button button-blue">
            <div class="text" style="background-image: url(/do_img/global/text_tf.esg?s=12&t=confirmBox_cancel&f=eurostyle_thea&color=white&bgcolor=grey);"></div>
        </div>
    </div>
</div>
<div id="popup-modalBackground"></div>
<img id="popup-loading" alt="Loading..." src="./do_img/global/pilotSheet/profilePage/loadingAnimation.gif" />

<!-- LayertoolService JavaScript Injection start -->
<script type="text/javascript">
    //<![CDATA[
    // add fancybox css to the head
    var cssLink  = document.createElement('link');
    cssLink.type = 'text/css';
    cssLink.rel  = 'stylesheet';
    cssLink.href = './application/fancybox/jquery.fancybox-1.3.4.css';
    document.getElementsByTagName('head')[0].appendChild(cssLink);
    //]]>
</script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7/jquery.min.js"></script>
<script type="text/javascript" src="./application/fancybox/jquery.fancybox-1.3.4.js"></script>
<script type="text/javascript" src="./application/client/client.js"></script>
<script type="text/javascript" src="./application/cookie/jquery.cookie.js"></script>
<script type="text/javascript">var jQueryLts = jQuery.noConflict(true);</script>

<!-- LayertoolService JavaScript Injection end -->


</body>
</html>
<script language="javascript" type="text/javascript">

var refresh = 'Refresh skylab';
var help = 'Help';



jQuery("#skylabReloader").qtip({
    content: refresh,
    style:'dohdr',
    position:{target:'mouse'}
})

jQuery("#skylabHelp").qtip({
    content: help,
    style:'dohdr',
    position:{target:'mouse'}
})

</script>
THIS IS NO COPY-PASTE-JOB TO GET IT WORK. DON'T SPAM ME!

Pictures





UND3RW0RLD is offline  
Thanks
3 Users
Old 11/21/2014, 17:46   #1193
 
elite*gold: 0
Join Date: Jun 2011
Posts: 297
Received Thanks: 14


Need help on my server idk how i can take it online with Windows server 2012 r2
Puma<3 is offline  
Old 11/22/2014, 12:37   #1194
 
steppdroid's Avatar
 
elite*gold: 0
Join Date: Sep 2014
Posts: 280
Received Thanks: 42
Quote:
Originally Posted by Puma<3 View Post


Need help on my server idk how i can take it online with Windows server 2012 r2
the database is inserted? -.-
steppdroid is offline  
Old 11/22/2014, 12:44   #1195
 
UND3RW0RLD's Avatar
 
elite*gold: 1
Join Date: Jun 2011
Posts: 1,464
Received Thanks: 1,065
Quote:
Originally Posted by «Ice.Shock™
I managed to make your skylab work but since I'm not MySQL expert I'm asking you if you can give me the skylab db
Code:
CREATE TABLE IF NOT EXISTS `skylab` (
  `LabID` int(11) NOT NULL AUTO_INCREMENT,
  `UserID` int(11) NOT NULL,
  `lastvisit` varchar(20) DEFAULT '0',
  `basicmod` varchar(50) NOT NULL DEFAULT '1',
  `solarmod` varchar(50) NOT NULL DEFAULT '1',
  `storagemod` varchar(50) NOT NULL DEFAULT '1',
  `prometiumcol` varchar(50) NOT NULL DEFAULT '0',
  `enduriumcol` varchar(50) NOT NULL DEFAULT '0',
  `terbiumcol` varchar(50) NOT NULL DEFAULT '0',
  `prometidref` varchar(50) NOT NULL DEFAULT '0',
  `duraniumref` varchar(50) NOT NULL DEFAULT '0',
  `promeriumref` varchar(50) NOT NULL DEFAULT '0',
  `xenogen` varchar(50) NOT NULL DEFAULT '0',
  `sepromref` varchar(50) NOT NULL DEFAULT '0',
  PRIMARY KEY (`UserID`),
  UNIQUE KEY `LabID` (`LabID`)
) ENGINE=InnoDB  DEFAULT CHARSET=latin1 AUTO_INCREMENT=11689 ;

CREATE TABLE IF NOT EXISTS `skylab_ressources` (
  `LabID` int(11) NOT NULL,
  `prometium` bigint(20) DEFAULT '1000',
  `endurium` bigint(20) DEFAULT '1000',
  `terbium` bigint(20) DEFAULT '1000',
  `prometid` bigint(20) DEFAULT '0',
  `duranium` bigint(20) DEFAULT '0',
  `xenomit` bigint(20) DEFAULT '0',
  `promerium` bigint(20) DEFAULT '0',
  `seprom` bigint(20) DEFAULT '0',
  PRIMARY KEY (`LabID`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
Quote:
Originally Posted by ǝnd1ǝss-ɯonǝʎ
Quote:
Originally Posted by «Ice.Shock™
Quote:
Originally Posted by ǝnd1ǝss-ɯonǝʎ
Quote:
Originally Posted by «Ice.Shock™
Well obviously I'm not much of a beast coder but however there is something going wrong with your counting system and overall MySQL. It does connect to mysql and it is working flawless but for some reason it does not count the resources nor defines the windows of the generators. I'm sure I'm going something wrong.

Line I've replaced for your Global DB

Quote:
$this->con = DB::getInstance();

PS: Would you mind creating me a DB for exporting / importing resources from the game since I'm doing some job on there.
are you using mysqli or pdo?
PDO
i'll update the thread
some parts where sleeping in an other file lol

PHP Code:
elseif ($_GET['action'] === 'internalSkylab'):
            require 
GLOBALS 'internalDoc.php';
            echo 
'<link rel="stylesheet" media="all" href="/css/cdn/internalSkylab.css" />';
            require 
GLOBALS 'internalDocEnd.php';
            require 
GLOBALS 'sajax.php';
            require 
GLOBALS 'xajax.php';
            require 
GLOBALS 'headerEndJS.php';
            
$Skylab->setId($Users->DataRow['ID']);
            
$Skylab->initSkylab();
            
$Skylab->getAllData();
            
            if(isset(
$_GET['subaction'])){
                if(
$_GET['subaction'] == "setInactive" && isset($_GET['construction'])){
                    
$Skylab->setStatus($_GET['construction'], "0""status");
                }elseif(
$_GET['subaction'] == "upgrade"){
                    
$Skylab->setStatus($_GET['construction'], "2""upthis");
                }elseif(
$_GET['subaction'] == "setActive"){
                    
$Skylab->setStatus($_GET['construction'], "1""status");
                }elseif(
$_GET['subaction'] == "instantUpgrade"){
                    
$Skylab->setStatus($_GET['construction'], "1""instaup");
                }
/*elseif($_GET['subaction'] == ""){
                
                }*/
            
}
            require 
GLOBALS 'internalMenu.php';
            require 
GLOBALS 'internalHeader.php';
            require 
FILES 'INDEXINTERNAL/internalSkylab_Body.php';
            require 
GLOBALS 'ads.php'
UND3RW0RLD is offline  
Thanks
2 Users
Old 11/22/2014, 15:21   #1196
 
elite*gold: 0
Join Date: Sep 2014
Posts: 8
Received Thanks: 0
Hi i have a problem @azure do server 0.6.2



please help me
hewal44 is offline  
Old 11/22/2014, 15:31   #1197
 
elite*gold: 15
Join Date: Dec 2012
Posts: 1,236
Received Thanks: 1,411
Quote:
Originally Posted by hewal44 View Post
Hi i have a problem @azure do server 0.6.2



please help me
The only way to help you is delete Azure and download Linkpad's source.
«Ice.Shock™ is offline  
Thanks
2 Users
Old 11/22/2014, 15:34   #1198
 
elite*gold: 0
Join Date: Sep 2014
Posts: 8
Received Thanks: 0
Quote:
Originally Posted by «Ice.Shock™ View Post
The only way to help you is delete Azure and download Linkpad's source.
Thanks for comment but i don't know how to download linkpad's i'm very junior sory
hewal44 is offline  
Old 11/22/2014, 20:54   #1199
 
YURI-ELIADE.ITALY's Avatar
 
elite*gold: 15
Join Date: Feb 2014
Posts: 313
Received Thanks: 78
Quote:
Originally Posted by hewal44 View Post
Hi i have a problem @azure do server 0.6.2



please help me
to doweloand : emulator
YURI-ELIADE.ITALY is offline  
Thanks
1 User
Old 11/23/2014, 00:34   #1200
 
elite*gold: 0
Join Date: Nov 2013
Posts: 60
Received Thanks: 4
anybody knows packets for ACM mines?
king[amg]ua is offline  
Reply

Tags
2018, darkorbit, emulator, private, server


Similar Threads Similar Threads
Private private server :P READ FOR MORE INFO
12/01/2010 - SRO Private Server - 12 Replies
hey guys im wondering if there is anyway to make a real private server like ZSZC or SWSRO or MYSRO but to where i can only play and level a character and as if it was a real private server. but just for me, not like an emulator where im already lvl 90 or 120 or whatever. i mean one where i set the rates and i level. if not then ok u can close this. but i was just wondering.



All times are GMT +1. The time now is 05:24.


Powered by vBulletin®
Copyright ©2000 - 2026, 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 ©2026 elitepvpers All Rights Reserved.