Jump to content

[1.12.x] IndicatorLights v1.8.3: Small, convenient, informative.


Snark

Recommended Posts

Thanks for the backstory, very interesting!

5 minutes ago, Snark said:

Perhaps I can cap it with a "dead" mesh that just stays dim, in effect erasing it from existence, so at least it won't be misleading the player.

That would be cool.  Don't stress over it though if it's a lot of work.

Link to comment
Share on other sites

3 minutes ago, Fwiffo said:

That would be cool.  Don't stress over it though if it's a lot of work.

Nah, that's pretty simple-- it's just placing one additional mesh on one part, and I can re-use the same "square lamp" indicator that I use for everything else (scaled appropriately to fit the right size & shape), just not wired up to any controllers so it stays off all the time.  Need to play around with it a little to see how it looks, but I suspect it'll be pretty quick to just slip that in to the next update.

Link to comment
Share on other sites

On 12/2/2016 at 6:48 AM, Bit Fiddler said:

 

could the lights on the Mk1 crew cabin be moved a bit...  there is a mod out there that adds a crew hatch to the top of the Mk1 cabin.  however this puts the LED right on top of the hatch window.  if the LEDs could be move to the sides, above the windows for instance this would be great.

 

Saw your post and decided to tinker with the LEDs with a Module Manager patch. How does this look?

zQWNMMW.png

The LEDs don't look too bad in this location without the hatch either.

Link to comment
Share on other sites

26 minutes ago, SchwinnTropius said:

Saw your post and decided to tinker with the LEDs with a Module Manager patch. How does this look?

The LEDs don't look too bad in this location without the hatch either.

Looks great!

I prefer to leave the default indicators where they are, but when that hatch mod is installed, your repositioning looks like the thing to do.  Could you package it up as a ModuleManager patch that runs only when whatever-mod-it-is happens to be installed, then send me the config?  (Either as a PM to me, or as a post over in the IndicatorLights Community Extensions thread.)  I'll happily package it up in an ILCE release.  :)

(Just for future reference-- anything having to do with "here's a tinkered thing to make IL work with <some other mod>" is best discussed over in the IndicatorLights Community Extensions thread.)

Thanks for digging into this!

Link to comment
Share on other sites

Howdy folks,

I've released v1.2.5 of IndicatorLights, with various bug fixes and moddability improvements.

New with this release:

  • Add "unknown" default color (magenta! but configurable), and enable crew indicators to use that for new kerbal types. (Thanks to @mikerl for the suggestion.)
  • Cover up a dummy stock "indicator" on the Z4K battery that was causing player confusion. (Thanks to @Fwiffo for the suggestion.)
  • Add situation() toggle syntax, with example config. (Thanks to @steedcrugeon for the feature idea.)
  • Fix a careless bug that broke the 3-argument form of the pulsate() syntax(Turns out I was never using it for anything before...)  :blush:
  • Fix a NullReferenceException bug that happens when a breakable part has an indicator that disappears when the part breaks.  (Discovered this in the process of testing a new mod to be released Real Soon Now™.  Stay tuned.)  :wink:
  • Update to ModuleManager 2.7.5.

Enjoy!

Link to comment
Share on other sites

17 minutes ago, Snark said:
  • Fix a NullReferenceException bug that happens when a breakable part has an indicator that disappears when the part breaks.  (Discovered this in the process of testing a new mod to be released Real Soon Now™.  Stay tuned.)  :wink:

wonder what this could be... :sealed:

Link to comment
Share on other sites

6 hours ago, steedcrugeon said:

wonder what this could be... :sealed:

For anyone else who may be wondering, this is the new mod:

...which, naturally, is IndicatorLights-enabled.

JX2LDA.png

JX2animation.gif

It's a joint project between me and Mister Wonder-what-this-could be, here.  :P  Basically, he does all the hard work and supplies all the artistic talent.  I publish the mod and supply config files and gratuitous nitpicking.  Go team!

 

Link to comment
Share on other sites

  • 2 weeks later...
1 hour ago, jlcarneiro said:

@Snark, is it possible to make Indicator Lights compatible to Kerbalism? Maybe because Kerbalism now has its own science module (with hardrives), Indicator Lights keeps blinking even when the experiment has been extracted...

It may or may not be possible to make the two mods work together... but I suspect that the fix would have to happen in Kerbalism, not IndicatorLights.

Technobabble details below in spoiler section, but the TL;DR is:

  • IndicatorLights is already using the standard, universal way of asking parts "do you contain science?"
  • If Kerbalism were using that mechanism, then IndicatorLights would already work with Kerbalism and you wouldn't be seeing this bug.
  • Since you're seeing this bug, I therefore infer that Kerbalism is not using the standard mechanism-- i.e. in effect, it has invented its own secret code.
  • Therefore it's impossible for IndicatorLights to do anything, and the only way to fix it would be for Kerbalism to switch its implementation to support the standard mechanism.
  • If that's the case... I don't know how practical it would be for Kerbalism to do that (or how inclined its author would be to make the change).

Okay, technobabble follows.

Spoiler

The IndicatorLights "stop blinking, it's on the ship somewhere!" feature is programmed in the most generic way possible, based on how the stock game manages science experiments.  It's based on the assumption that every science experiment lives in a PartModule that implements IScienceDataContainer.  Every stock PartModule that can store science (e.g. ModuleScienceExperiment, ModuleScienceContainer) implements that interface.  It's what the interface is for.

So... IndicatorLights makes no assumptions at all about what the actual PartModule is; all that matters is that it supports the standard, universal interface that says "I can haz science."  If some random mod author somewhere were to produce their own new PartModule type, and that PartModule supports the IScienceDataContainer interface, then IndicatorLights will automatically know how to talk to it, since they're speaking the same language.

I have no idea how Kerbalism has implemented its science-module-with-hard-drives thing that you mention.  However, given that you're observing this bug, I infer that it's not implemented to support IScienceDataContainer.

If that's the case, it's basically impossible to implement anything on the IndicatorLights side of things.

It may be worth asking the Kerbalism author about this.

If it is indeed the case that he hasn't implemented IScienceDataContainer on his custom module, I don't know the reason why.  It's a pretty simple interface; maybe it just didn't occur to him that it was necessary, and he just didn't get around to it, and it would be easy to add.

Or, on the other hand, maybe there's some technical reason why doing so would be difficult, and adding it would be impractical somehow.  For example, maybe it completely replaces KSP's stock science system with some new way of managing science, or something.  If that were the case, I'd guess that this would be in the ain't-gonna-happen category.

Without knowing anything about the Kerbalism implementation, or how much time the author has to spare for this sort of thing, I simply have no idea.

Anyway, those are my initial impressions on the subject.

 

Link to comment
Share on other sites

Hi all,

I've released v1.2.6 of IndicatorLights, a.k.a. "The Enceos Edition".

No new player-facing features-- just some moddability improvements, prompted by helpful suggestions from @Enceos, who's looking to add IndicatorLights functionality to a cool mod he's working on.

New in this version:

  • Enable IndicatorLights to work with "tint" color on Unity shaders, not just "emissive" color. (Thanks to Enceos for the suggestion.)
  • Update the color-parsing logic to allow specifying alpha values in config, in addition to RGB. (Thanks to Enceos for the suggestion.)
  • Enable resource indicators to specify that they show the parent part's resource contents. (Thanks to Enceos for the suggestion.)
    • No, as a player, there's nothing new/special for you to play with (yet), though I did add an example config file that clones the BL-01 as an attachable resource indicator.  But this will open the door for modders to do cool things.
    • The default behavior remains as before, so existing games, mods, etc. are unaffected.  This is just new functionality for any mods that want to take advantage of it.
  • Change the default status of crew indicators from "off" to "on".
    • If you're already running IndicatorLights, this won't affect you at all, because your preferred default status for the crew indicators is already stored in your local config.xml file, and that's what will get used.  This change only affects people who haven't previously run IndicatorLights and therefore don't have a pre-existing config.xml file sitting around.

 

For the curious, here's the nifty mod that Enceos is working on, for which the above features will come in handy:

I haven't yet updated the wiki documentation for the new features, but will do so soon.

Link to comment
Share on other sites

16 hours ago, Snark said:
  • Update the color-parsing logic to allow specifying alpha values in config, in addition to RGB. (Thanks to Enceos for the suggestion.)
  • Enable IndicatorLights to work with "tint" color on Unity shaders, not just "emissive" color. (Thanks to Enceos for the suggestion.)

These are very additions cool and useful indeed...

 

16 hours ago, Snark said:
  • Enable resource indicators to specify that they show the parent part's resource contents. (Thanks to Enceos for the suggestion.)
    • No, as a player, there's nothing new/special for you to play with (yet), though I did add an example config file that clones the BL-01 as an attachable resource indicator.  But this will open the door for modders to do cool things.

will this change the default module resource indicator setup, or do you have to specifically point it towards the 'root' part in the Config. I'm just worried it may change how some of the indicators work/may work on some of my escape pod.

Link to comment
Share on other sites

2 hours ago, steedcrugeon said:

will this change the default module resource indicator setup, or do you have to specifically point it towards the 'root' part in the Config. I'm just worried it may change how some of the indicators work/may work on some of my escape pod.

Nope, it's fully backwards compatible, you should be fine.  :) (Now that the mod's "released" rather than being in pre-release, I work very hard to ensure that I don't break anyone who's already using it-- my changes are generally backwards-compatible.  If some circumstance did come up that would break people, I'd call it out loudly and specifically.)

Existing stuff will continue to work as-is.

For the technically curious, the way this new feature works is:  I've added a new field to the resource modules, called searchStrategy, with possible values of "host" (meaning "show resources on this part") or "parent".  The default value is "host", which is the behavior that everything has always had up to now.  So any pre-existing stuff that you have, where you don't specify any searchStrategy in config, will automatically get the default value "host" and continue to work as before.  To make it search the parent part instead of the current one, you'd need to add "searchStrategy = parent" to your config.

Link to comment
Share on other sites

1 minute ago, Snark said:

For the technically curious, the way this new feature works is:  I've added a new field to the resource modules, called searchStrategy, with possible values of "host" (meaning "show resources on this part") or "parent".  The default value is "host", which is the behavior that everything has always had up to now.  So any pre-existing stuff that you have, where you don't specify any searchStrategy in config, will automatically get the default value "host" and continue to work as before.  To make it search the parent part instead of the current one, you'd need to add "searchStrategy = parent" to your config.

Excellent! I was going to ask how this should be implemented...

Link to comment
Share on other sites

Happy holidays! For those of you that decorate trees for the season, here's a little something I put together to celebrate the holiday:

DryjTYh.gif

http://imgur.com/DryjTYh

I made a part clone of the BL-01 and added the mesh from the Z-100 battery indicator to create the tubular light like those used in Christmas trees. Phasing of the light blinking could use a little tweaking to look more uniform, but it's pretty. Module Manager patch in the spoiler if anyone wants to have their own "tree" light.

Spoiler

+PART[indicatorLightSmall]:AFTER[IndicatorLights]
{
    @name = indicatorLightXmas
    @title = BL-01B Indicator Light
    @description = Doesn't achieve much, just looks pretty. It's tempting to place this on conical structures in snowy biomes.
    MODEL
    {
        model = IndicatorLights/Parts/indicatorLightSmall/model
    }
    MODEL
    {
        model = IndicatorLights/Meshes/z100lamp
        scale = 2, 4, 2
        position = 0, 0.13, 0 
    }
    MODULE
    {
        name = ModuleControllableEmissive
        target = IndicatorLights/Meshes/z100lamp
        emissiveName = light
    }
}

EDIT: Now available on KerbalX if you want to download it for your own save. (Requires the patch above and Fuel Tanks Plus, FYI)

Edited by SchwinnTropius
edited to better display .gif image: KerbalX link; typos
Link to comment
Share on other sites

5 hours ago, SchwinnTropius said:

Happy holidays! For those of you that decorate trees for the season, here's a little something I put together to celebrate:

Thank you, for sharing that with us, that's awesome!  :D  (I was wondering "which IndicatorLights user is going to be the first one to post a Christmas tree"...)

[EDIT] Hmm, something odd happened when I tried to copy the URL from imgur, it didn't actually populate the clipboard and had an outdated URL that got pasted without my noticing.  Deleted.

Link to comment
Share on other sites

1 hour ago, Snark said:

Thank you, for sharing that with us, that's awesome!  :D  (I was wondering "which IndicatorLights user is going to be the first one to post a Christmas tree"...)

Here it is in embedded inline-image form, so that anyone skimming this page in the future won't miss your deceptively inconspicuous post!

ezgif.com-52b883ea4b.gif

 

Didn't show there either. I found the imgur bit to embed it directly into my earlier post, so now all can see it in its BlinkenLights glory!

Edited by SchwinnTropius
typos
Link to comment
Share on other sites

Hi all,

I've released v1.2.7 of IndicatorLights.  New with this release:

  • Added crew indicators to the Mk3 cockpit and Mk3 crew cabin.  (Thanks to @SchwinnTropius for prodding me into doing this.)
  • Added compatibility patch for KIS(Thanks to @Enceos for pointing out the need for this, and for tracking down the right syntax to do it.)
  • Added new hasCrewEffect() toggle syntax.
  • Updated the MPL science lab's crew indicators to use the new hasCrewEffect() syntax.

The KIS compatibility patch has to do with "stackability": specifically, the ability to "stack" multiple items of the same type in a single inventory slot in a KIS container.  Prior to this patch, lots of stock parts that previously were stackable became unstackable, due to the modules that IndicatorLights adds.  This fixes that.

For a player, the change to the MPL to use hasCrewEffect() will appear to make no difference.  The change here is a subtle one, and is of interest primarily to modders-- it becomes relevant if someone is running a mod that adds new types of kerbals (besides just pilot, engineer, scientist).  It allows having config that's based on what a kerbal can do (e.g. "repair stuff") rather than what a kerbal is (e.g. "engineer").  So, for example, the science lab's crew indicators use a flashing animation to indicate "you've got the wrong kind of kerbal in here!"  But what does "wrong kind" actually mean?  Up until now, I had it coded as "scientist".  Well, actually, what we really care about is not "has the job title 'scientist'", but rather, "has the ScienceSkill effect that allows operating a research lab."  In the stock game, those two things end up being the same... but suppose someone ran a mod that added some new kerbal type, other than scientist, which happens to have that particular scientist skill.  What then?  Well, the science lab should allow it, and not yell that it's the "wrong type."  That's what this change allows.

Anyway, enjoy!

Link to comment
Share on other sites

55 minutes ago, SchwinnTropius said:

Any chance of a link?

The KSP 0.242 mod GlowStrips.  The topic is locked as the mod developer hasn't been on the forums in well over a year.  The GDrive download link in it is still functional.

Direct link to the Imgur album from that post.

http://imgur.com/a/ybaoT

@Drew Kerman has a post on the last page explaining how to update the mod to KSP 1.0.4 to work.  Extending that method to KSP 1.2.2 might work, although more may be needed.

 

Edited by Jacke
Link to comment
Share on other sites

2 hours ago, SchwinnTropius said:

@Darth Jeb It probably can. Any chance of a link? I have an idea, but it's also 5am here and my idea may not quite sync up with yours. 

@SchwinnTropius Happy to hear. 

 

1 hour ago, Jacke said:

The KSP 0.242 mod GlowStrips.  The topic is locked as the mod developer hasn't been on the forums in well over a year.  The GDrive download link in it is still functional.

Direct link to the Imgur album from that post.

http://imgur.com/a/ybaoT

@Drew Kerman has a post on the last page explaining how to update the mod to KSP 1.0.4 to work.  Extending that method to KSP 1.2.2 might work, although more may be needed.

 

Thanks @Jacke for providing the link.

But the method that @Drew Kerman explained was to update KSPAPIEXtensions.dll but the dll itself was not updated after version 1.0.4

Link to comment
Share on other sites

After looking at the imgur album, something like that can be done. I can probably put together a config for a part that does that with existing models in this mod, but I think @Snark should be the one to give the final go-ahead on it. (Plus I'm at work on break, and using mobile so can't quite write anything right now)

Link to comment
Share on other sites

12 hours ago, Darth Jeb said:

There used to be a mod Glowstrips (1.0.4) it was cool and gave a sleek look to the craft. So can this mod be configured somehow to function like Glowstrips ?

So I took a look at the Glowstrips OP, and the imgur album.  Here's my take on it, viewing it through IndicatorLights-tinted goggles, as it were.

My understanding (based on a cursory perusal of the mod thread) of what Glowstrips provides is this:

  • A set of radially attachable parts (the "strips"), which happen to have very simple emissive textures on them.
    • Apparently they're available in various fixed sizes (which would just be ordinary parts), plus one that's adaptive-length, so I assume the model for that one is some sort of procedural thing.
  • Some tweakables that allow specifying the color of the strips, and such-like.
  • A set of future feature plans (which never happened before the mod was abandoned) that would have given the strips various interesting behaviors.

So, what would this be like in IndicatorLights terms?

  • Aspects that would be easy to do with IndicatorLights:
    • Have a set of "glow-strip" parts, in various fixed sizes.
    • Would require new models for the parts, but the models would be so dead-simple that even someone like me could model them.  Basically, just a long thin strip of emissive material.  Heck, I managed to model the BL-01, and this would be a lot simpler than that.
    • Add config to those parts supporting the same part modules that IndicatorLights' BL-01 light already uses.  Basically, you can think of such a part as a very long, skinny BL-01.  This would give the behaviors that Glowstrips describes:  can turn on and off with action groups or part menus, customizable colors, customizable blinking if desired.
  • Aspects that would be hard to do with IndicatorLights:
    • The Glowstrips mod mentions one part that's adaptive-length.  That would require some sort of procedural model, which IndicatorLights doesn't support (and frankly I'm not inclined to add such a feature; sounds like a lot of work).
  • Bells and whistles:
    • Once the basic parts are available (with BL-01 type behavior), of course anyone who's willing to tinker with config (e.g. via ModuleManager) could adjust the way the strips work if they wanted to customize the visual appearance of the lights (e.g. pulsating animations, or color cycling, or whatever).

Anyway, that's my take on it.  Let me think on it a bit-- I need to consider whether (and how) to incorporate something like this into IndicatorLights itself.  In the meantime, though, it's worth noting that such a feature is just about models and config-- there would be zero new code required.  So there's nothing stopping anyone from modding up some parts like this to use IndicatorLights to drive them, if so inclined.  (Well, other than potential concern that I might add this to IL and render such a mod moot.)  :wink:

Anyway, it bears mulling over; gimme some time to think at it.  No promises.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...