Hard Light Productions Forums

FreeSpace Releases => Scripting Releases => Topic started by: Axem on February 18, 2014, 10:12:34 pm

Title: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 18, 2014, 10:12:34 pm
Isn't the tech room such an awful place to store in-universe fluff? To get to the good meat of everything, you need to go to "Tech Room" then down to "Intelligence" and you're greeted with a tiny textbox over shadowed by a large mostly unfilled window with a looping animation (and that's if you're lucky!)

Well I've decided to try and make something better to read with a few more options on how things are presented. Rather than me explain what it can do, here's a short video!

Now that you've seen it, let me explain:
Yes, I'm creating the interface in LUA, keeping the awful scaling intact. But non-interface images and text will not stretch (thankfully).
This mostly uses retail assets, the only new graphics are the background and the image box close/next/prev buttons. I'll be sure to make a contemplates template when I get all the heavy lifting down.
There are three kinds of "screen styles", full text (the top in the video), image+text (the middle screen), and thumbnail/full image (the bottom).
All the data for the journal/fluff viewer is controlled by a few config files. The screens can be renamed and you can have as many (long long) entries as you like! If entries get too long, the scroll buttons take care of the rest.
The script keeps track of what you've read as well, so you can easily find new entries you might have missed before.
As well entries can be hidden until they are revealed in a campaign.
Entries can also be reversed sorted, handy if you want most later entries on the top (if you want to do e-mail or a diary)

Can you replace the tech room with this? Technically yes, but you would lose the mission sim and the normal ship tech room. I just hijack the mostly harmless Barracks screen. Hijacking the tech room with its complicated 3 panel layout would be too much work I think.

This isn't ready for release yet, I just thought I'd show this off in case anyone had cool suggestions or ideas. If you are really interested in using this, let me know and maybe you can get a pre-beta version to help me bug test. ;)
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: General Battuta on February 18, 2014, 10:17:45 pm
Pure, unfiltered genius.
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Lorric on February 18, 2014, 10:39:42 pm
It's extra nice for me seeing the WoD people in there. :)

And when Did Luna get a full name? She was just... Luna...
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Droid803 on February 18, 2014, 10:45:57 pm
Awesome, finally a system that lets you go back and see Fiction Viewer entires unlocked in campaign without booting up the mission in techroom again :D
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 18, 2014, 10:54:13 pm
It's extra nice for me seeing the WoD people in there. :)

And when Did Luna get a full name? She was just... Luna...

Luna has had her name all along, all the data is from the intel entries from the WoD tech room. (This right here proves my point exactly!)
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Lorric on February 18, 2014, 11:04:26 pm
It's extra nice for me seeing the WoD people in there. :)

And when Did Luna get a full name? She was just... Luna...

Luna has had her name all along, all the data is from the intel entries from the WoD tech room. (This right here proves my point exactly!)
Must have slipped my mind, I have been there in the past. Thanks. And good luck with this. :nod:
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: niffiwan on February 19, 2014, 12:02:39 am
Very cool!  :yes:

Now... what happened to that feature suggestion re: adding new "rooms" to the mainhall....
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Black Wolf on February 19, 2014, 12:18:19 am
This is pretty cool - clearly not meant to replace the techroom (I could imagine using this much more for meta stuff, while the in-universe data is still presented in the traditional way), but a fantastic supplement.

That said, while I like the idea, and it's well executed, I am a tad concerned about entirely replacing and eliminating the Barracks. You were right to pick it - it's probably the least used and least important of the subsections off the mainhall, but it's not entirely unused or unimportant. Rather than replacing, could this functionality be added as a new subsection from the mainhall? I realize that that's probably well beyond the scope of this project at this point, but it'd certainly be a big improvement in the medium term. Of course, you've probably considered that already, but just in case...

Otherwise, I do have one request, though split up into a couple of sub points points (in decreasing likelihood of getting implemented :p ):

First, I couldn;t help but notice that you can click on the pictures, which suggests that scripting allows that part of the screen to accept input - does that mean that there's potential (perhaps over the long term rather than at version 1.0) for inter-entry wiki style linking? I proposed this awhile ago (http://www.hard-light.net/forums/index.php?topic=75377.msg1492550#msg1492550), but was told on IRC that it wouldn't be practical because that part of the techroom could only passively display data, and that changing it to accept input would be a big task and require a tonne of rewriting of the way the interface system works.

Secondly (and I know I'm probably shooting for the moon here) - given that scripting can apparently fiddle with the interface like this, if the above mentioned wiki-style linking does turn out to be possible, might it be a somewhat simpler task (than the previously mentioned massive rewrite) to supplement or recreate the tech room (either just the intelligence section or even better (and less likely) the whole thing (bar the mission simulator) with such a system, and then get a similar linking system in there? It's obviously not a requirement, and I have no idea if it's even practical, but I do think it would be very cool if possible.

Of course, even if none of this is possible, this is a pretty cool addition that will probably get lots of use.
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 19, 2014, 07:42:41 am
In theory, it doesn't have to replace the barracks. Different screens in Freespace are tied to different Game States (http://www.hard-light.net/wiki/index.php/List_of_Game_States). The Journal is actually a generic scripting game state screen (which oddly enough isn't on that list (mental note add it later)). So when I go to the Barracks, the script immediately changes to the scripting state. Now the primary issue is that we're limited to what we've got in mainball buttons. I can't create a new one for the retail interface, so I need to replace one. Now on a simpler non-fancy mainhall (something with only simple buttons) I could make it look like there's an extra button, but that would just be LUA emulating what the game already does.

Anyway, to your ideas...

1) I can do clickable buttons that are image, text, or both, so in theory, I could link entries together. But like the tech room, this is geared toward passive text content. Images are easy because they're huge and there's equations that place them where they are. Text links could be anywhere and since text basically gets drawn as an image, introducing markup to text would be quite the effort. Maybe in the very long term though?

2) Recreating the tech room could be possible buuut... since the above is out for the long term... no, not right now. But maybe in the future we'll have a proper custom moddable interface with html5 and live twitter feeds.
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Luis Dias on February 19, 2014, 09:42:10 am
live twitter feeds.

if you were someone else i'd laught that off as a joke.
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 19, 2014, 12:07:19 pm
Hmmm... lua library for twitter... (http://silverthorax.com/libs/twitter/examples.html)
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: m!m on February 19, 2014, 01:16:35 pm
Well, after SDL finally gets merged to trunk I want to try integrating Chromium into the engine sooo twitter might be possible in the future :p
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Droid803 on February 19, 2014, 09:03:01 pm
Wait, you could add a button in the fluffroom that say, takes you to the tech room, or barracks, right?
That way it isn't "replacing" anything?
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 19, 2014, 09:34:47 pm
There's a lot of ways you can add the screen, either replacing another or just extending on to another one. My own concern was to keep it consistent with how the normal interface acts.

You could have a tab on the fluff viewer that takes you to the tech room, but the tech database would need to be the top tab because that's how its interface is set up.

(WTB Better interface modding plz)
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on February 23, 2014, 03:14:40 pm
(http://lazymodders.fsmods.net/axemart/FreeSpace/screen0427.jpg)

This could be fun...
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: X3N0-Life-Form on February 23, 2014, 03:48:17 pm
Is much promising for teh fnu. :)
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: AndrewofDoom on March 09, 2014, 09:11:09 pm
The mainhall button seems redundant, since I can just hit escape and go there. Unless of course, you got plans to seamlessly go there without loading times.
Title: Re: Journal/Fluff Viewer (WIP!)
Post by: Axem on March 09, 2014, 09:25:44 pm
Just having the escape button as the only way to get back to the mainhall isn't that smart to me. It's not obvious to the player and it railroads him to the campaign. If you have got a fancy pants universe you'd like for people to explore, why not give them a little hint that they can go back to the mainhall and explore the database or journal?