Re: Oolite Wiki
Posted: Fri Jun 04, 2021 8:07 am
And some fell on stony ground!
And some fell on stony ground!
Aha!
I do agree a trim() to remove leading and trailing whitespace before comparison would fix this issue. I also strongly believe it is a step in the wrong direction. I have seen projects going towards wobbly behaviour just because input files were treated too generously.
While falling, it tried to grab whatever/whomever to prevent or at least soften the sudden impact at the end. So he stretched all his noodly appendages, but noone held on. They all felt blessed by having been touched by a god or something...Cholmondely wrote: ↑Fri Jun 04, 2021 8:53 amSo the Great and Glorious God, Ramen, the Witchspace Lobster, fell from his celestial throne plummeting down from the heavenly heights onto stony ground!
And what happened next, after the Divine Defenestration?
And how on earth does it tie up with his worshippers flying out through pirate-infested reaches to the witchspace beacon before they blast off to another system?
Implemented.
Agree. Abstract ships do not have to have user documentation. For programmers it might be worth having something, but this is out of scope for now.
'probably part of a larger ship' means to me the ship was reused as part of a larger ship. It does not mean it is no ship per se.phkb wrote: ↑Wed Jun 02, 2021 10:19 pmNext, if a ship identifier is used anywhere in the shipdata.plist file in a "subentity_key" (see the "Broadcast Array Arm", key "broadcast_array_arm", from the "Tionisla Chronicle Array" OXP), then that's probably only part of a larger ship and can be left off as well.
This is a really strange case, but yes it seems not to be a ship in the common sense.phkb wrote: ↑Wed Jun 02, 2021 10:19 pmAfter that it's much harder to define. For instance, in the "Breakable WItch Drive" OXP, it has one ship entity, named "Malfunction...Malfunction", id "btd_dummy_entity". This entity is used to pull the player ship out of torus when it's malfunctioning. It's not a ship that you will ever see in the game, but there's no way, other than by looking through the code and working out how it keeps the ship from appearing on the scanner when it's spawned (FWIW, it changes the scanner color to "clear", essentially making it invisible).
Hmmm, maybe we still need a good definition what we want to achieve.phkb wrote: ↑Wed Jun 02, 2021 10:19 pmI think your best bet is to look at the "roles" property of the ship, and seeing it if includes any of the standard spawning roles ("pirate-*", "assassin-*", "trader*", etc). Also check the "scan_class" for "CLASS_STATION", as that might be a way of picking up what could spawn (the Broadcast Array from the Tionisla Chronicle Array is an example of where the "roles" property probably won't help, but the scan_class might. The scan_class might also help if it says "CLASS_NO_DRAW", as that item won't be seen in the game. scan_class = "CLASS_POLICE" should only be used for police vessels, and could pick up a bit more.
I think this is going to take a bit of refinement before we've got something robust and accurate. Sorry I can't give you a more definitive list.
Very nice. You tell me to check whether is_template contains yes, which is in sync with http://wiki.alioth.net/index.php/Shipda ... s_template. At the same time I am checking for values yes, no, true, false. Not a big deal. But then I stumble over the oolite core game, which marks templates with is_template=1.
1 is the integer representation of the boolean true (in most languages at least). And Oolite is trying to handle the widest range of possible user inputs. So, 1, true, yes all do the same thing for a boolean value. There are exceptions to this rule in Oolite (of course) - consider the "has_escape_pod" property, which can be 1, yes, true, or 0.5, 0.1 (decimals being the likelihood of the escape pod being awarded) etc.
The cases where a smaller ship that can be spawned on it's own as well as part of a larger ship are so few as to be edge cases, rather than something you need to cater for up front.
That seems reasonable.hiran wrote: ↑Sun Jun 06, 2021 9:08 pmHow about taking it in phases? (which would not mean we must not work on stuff of the other phases, but we could focus our attention to fewer issues):
Phase 1: All expansions
Phase 2: All player playable ships
Phase 3: All visible equipment
Phase 4: Complete the missing parts
Ship.keysForRole("player")
to get a list of player-flyable ship data keys. (Of course, you'd have to have every player ship installed in your game for that to work, but still. Possibly useful.I grew up with a programming language that used -1 for true so it was safer to go with the definition:phkb wrote: ↑Sun Jun 06, 2021 9:53 pm1 is the integer representation of the boolean true (in most languages at least). And Oolite is trying to handle the widest range of possible user inputs. So, 1, true, yes all do the same thing for a boolean value. There are exceptions to this rule in Oolite (of course) - consider the "has_escape_pod" property, which can be 1, yes, true, or 0.5, 0.1 (decimals being the likelihood of the escape pod being awarded) etc.
Yep, it's complicated.
Code: Select all
false = 0; true = not false;
At least for the time being it makes sense. Ok.
I thought player playable ships should be listed in the shipyard.plist files. But yes we can consider that.
Oh, look what I found':hiran wrote: ↑Wed Jun 02, 2021 12:29 pmI understand this is becoming an issue. We may need a better solution for that.Cholmondely wrote: ↑Wed Jun 02, 2021 1:23 amI am becoming increasingly concerned about the number of redirect pages on the wiki (all my own fault. I know, I know...). People use it to find things and I would suspect most of us type in the words, which allows the wiki search engine come up with a list of choices, from which the correct item can be chosen. If there are too many choices, this does not work as well. Of course if people cut and paste, then it is a very different matter - but you can't cut and paste from the F3 ship outfitting screen in the game (even Version 1.90). So you will be typing, as above...
I see the important thing as that everything is on our wiki. our new Hiranistificalite Index is an absolutely spiffing tool for managing that. But it is merely a tool. Turning the index page blue is not the same as having everything listed (and findable) on the wiki. Of course, if Phkb waves his glass of cognac and the items on the F3 shipyard suddenly link to the wiki, then we will indeed need to turn the index page blue. But we are not there quite yet!
While I want everything to have a page, you want the search function to behave wisely. Which means not everything that might exist in the wiki should directly show up when a human being initiates a search.
Now I am wondering whether namespaces could be a solution for that (https://www.mediawiki.org/wiki/Help:Namespaces)...
An interesting find! Well done, sir!hiran wrote: ↑Mon Jun 07, 2021 6:09 amOh, look what I found':hiran wrote: ↑Wed Jun 02, 2021 12:29 pmI understand this is becoming an issue. We may need a better solution for that.Cholmondely wrote: ↑Wed Jun 02, 2021 1:23 amI am becoming increasingly concerned about the number of redirect pages on the wiki (all my own fault. I know, I know...). People use it to find things and I would suspect most of us type in the words, which allows the wiki search engine come up with a list of choices, from which the correct item can be chosen. If there are too many choices, this does not work as well. Of course if people cut and paste, then it is a very different matter - but you can't cut and paste from the F3 ship outfitting screen in the game (even Version 1.90). So you will be typing, as above...
I see the important thing as that everything is on our wiki. our new Hiranistificalite Index is an absolutely spiffing tool for managing that. But it is merely a tool. Turning the index page blue is not the same as having everything listed (and findable) on the wiki. Of course, if Phkb waves his glass of cognac and the items on the F3 shipyard suddenly link to the wiki, then we will indeed need to turn the index page blue. But we are not there quite yet!
While I want everything to have a page, you want the search function to behave wisely. Which means not everything that might exist in the wiki should directly show up when a human being initiates a search.
Now I am wondering whether namespaces could be a solution for that (https://www.mediawiki.org/wiki/Help:Namespaces)...
https://www.mediawiki.org/wiki/Help:Redirects
Redirects are used to forward users from one page name to another. They can be useful if a particular article is referred to by multiple names, or has alternative punctuation, capitalization or spellings.
No surprise here: redirects are intended to bridge different spellings or different names - just the discrepancy we have between artefact names and page names. Let's go and make use of them.
https://www.mediawiki.org/wiki/Manual:U ... _namespace
A custom namespace can be used to hold content that should not be shown on the search results page
...and this is to save the wiki index from exploding. We could introduce a namespace for Oolite artefact names consisting mainly of redirects to the existing pages. Given that these redirect pages are hosted in a separate namespace will not clog up the search function.
In German it is actually slightly easier. Well, you can still combine all such words to make up one big one. But in such cases they are written as one word - no whitespace between. Ugly for first class students trying to decipher the word and running out of breath. But compared to English...Cholmondely wrote: ↑Mon Jun 07, 2021 6:26 amAn interesting find! Well done, sir!
To be honest, I'm less worried about the proliferation of new equipment (showing the diversity of Oolite - ... and I love some of the names that, for example, Redspear has concatenated). I am more concerned with that of such as the "Market Observer/MarketObserver/MarketObserver OXP" .mixes.
Heavens... what a confusing array of pronouns, prepositions and what not. Tell me, Hiran, is it the same in German?