Jump to content

Virtual-Skies Map Tracker?


Thomas

Recommended Posts

Hi Guys,

Some of you might of heard of VSN or Virtual-Skies, its like Vatsim however alot smaller,

Is it possible to intergrate online pilots from there website to ours/your va's live map?

There website: http://www.virtual-skies.com/

So its just the same, live map wise, just need a code or something with Js?

Thanks, Thomas.

Link to comment
Share on other sites

  • Administrators

I have a VATSIM module working on my devlopment site to gather and sort current Vatsim pilot data, which includes the lat/long of their location. It would just take the coding to apply that lat/long and pilot info to the map. I am not sure if Virtual Skies offers a data feed as Vatsim does.

Link to comment
Share on other sites

  • Administrators

Ok,

1st- Simpilot, Vatsim doesnt work on my site, do you possibly have the code or maybe can you even send me it :D

2nd- Jayden, where do you want me to add this?

Not sure what you mean by "Vatsim doesnt work on my site" Have you written your own code or something for vatsim....

Link to comment
Share on other sites

  • Administrators

Simpilot,

Virtual Skies offers the data in the same format that you will be gathering it from VATSIM. http://status.virtual-skies.com/whazzup.txt

JS

Just looked at it and you are correct - It looks exactly the same as vatsim, wonder how they got away with that? I will see what happens to my module if I use the vsn page as a data source...

Link to comment
Share on other sites

  • Administrators

Dave, it will basically be an event listener for "refresh_acars".

This will work with the next beta:

<?php


class test extends CodonModule
{
    public function __construct()
    {
        parent::__construct();
        CodonEvent::addListener('test');
    }
    
    public function EventListener($eventinfo)
    {
        if($eventinfo[0] == 'refresh_acars')
        {
            // This gets the current instance of the ACARS controller so we can
            //    manipulate it
            $acars = MainController::getInstance('ACARS');
            //$acars->acarsflights This has all of the ACARS flights currently
            
            // This presumabley would be in a loop
            //foreach($flight as $flight)
            //{
            
                // Populate this array below with all of the data we need
                // Ignore the fields in it right now, I just pulled it from the acars now
                $acarsflight = array('pilotid'=>$pilotid,
                            'flightnum'=>$_GET['IATA'],
                            'pilotname'=>'',
                            'aircraft'=>$_GET['Regist'],
                            'lat'=>$_GET['lat'],
                            'lng'=>$_GET['long'],
                            'heading'=>'',
                            'alt'=>$_GET['Alt'],
                            'gs'=>$_GET['GS'],
                            'depicao'=>$_GET['depaptICAO'],
                            'depapt'=>$_GET['depapt'],
                            'arricao'=>$_GET['destaptICAO'],
                            'arrapt'=>$_GET['destapt'],
                            'deptime'=>'',
                            'arrtime'=>'',
                            'distremain'=>$_GET['disdestapt'],
                            'timeremaining'=>$_GET['timedestapt'],
                            'phasedetail'=>$phase_detail[$_GET['detailph']],
                            'online'=>$_GET['Online'],
                            'client'=>'FSACARS');
                
                // Now add the above data structure to our total acars flights
                $acars->acarsflights[] = $acarsflight;
                
            //} // end loop
        }
    }
}

Link to comment
Share on other sites

Hello Joeri  ;)

---

Just looked at it and you are correct - It looks exactly the same as vatsim, wonder how they got away with that? I will see what happens to my module if I use the vsn page as a data source...

We use the same base server networking server as them. As default it outputs to a text file called whazzup.txt - You will find the same for IVAO too.

JS

Link to comment
Share on other sites

  • Administrators

Hello Joeri  ;)

---

We use the same base server networking server as them. As default it outputs to a text file called whazzup.txt - You will find the same for IVAO too.

JS

Does anyone know what the address to the IVAO whazzup file is? I can not seem to find it.  ???

Thanks

edit - nvr mnd - found it

Link to comment
Share on other sites

  • Administrators

What peeves me is that XML is a standardized format, but they all refuse to use it... instead we have to do this inane parsing and picking apart data because it's in a dumb proprietary format. If XML is too verbose, they can use JSON, but they're both standardized and all languages have build in libraries to parse them... blah

/End rant

Link to comment
Share on other sites

  • Administrators

I have gotten the feeds for Vatsim, IVAO, Virtual Skies, and Real World ATC working on my development site. They all have a similar format but do have small items that are different so each data feed needs it's own module. I am working on transfering the data to the live map, right now all it does is count the data and can display all the info for each Pilot or ATC, as well as sort out a certain airline call sign. Does anyone know the admins on any of these sites other than Vatsim? Vatsim has a detailed written policy about using their data which I have made the Vatsim datafeed adhere to, but the others seem to lack much if anything in regards to the use of their data. I have had some tell me "yeah it's ok" but nothing as far as a policy.

Link to comment
Share on other sites

  • Administrators

If it's minor differences, you might be able to just do it in one module, and have settings within the file (like:

<?php
class ACARS_Remote extends CodonModule{

  public $parse_vatsim = true;
  public $parse_ivao = false;

  public function index()
  {
      if($this->parse_vatsim == true)
      {
           $this->parse_vatsim_list();
       }
      // etc
   }
}

Then different functions with each parsing. What are the differences? Maybe they can be compensated for within the code? But that would be the cleaner option in the end, IMO.

Also, did you see my sample for adding the data to the live map?

Link to comment
Share on other sites

  • 2 months later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...