Hints OXZ (Development Thread)

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

Moderators: winston, another_commander

User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 4830
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Education

Post by phkb »

Cholmondely wrote: Sat Apr 23, 2022 9:51 pm
I'd like to start adding Hints for some of the other OXPs.
Here's one way (there's more than one). You would need to create a new entries in descriptions.plist for each OXP you have hints for.
eg:

Code: Select all

{
	"hints_bar_gossip" = 
	( 
	... 
	);
	
	"hints_bar_commies" = 
	(
	"SLAPU's have jolly good prices if you want to buy computers (etc)",
	);
	
	"hint_bar_dsd" = 
	(
	"I made a fortune selling food and liquors to one of these (etc)",
	);
}
Then you'd need to add code to potentially use a description from the commies set, rather than the default set.

Code: Select all

this.showBar = function () {
    // grab the text from the descriptions
    var text = expandDescription("[hints_bar_gossip]");
    var alternate = false;
    // is commies installed? if so, randomly pick one of those descriptions (5% chance)
    if (alternate == false && worldScripts["communist_population"] && Math.random() < 0.05) {text = expandDescription("[hints_bar_commies]"); alternate = true;}
    // is deepspace dredger installed? if we haven't already picked an alternate, possibly pick one now
    if (alternate == false && worldScripts["deep_space_dredger"] && Math.random() < 0.05) {text = expandDescription("[hints_bar_dsd]"); alternate = true;}
    // change 0.05 up or down to taste.
    var breakdown = this.processText(text);
    ... code continues from this point as is...
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

phkb wrote: Wed Apr 27, 2022 4:43 am
Cholmondely wrote: Sat Apr 23, 2022 9:51 pm
I'd like to start adding Hints for some of the other OXPs.
Here's one way (there's more than one). You would need to create a new entries in descriptions.plist for each OXP you have hints for.
eg:

Code: Select all

{
	"hints_bar_gossip" = 
	( 
	... 
	);
	
	"hints_bar_commies" = 
	(
	"SLAPU's have jolly good prices if you want to buy computers (etc)",
	);
	
	"hint_bar_dsd" = 
	(
	"I made a fortune selling food and liquors to one of these (etc)",
	);
}
Then you'd need to add code to potentially use a description from the commies set, rather than the default set.

Code: Select all

this.showBar = function () {
    // grab the text from the descriptions
    var text = expandDescription("[hints_bar_gossip]");
    var alternate = false;
    // is commies installed? if so, randomly pick one of those descriptions (5% chance)
    if (alternate == false && worldScripts["communist_population"] && Math.random() < 0.05) {text = expandDescription("[hints_bar_commies]"); alternate = true;}
    // is deepspace dredger installed? if we haven't already picked an alternate, possibly pick one now
    if (alternate == false && worldScripts["deep_space_dredger"] && Math.random() < 0.05) {text = expandDescription("[hints_bar_dsd]"); alternate = true;}
    // change 0.05 up or down to taste.
    var breakdown = this.processText(text);
    ... code continues from this point as is...
Thank you for this.

After my abject failure last week (too ambitious?), I finally got it to work!

the descriptions.plist above should read "hints_bar_dsd" =



As usual, I take your template, add just the one itsy-titsy-bitsy thing to it, and everything goes pear-shaped!

I've just tried adding cim's Ship's Library. I identified it using the "ingame-manual.js" listed in its world-scripts.plist. And his oxp works just fine in my game, but the associated hint never appears, despite boosting the probability to 90%! Where have I gone wrong this time?

Code: Select all

this.name           = "Hints_Station_Bar.js";
this.author         = "Cholmondely";
this.copyright      = "(C) 2022 Cholmondely";
this.licence        = "CC-NC-by-SA 4.0";
this.description    = "Adds a station bar where you might overhear useful tips";
this.version        = "0.0.93";

"use strict";

// LittleBear's comments: This script would let you give a randomly picked item each time. Although you might want to also add a timer so the messages change over time. You could also add tests for Government type, economy or station type so different items are overheard in different systems types and station types.

// Set Up your F4 Screen Option Like this:-

this.startUpComplete = this.shipDockedWithStation = function(station) {
this.barinterface();
}
this.removebar = this.shipWillLaunchFromStation = function() {
player.ship.dockedStation.setInterface("bar_chatter",null);
}

//  Now add your Visit the Bar Interface like this:- 

this.barinterface = function() {	
player.ship.dockedStation.setInterface("bar_chatter",{
title: "Visit the Station Bar",
category: "Activity",
summary: "Useful gossip can sometimes be overheard in the Bar",
callback: this.showBar.bind(this)});	
};

// Phkb's Set up to allow colour (from https://bb.oolite.space/viewtopic.php?p=283402#p283402)

//-------------------------------------------------------------------------------------------------------------
this.processText = function (text) {
    var final = [];
    var colors = [];
    var columnWidth = 32; // this is the maximum display width available
    var paras = text.split("\n");
    var color = "";
    for (var i = 0; i < paras.length; i++) {
        var line = "";
        // special case for a blank line
        if (paras[i].length == 0 && i < paras.length - 1) {
            final.push("");
            colors.push(color);
            continue;
        }
        var words = paras[i].split(" ");
        for (var j = 0; j < words.length; j++) {
            // look for a colour change
            if (words[j].indexOf("{color:") >= 0) {
                // get the color deinition
                color = words[j].substring(words[j].indexOf("{color:") + 7, words[j].indexOf("}"));
                if (color == "reset") color = ""; // check for a reset to set the color back to the default
                // remove the color definition from the word
                words[j] = words[j].substring(0, words[j].indexOf("{color:")) + words[j].substring(words[j].indexOf("}") + 1);
            }
            // can we fit this word into the line?
            if (defaultFont.measureString(line + " " + words[j]) > columnWidth) {
                final.push(line); // put the current line into the final array
                colors.push(color);
                line = ""; // clear the text
            }
            line += (line.length == 0 ? "" : " ") + words[j];
        }
        if (line.trim() != "") {
            final.push(line); // make sure any leftovers are put into the array
            colors.push(color);
            line = "";
        }
    }
    // return all the data we compiled in a dictionary
    return {
        lines: final,
        colors: colors
    };
}

//-------------------------------------------------------------------------------------------------------------
// returns true if a HUD with allowBigGUI is enabled, otherwise false
this.$isBigGuiActive = function $isBigGuiActive() {
	if (oolite.compareVersion("1.83") <= 0) {
		return player.ship.hudAllowsBigGui;
	} else {
		var bigGuiHUD = ["XenonHUD.plist", "coluber_hud_ch01-dock.plist"]; // until there is a property we can check, I'll be listing HUD's that have the allow_big_gui property set here
		if (bigGuiHUD.indexOf(player.ship.hud) >= 0) {
			return true;
		} else {
			return false;
		}
	}
}

// Now add this code so that when the Visit the Bar Option is selected Oolite will randomly pick one of the messages you have set up in descriptions. Version 0.93: This now includes PHKB's colour-tweaking additions. Version 0.94: This now includes PHKB's OXP hint-adding additions.

this.showBar = function () {
    // grab the text from the descriptions
    var text = expandDescription("[hints_bar_gossip]");
    var alternate = false;

// Phkb's Set up to allow OXP additions (from https://bb.oolite.space/viewtopic.php?p=283699#283699)
    if (alternate == false && worldScripts["ingame-manual"] && Math.random() < 0.90) {text = expandDescription("[hints_Ship's_Library]"); alternate = true;}
    // change 0.05 up or down to taste.
    var breakdown = this.processText(text);

// Back to his colour additions
    var defaultColor = "yellowColor";
    var displayLines = 26;
    if (this.$isBigGuiActive() == false) displayLines = 20;
    var choices = {};
    
    // add the text lines to the choices dictionary
    for (var i = 0; i < breakdown.lines.length; i++) {
        choices["line_" + (i < 10 ? "0" : "") + i.toString()] = {
            text: breakdown.lines[i],
            alignment: "LEFT",
            color: (breakdown.colors[i] == "" ? defaultColor : breakdown.colors[i]),
            unselectable: true
        }
    }
    // add some spacers to push the text to the top of the screen
    for (var i = 0; i < displayLines - breakdown.lines.length; i++) {
        choices["spacer" + i] = {
            text: "",
            unselectable: true
        }
    }
    // add a final choice to inform the player what to do next
    choices["z_end"] = {
        text: "Press enter to continue"
    }

    mission.runScreen({
        title: "The Local Bar",
        screenID: "show_bar",
        choices: choices,
        overlay: "litf_bg_localbar.png", //This adds the bar image behind the message
        exitScreen: "GUI_SCREEN_INTERFACES",
    })
}

descriptions.plist:

Code: Select all

{
"hints_bar_gossip" = //Vanilla game advice
	(
	"Young frog to older couple: 'So, Uncle Ferdie, tell me about Rock Hermits! Jerry told me that there two things to remember - that they are usually off the beaten path, but that they are usually massive and can be seen from a distance'  \n{color:greenColor}
	Older frog with gold monocle: 'Well, almost every system has at least one if not several. And they differ. Some sit on one of the space lanes, others not. Some are dangerous to approach - surrounded or guarded by pirates, others are just harmless miners.'  \n{color:yellowColor}
	Young frog: 'My chum Switeck told me that you find them by looking for the movement of a distant point-of-light while whizzing around on torus and then you can initially spot them or other large stations'  \n{color:greenColor}
	Older frog with monocle: 'If you see a ship heading away from the spacelane, it's probably en route to a rock hermit.'  \n{color:redColor}
	Older frog with yellow cap: 'Some folk say they have a secret network, and control the black markets.'  \n{color:yellowColor}
	Young frog: 'Those must be the pirate-infested ones then'  \n{color:redColor}
	Older frog with yellow cap: 'I never heard that, but it seems a good guess...' ",

);

"hints_Ship's_Library" =
	(
	"You can get the Ship's Manual to appear in an MFD if your HUD supports them. That way you can read it as you fly! You cycle the current MFD with the ';' key on your astrogation console, and select the appropriate MFD with the ':' key"
	);
}
I get the frogs every time!
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 4830
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Education

Post by phkb »

Cholmondely wrote: Sun May 01, 2022 12:40 pm
I've just tried adding cim's Ship's Library. I identified it using the "ingame-manual.js" listed in its world-scripts.plist
The reference you actually want is from the header part of the "ingame-manual.js" file:

Code: Select all

"use strict";
this.author      = "cim"; 
this.copyright   = "� 2011-2014 cim."; 
this.licence = "CC-BY-SA 3.0";
this.version     = "0.8"; 
this.name = "Ships Library";   << this is the thing you need
this.description = "An e-book library readable on the F4 screen";
You need to use "Ships Library", not "ingame-manual.js".
So your code should be

Code: Select all

    if (alternate == false && worldScripts["Ships Library"] && Math.random() < 0.90) {text = expandDescription("[hints_Ship's_Library]"); alternate = true;}
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

LittleBear wrote: Thu Jan 06, 2022 2:45 pm
I think news broadcasts with GNN would be quite an immersive way of introducing these sort of things. Information about missions at special stations could be done with a news item reporting on the fact. Guidance on how to do cargo contracts could be given indirectly by the news reporting on the mis-fortunes of a commander who made a mess of it (sued, assassins sent after him or just a paid for content item by the disgruntled client as to how useless he is). GNN's OXZ does the donkey work, so a simple script like this will feed news items to it over time:

Under this.startupcomplete set up a news variable as 0 if not already defined. This gives you an easy way to check that each news item in your script is only given once. Under exiting.hyperspace increment a timer each time a jump is made so you can spread out the flavour news items so they don't pop up all at once. Ummm.... how do I do this?

Then you just need a test (text?) like this under exiting hyperspace:-

Code: Select all

// Send the 2nd (Rooters) Broadcast to GNN.- Is Sent as a Priority 1 once 4 jumps have been made since Broadcast 1 was sent.
if (missionVariables.random_station_names_news === 2 &&  missionVariables.random_station_names_timer > 3) {
missionVariables.random_station_names_timer = 0;
var news = new Object;
news.ID = this.name;
news.Message = expandDescription("[random_station_names_2_news]");
news.Agency = 2;
news.Priority = 1;
this.passScreen(news,1); 
// The same method is used as above.
}
// Send the 3rd (Tionisla Chronicle) Broadcast to GNN.- Is Sent as a Priority 1 once 6 jumps have been made since Broadcast 2 was sent.
if (missionVariables.random_station_names_news === 3 &&  missionVariables.random_station_names_timer > 5) {
missionVariables.random_station_names_timer = 0;
var news = new Object;
news.ID = this.name;
news.Message = expandDescription("[random_station_names_3_news]");
news.Agency = 4;
news.Priority = 1;
this.passScreen(news,1); 
// The same method is used as above.
}

And so on for however many news broadcasts you want to write.
Now copy and past in the function below (where?) to send the news items to GNN when the conditions are met:

Code: Select all

this.passScreen = function(news,mode)
{var a = worldScripts.GNN._insertNews(news);
if(!a){ if(mode) missionVariables.random_station_names_news++;  // If GNN conforms sucess, advance the News Counting variable to the next Broadcast.
return;
} else {if(a<0){ // If the buffer was full then the mission variable counting the News Broadcasts wasn't advanced. Once the player has made the required number of jumps Random Station names will check again.
return;
}}}
That's all you need by way of a script.

In a descriptions file write the text for your news broadcasts. All you need is a:-

Code: Select all

"random_station_names_1_news" = "Type in your text!";
"random_station_names_2_news" = "Type in your text for the next one";

And so on for however many broadcasts you want to send.
 
Alas, I just don't understand this. The code by itself doesn't work, and I know too little about programming to decipher the instructions.

And my current descriptions.plist is full of bar talk. Do I need a separate file for the new bulletins?

I now have some 9 broadcasts which I'd like to include.

//• Interview of Chap reaching Elite status and giving manouever he used
//Usge Ceanal has just attained Elite status according to a press release from the Elite Federation. In an interview, Ceanal said that he was an advocate of the Barkanion Bounce (named after the renowned Lave Academician) - swirling in loops towards his opposition whilst varying his speed. This tactic enables a trouble-free approach to one’s targets, and accounted for many hundreds of his kills.

//• Rock hermit destroyed in anarchy (a Pirate Cove)
//A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, "the Old Worlds are now as safe as a parentally-patrolled paddling pool!".

//• Pirates nab chap on milk run Ensoreus-Ararus Furs-Computers: turns out to be a millionaire
//Reports are just coming in about Orit Ceedthse, an Ensorean trader was murdered at Ararus yesterday by marauding pirates. It turns out that the feline was phenomenally rich, due to trading in furs and computers between Ensoreus and Ararus. Was she killed for her cargo, her money or for more murky misdemeanours? Truth is, we don’t know!

//• Quirium Cascade mishap
//A quirium cascade bomb has been detonated at Qubeen. It caught some 27 ships and a rock hermit as well as the launcher of the bomb, a rodent from nearby Maesin. Inquiries are ongoing into the exact cause of the incident. GalCop is offering handsome rewards for relevant information.

//• Flavour text
//• Murgh the Munificent, the Metropolitan of Maduro, in the Middle Oceans of Aronar, has been promoted to be the Sectoral Sacerdote for the Church of Giles the Creator. A devotee of fine wines, he is rumoured to have crepuscular connections in the ship-building industry as well as having links to the "Cuban Cohort", a mysterious group of musical mayhem-makers. He has for some time been threatening to lead a crusade against the Witchspace Lobster Worshippers. Watch this space!

//•Contracts
//Arquebus the Audacious, the master trader, has finally come a cropper! After years of amassing a fortune trading in furs and computers, he took a time-sensitive contract to deliver wodgets to Ceesxe. Forgetting that fewer long jumps take much more time than many more smaller jumps, he arrived several days too late - and lost well over thirty thousand credits as a result! He is rumoured to have sold his ship in disgust and retired to a life of farming trumbles!

//• Flavour text
// Archimandrite Phi Ku'ub of the Digebitian Antipodes has just published a new commentary on the treatise on Theological Arithmetics by Saint Phibo Nacci. Combined with his earlier analysis of the mystical fourth codicil of the Codex of Giles the Creator, Phi Ku'ub claims to prove that the ooniverse was designed through random purposefulness, and show the numerical underpinnings of all that exists. Copies of his masterpiece have been selling like hotcakes! But does anybody actually understand it? Truth is, we don't know - and neither does anyone else!

//• Cim's changes to safe systems
//Pirates travelling from their home system to raid another are becoming more of a threat. On the one hand, Police vipers at Diso have fought off another incursion of some several dozen pirates from the local anarchies, Uszaa and Reidquat. The President of Diso has appealed to GalCop for more help in stabilising the local region. On the other hand, Ensoreus has been raided by ravenous hordes from Ararus, Zaalela and Xeesle.

//• Pirates have ECM
//The number of pirates armed with Electronic Counter Measures is increasing. Arch-Chandler RedSpear of GalCop's weapons research laboratory at Ceesxe has confirmed that more and more pirates are now using ECM in combat: "Do not fire missiles at pirates grouped in clusters of four or more, or you will waste them. At least one of them will be able to destroy your missiles" he told our reporters this morning.
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 4830
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Education

Post by phkb »

Cholmondely wrote: Thu May 05, 2022 3:21 pm
Do I need a separate file for the new bulletins?
Not a separate file, as you can only have one descriptions.plist per OXP. A separate key (or keys) inside descriptions.plist.
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

I'm getting this error message (from Terminal on the AppleMac running plutil, a .plist checker):

2022-05-06 16:26:14.885 plutil[27027:223702] CFPropertyListCreateFromXMLData(): Old-style plist parser: missing semicolon in dictionary on line 9. Parsing will be abandoned. Break on _CFPropertyListMissingSemicolon to debug.
/Users/accountname/Library/Application Support/Oolite/AddOns/oolite.oxp.cholmondely.Hints.0.094 GNN only.oxp/Config/descriptions.plist: Unexpected character { at line 1

For this descriptions.plist

Code: Select all

   {
    //• Interview of Chap reaching Elite status and giving manouever he used
    "education_news_1" = "Usge Ceanal has just attained Elite status according to a press release from the Elite Federation. In an interview, Ceanal said that he was an advocate of the Barkanion Bounce (named after the renowned Lave Academician) - swirling in loops towards his opposition whilst varying his speed. This tactic enables a trouble-free approach to one’s targets, and accounted for many hundreds of his kills.";

    //• Rock hermit destroyed in anarchy (a Pirate Cove)
    "education_news_2" = "A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, \"the Old Worlds are now as safe as a parentally-patrolled paddling pool!\";

    //• Pirates nab chap on milk run Ensoreus-Ararus Furs-Computers: turns out to be a millionaire
    "education_news_3" = "Reports are just coming in about Orit Ceedthse, an Ensorean trader was murdered at Ararus yesterday by marauding pirates. It turns out that the feline was phenomenally rich, due to trading in furs and computers between Ensoreus and Ararus. Was she killed for her cargo, her money or for more murky misdemeanours? Truth is, we don’t know!";

    //• Quirium Cascade mishap
    "education_news_4" = "A quirium cascade bomb has been detonated at Qubeen. It caught some 27 ships and a rock hermit as well as the launcher of the bomb, a rodent from nearby Maesin. Inquiries are ongoing into the exact cause of the incident. GalCop is offering handsome rewards for relevant information.";

    //• Flavour text
    "education_news_5" = "Murgh the Munificent, the Metropolitan of Maduro, in the Middle Oceans of Aronar, has been promoted to be the Sectoral Sacerdote for the Church of Giles the Creator. A devotee of fine wines, he is rumoured to have crepuscular connections in the ship-building industry as well as having links to the \"Cuban Cohort\", a mysterious group of musical mayhem-makers. He has for some time been threatening to lead a crusade against the Witchspace Lobster Worshippers. Watch this space!";

    //• Pirates have ECM
    "education_news_6" = "The number of pirates armed with Electronic Counter Measures is increasing. Arch-Chandler RedSpear of GalCop's weapons research laboratory at Ceesxe has confirmed that more and more pirates are now using ECM in combat: "Do not fire missiles at pirates grouped in clusters of four or more, or you will waste them. At least one of them will be able to destroy your missiles" he told our reporters this morning.";
    
    //• Flavour text
    "education_news_7" = "Archimandrite Ph'i Ku'ub of the Digebitian antipodes has just published a new commentary on the treatise on Theological Arithmetics by Saint Phibo Nacci. Combined with his earlier analysis of the mystical fourth codicil of the Codex of Giles the Creator, Ph'i Ku'ub claims to prove that the ooniverse was designed through random purposefulness, and show the numerical underpinnings of all that exists. Copies of his masterpiece have been selling like hotcakes! But does anybody actually understand it? Truth is, we don't know - and neither does anyone else!";

    //• Cim's changes to safe systems
    "education_news_8" = "Pirates travelling from their home system to raid another are becoming more of a threat. On the one hand, Police vipers at Diso have fought off another incursion of some several dozen pirates from the local anarchies, Uszaa and Reidquat. The President of Diso has appealed to GalCop for more help in stabilising the local region. On the other hand, Ensoreus has been raided by ravenous hordes from Ararus, Zaalela and Xeesle.";

    //•Contracts
    "education_news_9" = "Arquebus the Audacious, the master trader, has finally come a cropper! After years of amassing a fortune trading in furs and computers, he took a time-sensitive contract to deliver wodgets to Ceesxe. Forgetting that fewer long jumps take much more time than many more smaller jumps, he arrived several days too late - and lost well over thirty thousand credits as a result! He is rumoured to have sold his ship in disgust and retired to a life of farming trumbles!";

}   
I don't see the missing semi-colon. Or anything else which seems wrong.
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Slartibartfast
Deadly
Deadly
Posts: 175
Joined: Mon Jan 21, 2008 3:54 pm

Re: Education

Post by Slartibartfast »

hi

in the line after //• Pirates have ECM
there are six " ( 4 after the = )
maybe 2 should be \"

matthias
Oolite 1.91 / Imp. Trader ( slighly modified :wink: ) on Lubuntu 22.04 LTS on AMD64 2x 3800+ ,
ATI Radeon R7240 XFS / Samsung TV 40" 1080p
C-Media CMI8738 / Yamaha RX-V575 / DIY-Speaker
Logitech Attack3 & standard german keyboard
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

Ummmm...

Support/Oolite/AddOns/oolite.oxp.cholmondely.Hints.0.094\ GNN\ only.oxp/Config/descriptions.plist
2022-05-06 19:21:40.170 plutil[32993:281717] CFPropertyListCreateFromXMLData(): Old-style plist parser: missing semicolon in dictionary on line 9. Parsing will be abandoned. Break on _CFPropertyListMissingSemicolon to debug.
/Users/accountname/Library/Application Support/Oolite/AddOns/oolite.oxp.cholmondely.Hints.0.094 GNN only.oxp/Config/descriptions.plist: Unexpected character { at line 1

For the Slartibartfasticated

Code: Select all

  {
    //• Interview of Chap reaching Elite status and giving manouever he used
    "education_news_1" = "Usge Ceanal has just attained Elite status according to a press release from the Elite Federation. In an interview, Ceanal said that he was an advocate of the Barkanion Bounce (named after the renowned Lave Academician) - swirling in loops towards his opposition whilst varying his speed. This tactic enables a trouble-free approach to one’s targets, and accounted for many hundreds of his kills.";

    //• Rock hermit destroyed in anarchy (a Pirate Cove)
    "education_news_2" = "A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, \"the Old Worlds are now as safe as a parentally-patrolled paddling pool!\";

    //• Pirates nab chap on milk run Ensoreus-Ararus Furs-Computers: turns out to be a millionaire
    "education_news_3" = "Reports are just coming in about Orit Ceedthse, an Ensorean trader was murdered at Ararus yesterday by marauding pirates. It turns out that the feline was phenomenally rich, due to trading in furs and computers between Ensoreus and Ararus. Was she killed for her cargo, her money or for more murky misdemeanours? Truth is, we don’t know!";

    //• Quirium Cascade mishap
    "education_news_4" = "A quirium cascade bomb has been detonated at Qubeen. It caught some 27 ships and a rock hermit as well as the launcher of the bomb, a rodent from nearby Maesin. Inquiries are ongoing into the exact cause of the incident. GalCop is offering handsome rewards for relevant information.";

    //• Flavour text
    "education_news_5" = "Murgh the Munificent, the Metropolitan of Maduro, in the Middle Oceans of Aronar, has been promoted to be the Sectoral Sacerdote for the Church of Giles the Creator. A devotee of fine wines, he is rumoured to have crepuscular connections in the ship-building industry as well as having links to the \"Cuban Cohort\", a mysterious group of musical mayhem-makers. He has for some time been threatening to lead a crusade against the Witchspace Lobster Worshippers. Watch this space!";

    //• Pirates have ECM
    "education_news_6" = "The number of pirates armed with Electronic Counter Measures is increasing. Arch-Chandler RedSpear of GalCop's weapons research laboratory at Ceesxe has confirmed that more and more pirates are now using ECM in combat: \"Do not fire missiles at pirates grouped in clusters of four or more, or you will waste them. At least one of them will be able to destroy your missiles\" he told our reporters this morning.";
    
    //• Flavour text
    "education_news_7" = "Archimandrite Ph'i Ku'ub of the Digebitian antipodes has just published a new commentary on the treatise on Theological Arithmetics by Saint Phibo Nacci. Combined with his earlier analysis of the mystical fourth codicil of the Codex of Giles the Creator, Ph'i Ku'ub claims to prove that the ooniverse was designed through random purposefulness, and show the numerical underpinnings of all that exists. Copies of his masterpiece have been selling like hotcakes! But does anybody actually understand it? Truth is, we don't know - and neither does anyone else!";

    //• Cim's changes to safe systems
    "education_news_8" = "Pirates travelling from their home system to raid another are becoming more of a threat. On the one hand, Police vipers at Diso have fought off another incursion of some several dozen pirates from the local anarchies, Uszaa and Reidquat. The President of Diso has appealed to GalCop for more help in stabilising the local region. On the other hand, Ensoreus has been raided by ravenous hordes from Ararus, Zaalela and Xeesle.";

    //•Contracts
    "education_news_9" = "Arquebus the Audacious, the master trader, has finally come a cropper! After years of amassing a fortune trading in furs and computers, he took a time-sensitive contract to deliver wodgets to Ceesxe. Forgetting that fewer long jumps take much more time than many more smaller jumps, he arrived several days too late - and lost well over thirty thousand credits as a result! He is rumoured to have sold his ship in disgust and retired to a life of farming trumbles!";

}  
What fun!
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Slartibartfast
Deadly
Deadly
Posts: 175
Joined: Mon Jan 21, 2008 3:54 pm

Re: Education

Post by Slartibartfast »

Hi

afair the \ deactivates the following

if that is correct here s also something wrong

"education_news_2" = "A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, \"the Old Worlds are now as safe as a parentally-patrolled paddling pool!\";

matthias
Oolite 1.91 / Imp. Trader ( slighly modified :wink: ) on Lubuntu 22.04 LTS on AMD64 2x 3800+ ,
ATI Radeon R7240 XFS / Samsung TV 40" 1080p
C-Media CMI8738 / Yamaha RX-V575 / DIY-Speaker
Logitech Attack3 & standard german keyboard
User avatar
Slartibartfast
Deadly
Deadly
Posts: 175
Joined: Mon Jan 21, 2008 3:54 pm

Re: Education

Post by Slartibartfast »

example ( linux / bash )

Code: Select all

mattes@Pille:~$ echo "\""
"
mattes@Pille:~$ 
Oolite 1.91 / Imp. Trader ( slighly modified :wink: ) on Lubuntu 22.04 LTS on AMD64 2x 3800+ ,
ATI Radeon R7240 XFS / Samsung TV 40" 1080p
C-Media CMI8738 / Yamaha RX-V575 / DIY-Speaker
Logitech Attack3 & standard german keyboard
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

Slartibartfast wrote: Fri May 06, 2022 6:34 pm
Hi

afair the \ deactivates the following

if that is correct here s also something wrong

"education_news_2" = "A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, \"the Old Worlds are now as safe as a parentally-patrolled paddling pool!\";

matthias
You, Sir, are a genius!

I'll tell cousin Digby all about you, and he'll get them to double your salary immediately!

There were also two wrong double quotations (curly ones), as well as a \"; which needed to be a \" ";
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
Slartibartfast
Deadly
Deadly
Posts: 175
Joined: Mon Jan 21, 2008 3:54 pm

Re: Education

Post by Slartibartfast »

hi

no genius -- more a "burned child" :wink:

cheers
Oolite 1.91 / Imp. Trader ( slighly modified :wink: ) on Lubuntu 22.04 LTS on AMD64 2x 3800+ ,
ATI Radeon R7240 XFS / Samsung TV 40" 1080p
C-Media CMI8738 / Yamaha RX-V575 / DIY-Speaker
Logitech Attack3 & standard german keyboard
User avatar
Cody
Sharp Shooter Spam Assassin
Sharp Shooter Spam Assassin
Posts: 16081
Joined: Sat Jul 04, 2009 9:31 pm
Location: The Lizard's Claw
Contact:

Re: Education

Post by Cody »

Slartibartfast wrote: Fri May 06, 2022 6:54 pm
Logitech Attack3
Just noticed that. I used an Attack3 for years - an excellent budget stick (and ambidextrous too).
I would advise stilts for the quagmires, and camels for the snowy hills
And any survivors, their debts I will certainly pay. There's always a way!
User avatar
Cholmondely
Archivist
Archivist
Posts: 5364
Joined: Tue Jul 07, 2020 11:00 am
Location: The Delightful Domains of His Most Britannic Majesty (industrial? agricultural? mainly anything?)
Contact:

Re: Education

Post by Cholmondely »

So both bits of this one are acting up.

I bunged in numbered "Got here's" at various stages in the code.

Latest Log:

Code: Select all

Opening log for Oolite development version 1.91.0-220208 (x86-64 test release) under Mac OS X Version 10.15.3 (Build 19D2064) at 2022-05-09 22:33:57 +0000.
Machine type: MacBookAir9,1, 8192 MiB memory, 2 (4 logical) x x86 (family 0x38435547) @ 1100 MHz.
Build options: OpenAL, new planets, JavaScript console support, Debug plug-in support, OXP verifier, localization tools, debug GraphViz support, JavaScript profiling.

Note that the contents of the log file can be adjusted by editing logcontrol.plist.

23:33:58.652 [dataCache.rebuild.pathsChanged] +[ResourceManager checkCacheUpToDateForPaths:] (ResourceManager.m:1156): Cache is stale (search paths have changed). Rebuilding from scratch.
23:33:58.935 [joystick.error.init] -[OOMacJoystickManager init] (OOMacJoystickManager.m:80): Cannot open HID manager; joystick support will not function.
23:33:58.935 [rendering.opengl.version] -[OOOpenGLExtensionManager reset] (OOOpenGLExtensionManager.m:221): OpenGL renderer version: 2.1.0 ("2.1 INTEL-14.4.26"). Vendor: "Intel Inc.". Renderer: "Intel(R) Iris(TM) Plus Graphics OpenGL Engine (1x6x8 (fused) LP".
23:33:58.935 [rendering.opengl.extensions] -[OOOpenGLExtensionManager reset] (OOOpenGLExtensionManager.m:222): OpenGL extensions (128):
GL_EXT_texture_compression_dxt1, GL_EXT_rescale_normal, GL_EXT_transform_feedback, GL_EXT_blend_func_separate, GL_EXT_framebuffer_sRGB, GL_ATI_texture_env_combine3, GL_ARB_draw_elements_base_vertex, GL_EXT_debug_label, GL_EXT_geometry_shader4, GL_EXT_secondary_color, GL_EXT_separate_specular_color, GL_EXT_shadow_funcs, GL_NV_texgen_reflection, GL_NV_blend_square, GL_ARB_texture_compression_rgtc, GL_EXT_stencil_wrap, GL_ARB_texture_env_crossbar, GL_EXT_framebuffer_blit, GL_ATI_separate_stencil, GL_APPLE_vertex_point_size, GL_EXT_texture_rectangle, GL_APPLE_specular_vector, GL_EXT_packed_depth_stencil, GL_EXT_blend_color, GL_ARB_fragment_program_shadow, GL_EXT_texture_env_add, GL_EXT_provoking_vertex, GL_EXT_texture_array, GL_ARB_texture_env_combine, GL_ARB_point_sprite, GL_ARB_multisample, GL_EXT_framebuffer_object, GL_ARB_framebuffer_sRGB, GL_EXT_texture_lod_bias, GL_APPLE_pixel_buffer, GL_ARB_vertex_program, GL_EXT_bgra, GL_APPLE_fence, GL_APPLE_ycbcr_422, GL_EXT_timer_query, GL_EXT_vertex_array_bgra, GL_ARB_depth_clamp, GL_IBM_rasterpos_clip, GL_ARB_pixel_buffer_object, GL_SGIS_generate_mipmap, GL_EXT_framebuffer_multisample_blit_scaled, GL_ARB_shader_texture_lod, GL_ARB_texture_float, GL_ARB_texture_rectangle, GL_ARB_vertex_shader, GL_NV_texture_barrier, GL_ARB_provoking_vertex, GL_ARB_texture_env_add, GL_APPLE_object_purgeable, GL_ARB_texture_env_dot3, GL_APPLE_rgb_422, GL_NV_depth_clamp, GL_ARB_texture_mirrored_repeat, GL_ARB_texture_cube_map, GL_APPLE_element_array, GL_ATI_texture_float, GL_ARB_window_pos, GL_ARB_sync, GL_ARB_vertex_buffer_object, GL_APPLE_texture_range, GL_NV_conditional_render, GL_EXT_stencil_two_side, GL_ARB_texture_compression, GL_ARB_instanced_arrays, GL_EXT_blend_minmax, GL_ARB_texture_border_clamp, GL_EXT_draw_buffers2, GL_ARB_shading_language_100, GL_EXT_blend_equation_separate, GL_ARB_vertex_blend, GL_EXT_blend_subtract, GL_EXT_packed_float, GL_APPLE_aux_depth_stencil, GL_APPLE_row_bytes, GL_NV_light_max_exponent, GL_EXT_abgr, GL_EXT_texture_filter_anisotropic, GL_ARB_vertex_array_bgra, GL_ARB_draw_buffers, GL_ARB_transpose_matrix, GL_ARB_color_buffer_float, GL_EXT_gpu_program_parameters, GL_APPLE_client_storage, GL_ARB_texture_non_power_of_two, GL_ARB_multitexture, GL_EXT_gpu_shader4, GL_APPLE_flush_render, GL_ARB_framebuffer_object, GL_APPLE_vertex_program_evaluators, GL_APPLE_transform_hint, GL_EXT_texture_compression_s3tc, GL_APPLE_flush_buffer_range, GL_EXT_texture_integer, GL_SGIS_texture_edge_clamp, GL_NV_fog_distance, GL_ARB_occlusion_query, GL_ARB_fragment_shader, GL_ARB_texture_rg, GL_ARB_fragment_program, GL_ARB_seamless_cube_map, GL_ARB_shader_objects, GL_EXT_draw_range_elements, GL_APPLE_vertex_array_object, GL_ARB_depth_texture, GL_EXT_texture_sRGB, GL_ARB_half_float_vertex, GL_APPLE_vertex_array_range, GL_ARB_shadow, GL_EXT_multi_draw_arrays, GL_ARB_half_float_pixel, GL_APPLE_packed_pixels, GL_ARB_point_parameters, GL_EXT_debug_marker, GL_EXT_texture_sRGB_decode, GL_EXT_clip_volume_hint, GL_SGIS_texture_lod, GL_EXT_fog_coord, GL_EXT_texture_shared_exponent, GL_ATI_texture_mirror_once, GL_APPLE_float_pixels, GL_EXT_framebuffer_multisample, GL_ARB_depth_buffer_float, GL_ARB_draw_instanced
23:33:58.992 [rendering.opengl.shader.support] -[OOOpenGLExtensionManager reset] (OOOpenGLExtensionManager.m:256): Shaders are supported.
23:33:59.042 [dataCache.rebuild.pathsChanged] +[ResourceManager checkCacheUpToDateForPaths:] (ResourceManager.m:1156): Cache is stale (search paths have changed). Rebuilding from scratch.
23:33:59.046 [searchPaths.dumpAll] +[ResourceManager logPaths] (ResourceManager.m:2240): Resource paths: 
    /var/folders/6s/ysb64pns7r3472gl73j4zsnc0000gn/T/AppTranslocation/32E9F699-A51C-4CA4-8105-660DC5ACC6DD/d/Oolite 1.91.app/Contents/Resources
    ~/Library/Application Support/Oolite/Managed AddOns
    ~/Library/Application Support/Oolite/AddOns
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Thargoid.Planetfall.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.spara.market_observer.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Svengali.Library.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/FontDangerousSquare.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Norby.LogEvents.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.spara.market_inquirer.oxp
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Svengali.BGS.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Svengali.GNN.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.ramirez.Feudal_States.oxz
    ~/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Svengali.Pagroove.BGSSoundset.oxz
    ~/Library/Application Support/Oolite/AddOns/oolite.oxp.cholmondely.Hints.0.094 everything.oxp
23:33:59.127 [shipData.load.begin] +[OOShipRegistry(Singleton) allocWithZone:] (OOShipRegistry.m:1698): Loading ship data.
23:34:00.385 [startup.complete] -[GameController applicationDidFinishLaunching:] (GameController.m:269): ========== Loading complete in 1.64 seconds. ==========
23:34:06.129 [shipData.load.begin] +[OOShipRegistry(Singleton) allocWithZone:] (OOShipRegistry.m:1698): Loading ship data.
23:34:06.728 [oxp-standards.deprecated] OOStandardsInternal (OODebugStandards.m:92): Script /Users/accountname/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Thargoid.Planetfall.oxz/Scripts/planetFall_worldScript.js does not "use strict";
23:34:06.907 [oxp-standards.deprecated] OOStandardsInternal (OODebugStandards.m:92): Script /Users/accountname/Library/Application Support/Oolite/Managed AddOns/oolite.oxp.Svengali.Pagroove.BGSSoundset.oxz/Config/script.js does not "use strict";
23:34:06.910 [script.load.world.listAll] +[ResourceManager loadScripts] (ResourceManager.m:2132): Loaded 48 world scripts:
    BGS 2.5.3
    BGS-PAGsoundsetv2 2.3
    Education_GNN.js 0.9.0
    feudal-challenge.js 9.1
    feudal-mission.js 9.1
    feudal-planetfall.js 3.1
    feudal-promotion.js 6.1
    feudal-ranks.js 5.1
    feudal-tournament.js 10.1
    GNN 1.2
    GNN_PhraseGen 1.2
    GNN_Words 1.2
    Hints_Station_Bar.js 0.0.93
    Lib_2DCollision 1.7.1
    Lib_Animator 1.7.1
    Lib_BinSearch 1.7.1
    Lib_Config 1.7.1
    Lib_Crypt 1.7.1
    Lib_Cubecode 1.7.1
    Lib_EntityStrength 1.7.1
    Lib_GUI 1.7.1
    Lib_Main 1.7.1
    Lib_MissionCoord 1.7.1
    Lib_Music 1.7.1
    Lib_PAD 1.7.1
    Lib_PAD_Events 1.7.1
    Lib_Starmap 1.7.1
    logevents 1.4
    market_inquirer 1.14.1
    market_observer3 3.7
    mo-traders_rating3 3.7
    Oolite Equipment Control 1.91
    Oolite Ship Library 1.91
    oolite-cloaking-device 1.91
    oolite-constrictor-hunt 1.91
    oolite-contracts-cargo 1.91
    oolite-contracts-helpers 1.91
    oolite-contracts-parcels 1.91
    oolite-contracts-passengers 1.91
    oolite-libPriorityAI 1.91
    oolite-nova 1.91
    oolite-populator 1.91
    oolite-primable-equipment-register 1.91
    oolite-registership 1.91
    oolite-thargoid-plans 1.91
    oolite-trumbles 1.91
    oolite-tutorial 1.91
    PlanetFall 1.51
23:34:06.927 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_FUEL_SCOOPS
23:34:06.927 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_ESCAPE_POD
23:34:06.933 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_SHIELD_BOOSTER
23:34:06.933 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_TARGET_MEMORY
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_PLANETFALL
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_INTEGRATED_TARGETING_SYSTEM
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_ADVANCED_COMPASS
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_MARKET_INQUIRER_MFD
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_CLOAKING_DEVICE
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_FUEL_SCOOPS
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_DOCK_COMP
23:34:06.934 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_SCANNER_SHOW_MISSILE_TARGET
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_ESCAPE_POD
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_FUEL_INJECTION
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_CARGO_BAY
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_NAVAL_SHIELD_BOOSTER
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_HEAT_SHIELD
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_ADVANCED_NAVIGATIONAL_ARRAY
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_GAL_DRIVE
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_NAVAL_ENERGY_UNIT
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_WORMHOLE_SCANNER
23:34:06.935 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_ECM
23:34:06.936 [LogEvents] GlobalLog (OOJSGlobal.m:266): ship got EQ_MULTI_TARGET
23:34:07.857 [LogEvents] GlobalLog (OOJSGlobal.m:266): Populators:
 {"oolite-thargoid-scouts":{"priority":40,"location":"LANE_WPS","groupCount":1},
  "oolite-hunters-route1":{"priority":40,"location":"LANE_WP","groupCount":1},
  "oolite-pirate-independent-route1":{"priority":40,"location":"LANE_WP","groupCount":1},
  "oolite-pirate-independent-route2":{"priority":40,"location":"LANE_PS","groupCount":1},
  "oolite-pirate-independent-route3":{"priority":40,"location":"LANE_WS","groupCount":0},
  "oolite-route1-asteroids":{"groupCount":0,"deterministic":1,"priority":20,"location":"LANE_WP","locationSeed":51728},
  "oolite-police-route1":{"priority":40,"location":"LANE_WP","groupCount":2},
  "oolite-interceptors-witchpoint":{"priority":40,"location":"WITCHPOINT","groupCount":0},
  "oolite-pirate-medium-remote":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-couriers-route3":{"priority":40,"location":"LANE_WS","groupCount":0},
  "oolite-interceptors-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-pirate-medium-triangle":{"priority":40,"location":"LANE_WPS","groupCount":0},
  "oolite-pirate-light-remote":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-freighters-docking":{"priority":40,"location":"STATION_AEGIS","groupCount":0},
  "oolite-freighters":{"priority":40,"location":"LANE_WP","groupCount":3},
  "oolite-hunters-medium-route3":{"priority":40,"location":"LANE_WS","groupCount":0},
  "oolite-couriers-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-route2-asteroids":{"groupCount":2,"deterministic":1,"priority":20,"location":"LANE_PS","locationSeed":82715},
  "oolite-hunters-medium-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-smugglers":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-pirate-heavy-remote":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-pirate-light-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-offlane-hermit":{"groupCount":1,"deterministic":1,"priority":99,"location":"PLANET_ORBIT_HIGH","locationSeed":71258},
  "oolite-hunters-triangle":{"priority":40,"location":"LANE_WPS","groupCount":0},
  "oolite-pirate-heavy-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-police-triangle":{"priority":40,"location":"LANE_WPS","groupCount":0},
  "oolite-police-stationpatrol":{"location":"STATION_AEGIS","priority":40},
  "oolite-hunters-heavy-route3":{"priority":40,"location":"LANE_WS","groupCount":0},
  "oolite-hunters-heavy-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-thargoid-strike":{"priority":40,"location":"LANE_WPS","groupCount":0},
  "oolite-pirate-medium-route1":{"priority":40,"location":"LANE_WP","groupCount":0},
  "oolite-pirate-heavy-triangle":{"priority":40,"location":"LANE_WPS","groupCount":0},
  "oolite-nav-buoy":{"deterministic":1,"coordinates":[-29962.3203125,32725.83984375,302050.25],"priority":5,"location":"COORDINATES"},
  "oolite-assassins":{"priority":40,"location":"WITCHPOINT","groupCount":0},
  "oolite-witch-buoy":{"deterministic":1,"priority":10,"location":"COORDINATES","coordinates":[0,0,0]},
  "oolite-pirate-light-triangle":{"priority":40,"location":"LANE_WPS","groupCount":0}}
23:34:07.859 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen will change from GUI_SCREEN_LOAD to GUI_SCREEN_STATUS
23:34:07.899 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_LOAD to GUI_SCREEN_STATUS
23:34:07.899 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission screen opportunity
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Navigation Buoy 10711 spawned at 10 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): GalCop Viper 18861 spawned at 32 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Coriolis Station 11690 spawned at 0 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 25496 spawned at 175 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 27330 spawned at 177 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 8496 spawned at 187 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 16975 spawned at 252 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 31222 spawned at 260 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 20614 spawned at 260 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 9304 spawned at 261 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 21405 spawned at 263 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 7377 spawned at 263 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 18995 spawned at 267 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Rock Hermit 29477 spawned at 273 km
23:34:08.200 [LogEvents] GlobalLog (OOJSGlobal.m:266): Asteroid 15095 spawned at 274 km
23:34:10.493 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen will change from GUI_SCREEN_STATUS to GUI_SCREEN_EQUIP_SHIP
23:34:10.529 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_STATUS to GUI_SCREEN_EQUIP_SHIP
23:34:11.705 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen will change from GUI_SCREEN_EQUIP_SHIP to GUI_SCREEN_INTERFACES
23:34:11.732 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_EQUIP_SHIP to GUI_SCREEN_INTERFACES
23:34:12.670 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here4
23:34:12.721 [script.javaScript.warning.ooliteDefined] ReportJSError (OOJavaScriptEngine.m:204): ----- JavaScript warning (Hints_Station_Bar.js 0.0.93): Unknown expansion key [hints_bar_gossip] in string.
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here1
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here2
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here3
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.722 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.723 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.723 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.723 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:12.739 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_INTERFACES to GUI_SCREEN_MISSION
23:34:12.740 [strings.expand.warning.unknownExpansion] ReportWarningForUnknownKey (OOStringExpander.m:911): ----- WARNING: Unknown expansion key [hints_bar_gossip] in string.
23:34:12.740 [strings.expand.warning.unbalancedClosingBracket] Expand (OOStringExpander.m:306): ----- WARNING: Unbalanced ] in string.
23:34:12.740 [strings.expand.warning.unknownExpansion] ReportWarningForUnknownKey (OOStringExpander.m:911): ----- WARNING: Unknown expansion key [hints_bar_gossip] in string.
23:34:13.683 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen will change from GUI_SCREEN_MISSION to GUI_SCREEN_INTERFACES
23:34:13.689 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_MISSION to GUI_SCREEN_INTERFACES
23:34:13.701 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission screen ended
23:34:13.702 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission screen opportunity
23:34:16.280 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here4
23:34:16.280 [script.javaScript.warning.ooliteDefined] ReportJSError (OOJavaScriptEngine.m:204): ----- JavaScript warning (Hints_Station_Bar.js 0.0.93): Unknown expansion key [hints_bar_gossip] in string.
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here1
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here2
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here3
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.281 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [Hints_Station_Bar.js] GlobalLog (OOJSGlobal.m:266): got here5
23:34:16.282 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_INTERFACES to GUI_SCREEN_MISSION
23:34:16.283 [strings.expand.warning.unknownExpansion] ReportWarningForUnknownKey (OOStringExpander.m:911): ----- WARNING: Unknown expansion key [hints_bar_gossip] in string.
23:34:16.283 [strings.expand.warning.unbalancedClosingBracket] Expand (OOStringExpander.m:306): ----- WARNING: Unbalanced ] in string.
23:34:16.283 [strings.expand.warning.unknownExpansion] ReportWarningForUnknownKey (OOStringExpander.m:911): ----- WARNING: Unknown expansion key [hints_bar_gossip] in string.
23:34:16.283 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission choice was reset
23:34:17.583 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen will change from GUI_SCREEN_MISSION to GUI_SCREEN_INTERFACES
23:34:17.588 [LogEvents] GlobalLog (OOJSGlobal.m:266): gui screen changed from GUI_SCREEN_MISSION to GUI_SCREEN_INTERFACES
23:34:17.602 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission screen ended
23:34:17.602 [LogEvents] GlobalLog (OOJSGlobal.m:266): mission screen opportunity
23:34:24.238 [exit.context] -[OoliteApp terminate:] (OoliteApp.m:68): Exiting: Cocoa terminate event.

Closing log at 2022-05-09 22:34:24 +0000.
Relevant code:

Code: Select all

"use strict";
this.name = "Education_GNN.js";
this.author = "Cholmondely";
this.copyright = "(C) 2022 Cholmondely";
this.licence = "CC-NC-by-SA 4.0";
this.description = "Code by LittleBear and then Phkb.";
this.version = "0.9.0";

this.education_last = 0; // holds which news item was last published
this.education_max = 9; // hold the maximum number of news items available

this.startUpComplete = function() {
    // check save game for our education_last variable, and read it back in if found
    if (missionVariables.education_last) {
        this.education_last = parseInt(missionVariables.education_last);
    log(this.name, "got here1");
    }
}

this.playerWillSaveGame = function() {
    // make sure our education variable is saved
    missionVariables.education_last = this.education_last;
}

this.shipExitedWitchspace = function() {
    // if we've reach the maximum number of messages, we're done.
    if (this.education_last == this.education_max) return;

    // this is where you'd set up rules to govern how often news items are sent.
    // for the purposes of this exercise, we'll just make it random (1% chance)
    if (Math.random() < 0.01) { 
        var news = new Object;
        news.ID = this.name;
        // get the appropriate news item, based on the education_last variable.
        news.Message = expandDescription("[education_news_" + this.education_last + "]");
        news.Agency = 2;
        news.Priority = 1;
        this.passScreen(news, 1);
        log(this.name, "got here2");
    }
}

// i'm going to assume LittleBear's code here works
this.passScreen = function (news, mode) {
    var a = worldScripts.GNN._insertNews(news);
        log(this.name, "got here3");
    if (!a) {
        if (mode) this.education_last += 1; // If GNN conforms sucess, advance the News Counting variable to the next Broadcast.
        return;
    } else {
        if (a < 0) { // If the buffer was full then the mission variable counting the News Broadcasts wasn't advanced. Once the player has made the required number of jumps Random Station names will check again.
            return;
        }
    }
}

/*

// copy and paste everything between these markers ****** (but not the markers themselves) into descriptions.plist

******
    //• Interview of Chap reaching Elite status and giving manouever he used
    "education_news_1" = "Usge Ceanal has just attained Elite status according to a press release from the Elite Federation. In an interview, Ceanal said that he was an advocate of the Barkanion Bounce (named after the renowned Lave Academician) - swirling in loops towards his opposition whilst varying his speed. This tactic enables a trouble-free approach to one’s targets, and accounted for many hundreds of his kills.";

    //• Rock hermit destroyed in anarchy (a Pirate Cove)
    "education_news_2" = "A pirate-infested Rock Hermit has just been destroyed by a police viper-squad in the rodent-ridden anarchy of Riedquat. A centre for the local slave and narcotics trade, it has finally been shut down, allowing much safer travel in the Old Worlds sector! “The pirate plague has finally been eliminated” claimed the courageous Commander Reed Spar of GalCop, \"the Old Worlds are now as safe as a parentally-patrolled paddling pool!\"";

    //• Pirates nab chap on milk run Ensoreus-Ararus Furs-Computers: turns out to be a millionaire
    "education_news_3" = "Reports are just coming in about Orit Ceedthse, an Ensorean trader was murdered at Ararus yesterday by marauding pirates. It turns out that the feline was phenomenally rich, due to trading in furs and computers between Ensoreus and Ararus. Was she killed for her cargo, her money or for more murky misdemeanours? Truth is, we don’t know!";

    //• Quirium Cascade mishap
    "education_news_4" = "A quirium cascade bomb has been detonated at Qubeen. It caught some 27 ships and a rock hermit as well as the launcher of the bomb, a rodent from nearby Maesin. Inquiries are ongoing into the exact cause of the incident. GalCop is offering handsome rewards for relevant information.";"

    //• Flavour text
    "education_news_5" = "Murgh the Munificent, the Metropolitan of Maduro, in the Middle Oceans of Aronar, has been promoted to be the Sectoral Sacerdote for the Church of Giles the Creator. A devotee of fine wines, he is rumoured to have crepuscular connections in the ship-building industry as well as having links to the \"Cuban Cohort\", a mysterious group of musical mayhem-makers. He has for some time been threatening to lead a crusade against the Witchspace Lobster Worshippers. Watch this space!";

    //•Contracts
    "education_news_9" = "Arquebus the Audacious, the master trader, has finally come a cropper! After years of amassing a fortune trading in furs and computers, he took a time-sensitive contract to deliver wodgets to Ceesxe. Forgetting that fewer long jumps take much more time than many more smaller jumps, he arrived several days too late - and lost well over thirty thousand credits as a result! He is rumoured to have sold his ship in disgust and retired to a life of farming trumbles!";

    //• Flavour text
    "education_news_7" = "Archimandrite Ph'i Ku'ub of the Digebitian antipodes has just published a new commentary on the treatise on Theological Arithmetics by Saint Phibo Nacci. Combined with his earlier analysis of the mystical fourth codicil of the Codex of Giles the Creator, Ph'i Ku'ub claims to prove that the ooniverse was designed through random purposefulness, and show the numerical underpinnings of all that exists. Copies of his masterpiece have been selling like hotcakes! But does anybody actually understand it? Truth is, we don't know - and neither does anyone else!";

    //• Cim's changes to safe systems
    "education_news_8" = "Pirates travelling from their home system to raid another are becoming more of a threat. On the one hand, Police vipers at Diso have fought off another incursion of some several dozen pirates from the local anarchies, Uszaa and Reidquat. The President of Diso has appealed to GalCop for more help in stabilising the local region. On the other hand, Ensoreus has been raided by ravenous hordes from Ararus, Zaalela and Xeesle.";

    //• Pirates have ECM
    "education_news_6" = "The number of pirates armed with Electronic Counter Measures is increasing. Arch-Chandler RedSpear of GalCop's weapons research laboratory at Ceesxe has confirmed that more and more pirates are now using ECM in combat: "Do not fire missiles at pirates grouped in clusters of four or more, or you will waste them. At least one of them will be able to destroy your missiles" he told our reporters this morning.";
******
*/

Code: Select all

this.name           = "Hints_Station_Bar.js";
this.author         = "Cholmondely";
this.copyright      = "(C) 2022 Cholmondely";
this.licence        = "CC-NC-by-SA 4.0";
this.description    = "Adds a station bar where you might overhear useful tips";
this.version        = "0.0.93";

"use strict";

// LittleBear's comments: This script would let you give a randomly picked item each time. Although you might want to also add a timer so the messages change over time. You could also add tests for Government type, economy or station type so different items are overheard in different systems types and station types.

// Set Up your F4 Screen Option Like this:-

this.startUpComplete = this.shipDockedWithStation = function(station) {
this.barinterface();
}
this.removebar = this.shipWillLaunchFromStation = function() {
player.ship.dockedStation.setInterface("bar_chatter",null);
}

//  Now add your Visit the Bar Interface like this:- 

this.barinterface = function() {	
player.ship.dockedStation.setInterface("bar_chatter",{
title: "Visit the Station Bar",
category: "Activity",
summary: "Useful gossip can sometimes be overheard in the Bar",
callback: this.showBar.bind(this)});	
};

// Phkb's Set up to allow colour (from https://bb.oolite.space/viewtopic.php?p=283402#p283402)

//-------------------------------------------------------------------------------------------------------------
this.processText = function (text) {
    var final = [];
    var colors = [];
    var columnWidth = 32; // this is the maximum display width available
    var paras = text.split("\n");
    var color = "";
    for (var i = 0; i < paras.length; i++) {
        var line = "";
        // special case for a blank line
        if (paras[i].length == 0 && i < paras.length - 1) {
            final.push("");
            colors.push(color);
            continue;
        }
    log(this.name, "got here1");
        var words = paras[i].split(" ");
        for (var j = 0; j < words.length; j++) {
            // look for a colour change
            if (words[j].indexOf("{color:") >= 0) {
                // get the color deinition
                color = words[j].substring(words[j].indexOf("{color:") + 7, words[j].indexOf("}"));
                if (color == "reset") color = ""; // check for a reset to set the color back to the default
                // remove the color definition from the word
                words[j] = words[j].substring(0, words[j].indexOf("{color:")) + words[j].substring(words[j].indexOf("}") + 1);
            }
            // can we fit this word into the line?
            if (defaultFont.measureString(line + " " + words[j]) > columnWidth) {
                final.push(line); // put the current line into the final array
                colors.push(color);
                line = ""; // clear the text
            }
            line += (line.length == 0 ? "" : " ") + words[j];
        }
            log(this.name, "got here2");
        if (line.trim() != "") {
            final.push(line); // make sure any leftovers are put into the array
            colors.push(color);
            line = "";
        }
    }
    // return all the data we compiled in a dictionary
    return {
        lines: final,
        colors: colors
    };
}

//-------------------------------------------------------------------------------------------------------------
// returns true if a HUD with allowBigGUI is enabled, otherwise false
this.$isBigGuiActive = function $isBigGuiActive() {
	    log(this.name, "got here3");
	if (oolite.compareVersion("1.83") <= 0) {
		return player.ship.hudAllowsBigGui;
	} else {
		var bigGuiHUD = ["XenonHUD.plist", "coluber_hud_ch01-dock.plist"]; // until there is a property we can check, I'll be listing HUD's that have the allow_big_gui property set here
		if (bigGuiHUD.indexOf(player.ship.hud) >= 0) {
			return true;
		} else {
			return false;
		}
	}
}

// Now add this code so that when the Visit the Bar Option is selected Oolite will randomly pick one of the messages you have set up in descriptions. Version 0.93: This now includes PHKB's colour-tweaking additions

this.showBar = function () {
	    log(this.name, "got here4");
    // grab the text from the descriptions
    var text = expandDescription("[hints_bar_gossip]");
    var alternate = false;

    if (alternate == false && worldScripts["Ships Library"] && Math.random() < 0.90) {text = expandDescription("[hints_Ship's_Library]"); alternate = true;}
    // change 0.05 up or down to taste.
    var breakdown = this.processText(text);

    var defaultColor = "yellowColor";
    var displayLines = 26;
    if (this.$isBigGuiActive() == false) displayLines = 20;
    var choices = {};
    
    // add the text lines to the choices dictionary
    for (var i = 0; i < breakdown.lines.length; i++) {
        choices["line_" + (i < 10 ? "0" : "") + i.toString()] = {
            text: breakdown.lines[i],
            alignment: "LEFT",
            color: (breakdown.colors[i] == "" ? defaultColor : breakdown.colors[i]),
            unselectable: true
        }
    }
    // add some spacers to push the text to the top of the screen
    for (var i = 0; i < displayLines - breakdown.lines.length; i++) {
	        log(this.name, "got here5");
        choices["spacer" + i] = {
            text: "",
            unselectable: true
        }
    }
    // add a final choice to inform the player what to do next
    choices["z_end"] = {
        text: "Press enter to continue"
    }

    mission.runScreen({
        title: "The Local Bar",
        screenID: "show_bar",
        choices: choices,
        overlay: "litf_bg_localbar.png", //This adds the bar image behind the message
        exitScreen: "GUI_SCREEN_INTERFACES",
    })
}
I'm getting [hints_bar_gossip] when I visit the local bar, and no hints whatsoever. And nothing hint-wise appears with GNN (but the regular news broadcasts have suddenly become a lot more interesting!). It doesn't seem to be the .plists (I've been plutil_'ing them like billy-oh!).
Comments wanted:
Missing OXPs? What do you think is missing?
Lore: The economics of ship building How many built for Aronar?
Lore: The Space Traders Flight Training Manual: Cowell & MgRath Do you agree with Redspear?
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 4830
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Education

Post by phkb »

Cholmondely wrote: Mon May 09, 2022 10:41 pm
So both bits of this one are acting up.
The error "Unknown expansion key [hints_bar_gossip] in string" is happening because Oolite can't find "hints_bar_gossip" in your descriptions.plist file. There are no errors in your log file that would suggest it couldn't be read, so the error must be in the file itself. Can you post the entire content of descriptions.plist so I can investigate?
Post Reply