Chocolate Software Forums

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Hop List Position File - format  (Read 3548 times)

Pro_Avia

  • Junior Member
  • **
  • Offline Offline
  • Posts: 25
    • FreedomAir Virtual Airlines
Hop List Position File - format
« on: August 04, 2014, 09:43:52 PM »

Hi Russell

I am trying to reconstruct a position file do to the need to change server providers. I cannot retrieve the original position file from the previous person who was running the server. Several pilots were flying a 50+ leg hop and I'd like to add all of the legs they have previously flown. I did have one pilot fly a hop so I could try to figure out the format. I do understand the first several columns of the position file, but I'm not sure of the data in the last 2 or why the leg number is displayed twice. Any help would be most appreciated.

Thanks
Gene

Pilot_Number/Name Leg_Number Leg_Number 10-Digit_Number 1-Digit_Number

99 Bill                            23                23           1407196094                 0

« Last Edit: August 04, 2014, 09:46:50 PM by Pro_Avia »
Logged

Russell Gilbert

  • Administrator
  • Guru
  • *****
  • Offline Offline
  • Posts: 1465
    • FSHost
Re: Hop List Position File - format
« Reply #1 on: August 05, 2014, 08:30:49 AM »

Hi Gene. Sure, here's the format:

<player_name><tab><current_hop><tab><highest_hop_started><tab><last_time_hop_completed><tab><time_hop_list_first_completed>

The time values are in Unix time format, or in other words, number of seconds since Jan. 1, 1970.
On Unix/Linux systems, type date +%s to get the current time in Unix time (ex. output: 1407246189).

Or to convert a specific date/time to Unix time, type: date -d '12/31/2013 23:59:59' +%s (outputs: 1388555999)

Or to convert from Unix time back to a local time/date string, type: date -d '@1388555999' (outputs: Tue Dec 31 23:59:59 CST 2013).

Example: Bill is currently on hop 10, which is also the highest hop he's started. He completed hop 9 at 12/31/2013 23:59:59. He has never completed the full hop list.

Bill<tab>10<tab>10<tab>1388555999<tab>0

Example: Bill finished hop 11 at 12/31/2013 23:59:59. He then used a chat command to manually position himself back at hop 10, where he is currently. He has never completed the full hop list.

Bill<tab>10<tab>11<tab>1388555999<tab>0

Example: Bill is currently on hop 10 of a list with 20 hops total. He completed hop 9 at 12/31/2013 23:59:59. He finished the entire hop list once before at 11/30/2013 20:00:00.

Bill<tab>10<tab>20<tab>1388555999<tab>1385863200

Let me know if you need more info.

Russell
Logged

Pro_Avia

  • Junior Member
  • **
  • Offline Offline
  • Posts: 25
    • FreedomAir Virtual Airlines
Re: Hop List Position File - format
« Reply #2 on: August 06, 2014, 05:09:44 PM »

Hi Russell

Thanks for the quick response and file format data!

I wasn't even thinking about Unix time while looking at the 10 digit number. And I've had to edit Unix time many times in our databases. The converter I use is at:
www.epochconverter.com
Just in case anyone else could use it.

Thanks again!
Gene
Logged

Russell Gilbert

  • Administrator
  • Guru
  • *****
  • Offline Offline
  • Posts: 1465
    • FSHost
Re: Hop List Position File - format
« Reply #3 on: August 06, 2014, 05:27:44 PM »

Thanks Gene.  I figured there must be a tool out there somewhere but had never come across one.

Russell
Logged
Pages: [1]   Go Up