Page 7 of 12

Re: Randomshipnames.oxp v 1.3 released

Posted: Tue Sep 03, 2013 6:46 pm
by Commander McLane
cim wrote:
In 1.77, the rock hermit positions are consistent for about 90 days and then move. In 1.79 they're permanently consistent (but different to any 1.77 position). This to within the limits of reading a floating-point number anyway: you might want to allow +/- a metre or two.
That's good to know. The effect of wandering rock hermits won't really matter. The new positions will just be added to the list (with new names). And the list is cleared for every galactic jump anyway, so there's no permanent clutter. And yes, the positions are compared with an accuracy of a metre. Actually, given the hermits' size, it could be +/- 100 metres.
cim wrote:
Provided none of the rock hermit names are from a list that gets entries removed over time, you could theoretically write your own RNG function (i.e. instead of Math.random()) for use when generating rock hermit names, and seed it with some combination of the hermit's position and the system ID. Probably more effort than it's worth, though!
Definitely too much effort. Especially as the names do come from depleting lists (the male and female names both get removed from their lists after use, in order to ensure variety).

Re: Randomshipnames.oxp v 1.3 released

Posted: Tue Sep 03, 2013 8:21 pm
by Cody
cim wrote:
In 1.79 they're permanently consistent...
<wonders if he could visit every rock hermit in an octant>

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Sep 04, 2013 7:39 am
by Commander McLane
Cody wrote:
cim wrote:
In 1.79 they're permanently consistent...
<wonders if he could visit every rock hermit in an octant>
Given enough time, sure. There's usually one or two hermits per system (some have none, some have more), that'd make roundabout 500 visits. And you could also visit every main station along the way for the same price. :mrgreen:

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Sep 04, 2013 10:45 am
by Cody
I ain't worried about main stations - I've probably already visited most, if not all, of them. But rock hermits are different - I like rock hermits for several reasons, and there's always at least one in every system - and now their delightfully wacky names will persist.

Re: Randomshipnames.oxp v 1.3 released

Posted: Thu Sep 05, 2013 5:48 am
by Tricky
Commander McLane wrote:
cim wrote:
Provided none of the rock hermit names are from a list that gets entries removed over time, you could theoretically write your own RNG function (i.e. instead of Math.random()) for use when generating rock hermit names, and seed it with some combination of the hermit's position and the system ID. Probably more effort than it's worth, though!
Definitely too much effort. Especially as the names do come from depleting lists (the male and female names both get removed from their lists after use, in order to ensure variety).

Code: Select all

/* Same random number for each system. */
randf = system.scrambledPseudoRandomNumber(salt);
Change salt (increase it) for each new name in the system.

Re: Randomshipnames.oxp v 1.3 released

Posted: Thu Sep 05, 2013 11:05 am
by Commander McLane
Tricky wrote:
Commander McLane wrote:
cim wrote:
Provided none of the rock hermit names are from a list that gets entries removed over time, you could theoretically write your own RNG function (i.e. instead of Math.random()) for use when generating rock hermit names, and seed it with some combination of the hermit's position and the system ID. Probably more effort than it's worth, though!
Definitely too much effort. Especially as the names do come from depleting lists (the male and female names both get removed from their lists after use, in order to ensure variety).

Code: Select all

/* Same random number for each system. */
randf = system.scrambledPseudoRandomNumber(salt);
Change salt (increase it) for each new name in the system.
I typed the wrong answer. The problem isn't actually the effort (because scrambledPseudoRandomNumber does indeed provide a reliably unchanging number), but the condition before that. Each name that is used once gets stricken from the list. Thus, "Aaron's Solitary Rock" would become "Abbot's Solitary Rock" when you re-enter the system. Not persistent. Storing and retrieving the names is the only way to ensure persistence.

Re: Randomshipnames.oxp v 1.3 released

Posted: Fri Sep 06, 2013 2:27 am
by Tricky
Commander McLane wrote:
I typed the wrong answer. The problem isn't actually the effort (because scrambledPseudoRandomNumber does indeed provide a reliably unchanging number), but the condition before that. Each name that is used once gets stricken from the list. Thus, "Aaron's Solitary Rock" would become "Abbot's Solitary Rock" when you re-enter the system. Not persistent. Storing and retrieving the names is the only way to ensure persistence.
Ah! Appologies. I made the mistake of assuming the list was reset on entering a system, ie from this.shipWillExitWitchspace().

Never really done an analysis of the code for Random Shipnames. Just taken a cursory look at the bit that selects the name.

Remember kids, never assume anything as you will make an ass out of you and me. :oops:

Re: Randomshipnames.oxp v 1.3 released

Posted: Fri Sep 06, 2013 9:21 am
by Cody
Tricky wrote:
Remember kids, never assume anything as you will make an ass out of you and me.
Remember kids, never trust a man with too many fingers!

Re: Randomshipnames.oxp v 1.3 released

Posted: Tue Oct 22, 2013 7:54 pm
by UK_Eliter
Commander McLane: sorry if this has been posted before, but the playerProxyEntity that gets generated upon eject gets a randomshipname, via your oxp, and it's not the name the player himself/herself gave the ship. Thought you ought to know.

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 12:11 am
by Duggan
I note Henry Every and Blackbeard along with Calico Jack, Henry Morgan quiet regularly in varying forms along with a certain fictional Pirate, However I feel that to make up the numbers in future , there is this.

http://en.wikipedia.org/wiki/List_of_pi ... .80.931730

I do miss William Kydd and Black Bart in my travels amongst others :D

I digress of course (nothing new there then), I simply thought the list might be useful for any future edition of this excellent Expansion Pack.

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 11:16 am
by Commander McLane
Duggan wrote:
I note Henry Every and Blackbeard along with Calico Jack, Henry Morgan quiet regularly in varying forms along with a certain fictional Pirate, However I feel that to make up the numbers in future , there is this.

http://en.wikipedia.org/wiki/List_of_pi ... .80.931730

I do miss William Kydd and Black Bart in my travels amongst others :D

I digress of course (nothing new there then), I simply thought the list might be useful for any future edition of this excellent Expansion Pack.
It certainly is, and I used it for extracting names. However, I find it necessary that the names I choose are easily recognizable as historical pirates, and some on the list are too little-known to fit the bill.

When compiling the pirate name list, I used a very simple (and of course very imperfect) litmus test for the notoriety of each person on that Wikipedia list: if I knew them instantly as a historical pirate, I assumed that the average Oolite player would probably know them as well, and they went on my list. William Kydd and Black Bart fell through that—admittedly simple—sieve. That's why they're not in.

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 11:20 am
by JazHaz
UK_Eliter wrote:
Commander McLane: sorry if this has been posted before, but the playerProxyEntity that gets generated upon eject gets a randomshipname, via your oxp, and it's not the name the player himself/herself gave the ship. Thought you ought to know.
In case you missed it McLane?

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 11:22 am
by Commander McLane
UK_Eliter wrote:
Commander McLane: sorry if this has been posted before, but the playerProxyEntity that gets generated upon eject gets a randomshipname, via your oxp, and it's not the name the player himself/herself gave the ship. Thought you ought to know.
Thanks for the report. This hasn't been posted before.

Under which circumstances did you notice this? Once the player has ejected, hey can't do anything anymore, and the name of the proxy entity doesn't get displayed. There isn't even a way to display it in-game that I'm aware of. So the fact that the proxy entity gets a random name should be of no consequence.

If this is different for you (probably in conjunction with a certain OXP or certain OXPs), then please elaborate.

EDIT: @JazHaz: no, I was just answering. :wink:

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 3:34 pm
by UK_Eliter
Commander McLane wrote:
UK_Eliter wrote:
Commander McLane: sorry if this has been posted before, but the playerProxyEntity that gets generated upon eject gets a randomshipname, via your oxp, and it's not the name the player himself/herself gave the ship. Thought you ought to know.
Thanks for the report. This hasn't been posted before.

Under which circumstances did you notice this? Once the player has ejected, hey can't do anything anymore, and the name of the proxy entity doesn't get displayed. There isn't even a way to display it in-game that I'm aware of. So the fact that the proxy entity gets a random name should be of no consequence.

If this is different for you (probably in conjunction with a certain OXP or certain OXPs), then please elaborate.
Dear McLane

I ejected near the system witchpoint, then relaunched from the main station where my pod ended up, and then went back to the system witchpoint with my new ship (that new ship being identical in fittings to the old one, i.e. I didn't buy a new ship). And there was my old ship, with a new name!

Re: Randomshipnames.oxp v 1.3 released

Posted: Wed Oct 23, 2013 4:58 pm
by cim
Hmm. That's feels like a core bug: the escape sequence adds several hours if not days onto your clock - no way should your old ship still be around after that.