Talkative space combat tweak

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

Moderators: winston, another_commander

Post Reply
User avatar
spara
---- E L I T E ----
---- E L I T E ----
Posts: 2691
Joined: Wed Aug 15, 2012 4:19 am
Location: Finland

Talkative space combat tweak

Post by spara »

Hello to all.

I've been playing Oolite for a quite some time and with all the oxps it's an amazing game. It's been well over 10 years since I've been this addicted to a game. Don't know if it's a good thing, though. Thank you all.

One thing I like a lot is that you can tweak the oxp:s to your liking.

Talkative space compass gives you the name of the object when you browse objects in advanced space compass. Here is a little tweak to give you the distance too. Add the following code to the end of the script.js just before the last }.

Code: Select all

//distance to object
if (mode != "COMPASS_MODE_BASIC") {
           dist = (player.ship.position.distanceTo(whom) - whom.collisionRadius)/1000;
           player.consoleMessage(dist.toFixed(3)+" km");
}
User avatar
Smivs
Retired Assassin
Retired Assassin
Posts: 8408
Joined: Tue Feb 09, 2010 11:31 am
Location: Lost in space
Contact:

Re: Talkative space combat tweak

Post by Smivs »

Hi spara, and welcome to the friendliest board this side of Riedquat.
Great first post - we are always impressed by a useful contribution. :)
Commander Smivs, the friendliest Gourd this side of Riedquat.
User avatar
Shipbuilder
---- E L I T E ----
---- E L I T E ----
Posts: 877
Joined: Thu May 10, 2012 9:41 pm
Location: Derby

Re: Talkative space combat tweak

Post by Shipbuilder »

Welcome onboard Spara.

Glad you like what is being produced and as Smivs says great first post. :D
The GalTech Industries Corporation - Building ships to populate the galaxies.

Increase the variety of ships within your Ooniverse by downloading my OXPs

Flying the [wiki]Serpent_Class_Cruiser[/wiki] "Thargoid's Bane"
User avatar
spara
---- E L I T E ----
---- E L I T E ----
Posts: 2691
Joined: Wed Aug 15, 2012 4:19 am
Location: Finland

Re: Talkative space combat tweak

Post by spara »

Thanks.

This board sure is the "friendliest board this side of Riedquat."

I wish I had more time to waste on Oolite.
User avatar
Gimi
---- E L I T E ----
---- E L I T E ----
Posts: 2073
Joined: Tue Aug 29, 2006 5:02 pm
Location: Norway

Re: Talkative space combat tweak

Post by Gimi »

spara wrote:
Thanks.
This board sure is the "friendliest board this side of Riedquat."
I wish I had more time to waste on Oolite.
Waste? :shock:
I'm unable to connect the dots in that last statement. :D

Welcome, and thanks for the code snippet. Under consideration for inclusion in my personal copy.
"A brilliant game of blasting and trading... Truly a mega-game... The game of a lifetime."
(Gold Medal Award, Zzap!64 May 1985).
User avatar
Smivs
Retired Assassin
Retired Assassin
Posts: 8408
Joined: Tue Feb 09, 2010 11:31 am
Location: Lost in space
Contact:

Re: Talkative space combat tweak

Post by Smivs »

spara wrote:
I wish I had more time to waste on Oolite.
Don't worry, the time will find you :D Other things might suffer, but..... :wink:
Commander Smivs, the friendliest Gourd this side of Riedquat.
User avatar
CommonSenseOTB
---- E L I T E ----
---- E L I T E ----
Posts: 1397
Joined: Wed May 04, 2011 10:42 am
Location: Saskatchewan, Canada

Re: Talkative space combat tweak

Post by CommonSenseOTB »

spara wrote:
Hello to all.

I've been playing Oolite for a quite some time and with all the oxps it's an amazing game. It's been well over 10 years since I've been this addicted to a game. Don't know if it's a good thing, though. Thank you all.

One thing I like a lot is that you can tweak the oxp:s to your liking.

Talkative space compass gives you the name of the object when you browse objects in advanced space compass. Here is a little tweak to give you the distance too. Add the following code to the end of the script.js just before the last }.

Code: Select all

//distance to object
if (mode != "COMPASS_MODE_BASIC") {
           dist = (player.ship.position.distanceTo(whom) - whom.collisionRadius)/1000;
           player.consoleMessage(dist.toFixed(3)+" km");
}
Good job spara! :D
Take an idea from one person and twist or modify it in a different way as a return suggestion so another person can see a part of it that can apply to the oxp they are working on.


CommonSense 'Outside-the-Box' Design Studios Ltd.
WIKI+OXPs
User avatar
Tricky
---- E L I T E ----
---- E L I T E ----
Posts: 821
Joined: Sun May 13, 2012 11:12 pm
Location: Bradford, UK. (Anarchic)

Re: Talkative space combat tweak

Post by Tricky »

spara wrote:
Hello to all.

I've been playing Oolite for a quite some time and with all the oxps it's an amazing game. It's been well over 10 years since I've been this addicted to a game. Don't know if it's a good thing, though. Thank you all.

One thing I like a lot is that you can tweak the oxp:s to your liking.

Talkative space compass gives you the name of the object when you browse objects in advanced space compass. Here is a little tweak to give you the distance too. Add the following code to the end of the script.js just before the last }.

Code: Select all

//distance to object
if (mode != "COMPASS_MODE_BASIC") {
           dist = (player.ship.position.distanceTo(whom) - whom.collisionRadius)/1000;
           player.consoleMessage(dist.toFixed(3)+" km");
}
I would just like to say, "I HATE YOU!", in a nice way. :lol:

I should have thought of that myself. :(

Talkative Compass should have had this as standard.
User avatar
JazHaz
---- E L I T E ----
---- E L I T E ----
Posts: 2991
Joined: Tue Sep 22, 2009 11:07 am
Location: Enfield, Middlesex
Contact:

Re: Talkative space combat tweak

Post by JazHaz »

Tested this tweak today, can report it works well. One thought, putting distances in kilometers might make Oolite distances feel a little small. Maybe Astronomical Units or ParSecs might be better.

Edit: not ParSecs as they are about 3.26 light-years each! If the km value could be multiplied by 0.01 or even 0.001 then the AU figure might be better.
JazHaz

Gimi wrote:
drew wrote:
£4,500 though! :shock: <Faints>
Cheers,
Drew.
Maybe you could start a Kickstarter Campaign to found your £4500 pledge. 8)
Thanks to Gimi, I got an eBook in my inbox tonight (31st May 2014 - Release of Elite Reclamation)!
User avatar
Tricky
---- E L I T E ----
---- E L I T E ----
Posts: 821
Joined: Sun May 13, 2012 11:12 pm
Location: Bradford, UK. (Anarchic)

Re: Talkative space combat tweak

Post by Tricky »

JazHaz wrote:
Tested this tweak today, can report it works well. One thought, putting distances in kilometers might make Oolite distances feel a little small. Maybe Astronomical Units or ParSecs might be better.

Edit: not ParSecs as they are about 3.26 light-years each! If the km value could be multiplied by 0.01 or even 0.001 then the AU figure might be better.
Mmm... 25.6 kilometer = 0.000000171 astronomical unit whereas 1 astronomical unit = 149,597,870.691 kilometer. Maybe we could define an Oolite AU being the distance between Lave and it's star* (without [EliteWiki] Farsun or [EliteWiki] Sensible Sun OXP).

(*Not sure what that is ATM)
User avatar
spara
---- E L I T E ----
---- E L I T E ----
Posts: 2691
Joined: Wed Aug 15, 2012 4:19 am
Location: Finland

Re: Talkative space combat tweak

Post by spara »

Km:s make the system feel unrealistically small. Unless you imagine yourself vey small.
...Maybe we could define an Oolite AU...
This is a great idea. Would it be OU, OAU or maybe OoAU? The last one sounds funniest.
User avatar
Smivs
Retired Assassin
Retired Assassin
Posts: 8408
Joined: Tue Feb 09, 2010 11:31 am
Location: Lost in space
Contact:

Re: Talkative space combat tweak

Post by Smivs »

<Smivs chuckles - he loves the idiosyncracies of Oolite scale>
Commander Smivs, the friendliest Gourd this side of Riedquat.
User avatar
Disembodied
Jedi Spam Assassin
Jedi Spam Assassin
Posts: 6885
Joined: Thu Jul 12, 2007 10:54 pm
Location: Carter's Snort

Re: Talkative space combat tweak

Post by Disembodied »

Pick a unit with sufficiently large numbers, i.e. where far away things are several hundred units off at least, and call them "klicks", as per Starship Troopers, or something. It's US military slang for "kilometre", apparently, but by the 32nd century it could mean anything.
Post Reply