Library

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

Moderators: winston, another_commander

Post Reply
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Library

Post by Svengali »

Image

Reinventing the wheel is not everybodys taste, so here comes a collection of useful snippets and helpers. Its main purpose is to simplify or unify some common tasks used by OXPers. Library is the successor to CCL, Hyperradio and OXPConfig. The library does not alter any native JS objects (like Array or String) to avoid clashes and does not clutter the global namespace.

[EliteWiki] Library (or the WIKI-Backup Library)

Some key features:
  • Lib_Config.js - Configuration interface. Replaces OXPConfig. Supports multiple entries and path handling.
  • Lib_GUI.js - Unified GUI image, sound and music handling. It allows multiple background AddOns to be installed. Users may switch between them.
  • Lib_Music.js - Unified event driven music handling. Replaces Hyperradio.
Last edited by Svengali on Mon Feb 19, 2018 9:13 pm, edited 2 times in total.
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

New versions for Library and BGS .-) I guess they are ready for release, but we'll see.
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: Library

Post by Cody »

Only just back in the saddle - good to see settings now persisting. Muchas gracias!
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
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

Cody wrote:
Only just back in the saddle - good to see settings now persisting. Muchas gracias!
Yep. I've removed the 'force defaults' thing in BGS. It was time to do it...
User avatar
Keeper
---- E L I T E ----
---- E L I T E ----
Posts: 273
Joined: Fri Feb 01, 2013 7:44 am
Location: Indian Hills, Nevada, USA

Re: Library

Post by Keeper »

For years I've had some changed images and sounds for this set. I've updated them to match the new set. I figure people might like them, so I've uploaded them.

The screens have a bit of the "legend" icons showing the relative order of government and economy types, as well as a function key menu with English labels (the old menu from the previous BGS set but with text added by myself -- now blended over the new backgrounds nicely). Here's a 16:10 screenshot: http://www.keeper1st.com/Oolite/bgsexample.png

For the sounds, I replaced the "Item Sold" and "Item Bort" (?!) with nice little chimes (can't remember where they came from -- original Oolite?), changed things like "Ortopilot activated" into "Autopilot activated", trimmed some dead air (e.g. so instead of "missile......armed" it's "missile armed"), removed all instances of Majel Barrett from Star Trek (nothing against the late Ms Barrett or Star Trek; I just think the second voice is unnecessary), and greatly changed the extremely long and drawn-out game-over sound into a rather rapid explosion then sudden expulsion of air into silence, which is rather more shocking and realistic.

You're free to add them to the pack if you like.
http://www.keeper1st.com/Oolite/bgs2changedimages.zip
http://www.keeper1st.com/Oolite/bgs-editedsounds.zip
Last edited by Keeper on Fri Sep 02, 2016 12:49 am, edited 1 time in total.
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: Library

Post by phkb »

Small bug:

Code: Select all

07:14:03.092 [script.javaScript.exception.unexpectedType]: ***** JavaScript exception (Lib_EntityStrength 1.0): TypeError: s is null
07:14:03.092 [script.javaScript.exception.unexpectedType]:       ../AddOns/Testing.oxp/Library1.0.oxp/Library1.0.oxp/Scripts/Lib_EntityStrength.js, line 47.
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

phkb wrote:
Small bug:
Oh, yes. I need to guard it. Muchas gracias.
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

New version online.

Changes:
  • Lib_EntityStrength - Guarded check - although a bit undertested atm.
  • Lib_GUI - Added suffixes for alertConditionRed and hudAllowsBigGui and handling for mission.exitScreen which doesn't trigger guiScreenChanged.
  • lib_fx - Attempt to avoid sunglare popping in (with BGS jump and docking sequence).
I've also changed the BGS jump shader a bit.

@Keeper - Just grabbing it .-)
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: Library

Post by Cody »

Svengali wrote:
I've also changed the BGS jump shader a bit.
Indeed! Certainly different, amigo - if only that old momentary stutter could be removed.

I always swap the BGS buy/sell .oggs for Oolite's defaults, btw - BGS's are too long.
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
Keeper
---- E L I T E ----
---- E L I T E ----
Posts: 273
Joined: Fri Feb 01, 2013 7:44 am
Location: Indian Hills, Nevada, USA

Re: Library

Post by Keeper »

I just realized that the zip file of the edited images I uploaded was the wrong one. That was for the old set. The images for the new set are at http://www.keeper1st.com/Oolite/bgs2changedimages.zip
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

Cody wrote:
if only that old momentary stutter could be removed.
Try - https://bb.oolite.space/viewtopic.php?f= ... 52#p251252. For me it solved it.

@Keeper: *grins, grab*
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: Library

Post by Cody »

Tried that a while back, and tried it again just now - no luck.
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
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: Library

Post by Cody »

This popped up:

Code: Select all

14:40:00.123 [script.javaScript.exception.notFunction]: ***** JavaScript exception (<unidentified script>): TypeError: pos.normalize is not a function
14:40:00.123 [script.javaScript.exception.notFunction]:       ../AddOns/Library1.0.oxp/Scripts/lib_fx.js, line 57.
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
cbr
---- E L I T E ----
---- E L I T E ----
Posts: 1422
Joined: Thu Aug 27, 2015 4:24 pm

Re: Library

Post by cbr »

When i look at the animation demo i am wondering if library could be used to simulate 'screensaver mode' ?

loading the data from a random system/planet (size and texture) and displaying it like the animation demo displays
the 'moon' preferable with the current planet shader :)
User avatar
Svengali
Commander
Commander
Posts: 2370
Joined: Sat Oct 20, 2007 2:52 pm

Re: Library

Post by Svengali »

Cody wrote:
This popped up:
It's already gone in the last WIP-version. Still - thanks a lot, Cody .-)
cbr wrote:
When i look at the animation demo i am wondering if library could be used to simulate 'screensaver mode'?
I doubt it. missionscreens are rather limited (no multipass, no blending, etc.) atm.
Post Reply