Flight Log OXP

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Flight Log OXP

Post by Thargoid »

A little "by request" OXP (see here) that adds some extra functionality to the game.

It provides an extra screen to the info pages detailing the last 10 systems that the player has visited in the current galaxy, plus their current location. Once the OXP is installed, it is accessed by going to the ship's manifest (F5 or F5-F5) screen and from there accessing the short range chart (F6). This should display the list of systems visited.

The list will begin to populate as you fly around (it resets on galactic jump), and once it begins to fill up you can dump it to the latest.log and also manually reset it.

It will also log visits to interstellar space, and is persistent across game saves.

- - = = Download Flight Log OXP here = = - -
Last edited by Thargoid on Thu Jul 21, 2011 7:30 pm, edited 3 times in total.
User avatar
Gimi
---- E L I T E ----
---- E L I T E ----
Posts: 2073
Joined: Tue Aug 29, 2006 5:02 pm
Location: Norway

Post by Gimi »

Thank you very much!
"A brilliant game of blasting and trading... Truly a mega-game... The game of a lifetime."
(Gold Medal Award, Zzap!64 May 1985).
UK_Eliter
---- E L I T E ----
---- E L I T E ----
Posts: 1248
Joined: Sat Sep 12, 2009 11:58 pm
Location: Essex (mainly industrial and occasionally anarchic)

Post by UK_Eliter »

Dear Thargoid

Excellent! Thank you. And/but might I be cheeky and ask: how about including in the log what one bought where and for how much? Still, I am always asking for extra functions. So perhaps I should learn how to do such things myself!

Cheers.
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

That's not possible, as the prices of commodities aren't visible to Javascript (at least I don't think they are). Plus it would make the thing rather complicated and difficult to use, especially if multiple transactions are carried out.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Thargoid wrote:
That's not possible, as the prices of commodities aren't visible to Javascript (at least I don't think they are).
Could perhaps be done if there was an event handler firing whenever something is bought or sold.

On second thought, however, that would be rather clumsy, as you often buy and sell in single units.

And, of course, the objection of being rather complicated and difficult to use is still valid.
User avatar
Gimi
---- E L I T E ----
---- E L I T E ----
Posts: 2073
Joined: Tue Aug 29, 2006 5:02 pm
Location: Norway

Post by Gimi »

Is it possible to make a snapshot of cargo-hold content and funds when entering and leaving station. That would allow you to calculate earnings/loss on a run.
Also, can number of kills be logged providing a progress history.
"A brilliant game of blasting and trading... Truly a mega-game... The game of a lifetime."
(Gold Medal Award, Zzap!64 May 1985).
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

Gimi wrote:
Is it possible to make a snapshot of cargo-hold content and funds when entering and leaving station. That would allow you to calculate earnings/loss on a run.
Sure. In fact, most of this functionality makes for the scripting example in the documentation.
Gimi wrote:
Also, can number of kills be logged providing a progress history.
Sure. That's not more than a couple of lines of script. Hey, why don't you make it your first OXP? :wink:
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Gimi wrote:
Is it possible to make a snapshot of cargo-hold content and funds when entering and leaving station. That would allow you to calculate earnings/loss on a run.
Also, can number of kills be logged providing a progress history.
Buying (or selling) equipment would mess up monitoring during docking with/launching from stations, as would any mission which awarded a credit reward when docked or fines imposed by GalCop. My new HyperCargo system would also screw it up.

Something could be done triggered by entering and leaving the marketplace screen whilst docked though with suitable notes of credit levels on both occasions. Problem is telling runs apart, as you will normally buy and sell during the same visit to the marketplace screen.

It's a simple concept in theory, but in practice it would get horribly messy as there are so many things that can change the players credit levels.
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

How about recording cargo contract runs?
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Post by Commander McLane »

I can imagine that people like to record all sorts of stuff.

However, as Thargoid hinted at already, Oolite isn't currently designed to do that. The only ways to "record" something are to put it in the log-file, which is completely deleted the second-to-next time you start Oolite (and actually has completely different purposes); or the save-file, which—while it can be read in a text editor—isn't optimized to give comprehensive human-readable log information.

Thargoid's solution of creating sort of an extra screen while docked via a disguised mission screen which is accessible by going through a combination of GUI screens (F5 -> F6 in this case) is extremely clever (I imagine that's how he made it, I haven't actually downloaded and examined the OXP yet), but has its drawbacks as well: first, the capacity of a single Oolite text screen is quite limited; second, at the end of the day the number of possible combinations which can lead to various disguised mission screens is limited as well; and third, in the long run it may become annoying if you can't switch between the usual screens anymore, because every time some recording screen gets in-between.

All of that means that at least for the time being we have to live with Oolite's limited capacity to provide us with comprehensive pilot's log-book functions. Perhaps as an EMMSTRAN*-feature?


_______________

* Even More Mythical Stable Release After Next
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Yup spot on. I branched it out of the manifest screen (same as I did the other day for HyperCargo) as most people accessing that screen are just doing so for the information on it, rather than to go anywhere else (open it then go back to the status screen again). Hence it's a logical waypoint for a sequence (and Flight Log using short range chart and HyperCargo the marketplace screen makes intuitive sense too).

I don't think in these cases it'd get in the way of normal screen navigation, but that's just how I use them. Others may get different mileage.

But you are correct that it's by nature limited in scope (both what a screen can hold and also the number of "fake" screens that can be done), so I'd agree if this is something that people want then the functionality would be a candidate for inclusion into trunk on a more properly constructed way (possibly using the F4 key in some fashion?).

Oh and it's not just whilst docked. The flight log (and HyperCargo as well) works in-flight too. You just have to press F5 twice rather than once as the first one is needed to bring up the status screen when in-flight.
User avatar
Corny
---- E L I T E ----
---- E L I T E ----
Posts: 363
Joined: Sun Dec 20, 2009 11:50 am
Location: (northern) Germany

Post by Corny »

Thanks, Thargoid! I'm curious if that OXP will evolve further with Oolite. :)
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

I seem to be getting more than 10 systems listed...AND the menu for it gets screwed up in funny ways when it happens. :cry:
User avatar
Thargoid
Thargoid
Thargoid
Posts: 5528
Joined: Thu Jun 12, 2008 6:55 pm

Post by Thargoid »

Can you give me more details - what systems you've visited and what the screen looks like (presumably the text is flowing down underneath the menu options?).

Also if you can dump the content to your latest.log and paste that here (just the block labelled "FlightLog: ")
Switeck
---- E L I T E ----
---- E L I T E ----
Posts: 2411
Joined: Mon May 31, 2010 11:11 pm

Post by Switeck »

This is in the latest.log from it:

[FlightLog]: ==================================
[FlightLog]:
[FlightLog]: 29 - Atbevete
[FlightLog]: 28 - Tioranin
[FlightLog]: 27 - Teraed
[FlightLog]: 26 - Zasoceat
[FlightLog]: 25 - Rizala
[FlightLog]: 24 - Arexe
[FlightLog]: 23 - Geisgeza
[FlightLog]: 22 - Reesdice
[FlightLog]: 21 - Xezaor
[FlightLog]: 20 - Xeer
[FlightLog]: 19 - Solageon
[FlightLog]: 18 - Esusti
[FlightLog]: 17 - Zadies
[FlightLog]: 16 - Razaar
[FlightLog]: 15 - Maxeedso
[FlightLog]: 14 - Enonla
[FlightLog]: 13 - Biorle
[FlightLog]: 12 - Atrabiin
[FlightLog]: 11 - Rilace
[FlightLog]: 10 - Maregeis
[FlightLog]: 9 - Uscela
[FlightLog]: 8 - Terea
[FlightLog]: 7 - Tibionis
[FlightLog]: 6 - Laenin
[FlightLog]: 5 - Xexedi
[FlightLog]: 4 - Laenin
[FlightLog]: 3 - Oresri
[FlightLog]: 2 - Riiser
[FlightLog]: 1 - Riredi
[FlightLog]:
[FlightLog]: Current system - Eninre
[FlightLog]: ==================================

The text doesn't flow down past the menu so much as the menu simply isn't on the screen. Weirdly, the highlighted text is either:
13 - Biorle
12 - Atrabiin
11 - Rilace

With 13 corresponding to "Exit log" option,
12 corresponding to "Clear log" option,
and 11 is "Output to Latest.log" option.
(This is what they do when I hit enter on them.)
Post Reply