Modding Discussion Any mods out there that change the color of water?

Discussion in 'Starbound Modding' started by rosennetyle, Jan 1, 2016.

  1. rosennetyle

    rosennetyle Void-Bound Voyager

    I would like to have a way to have colored water that would be safe to use in many places for builds without having to use dangerous liquids like poison and lava as a "water" source. I've tried looking for a simple mod to change just the water, but I haven't found what I was looking for, or might have missed it somehow in my search.

    However, if there isn't a mod for just changing the color of water, could the use of dyes work for changing water (As a mod itself)? I don't know how simple or complex that would be but would give another cool use for dyes and a little wider range for the looks of builds.

    If this hasn't been done before, the idea I have for this is that a single dye bottle would cover the range of all the water you have placed, but gathering the water will turn the water back to normal. You can add more water to the colored water to increase the volume, but can't suck up the colored water to place it somewhere else, or to add it to another water source, pure or colored. Mainly because that would take up 11 spaces with different colored water blocks, and color mixing is not possible with using the dyes. But if anyone has anything to add to the idea, feel free to do so!
     
  2. Monijir

    Monijir Scruffy Nerf-Herder

    I'm not sure what you mean by the single dye bottle - would it be like the paint-gun where you scroll through the options? I like your reverts to plain water on pickup detail. It seems like you've thought most of this through, are you planning on creating the mod yourself?
    Because I like to get over-complicated ideas out of my system here's a way-to-hard-to-implement-idea (TM) : Create dye liquids which interact with water by converting it to dyed water. Let the regular dye liquid dye everything it touches :)
     
  3. rosennetyle

    rosennetyle Void-Bound Voyager

    Oh, by the single dye bottle, I mean these http://starbounder.org/Dye , the ones used for dying armor. It generally takes one bottle to dye each piece, and with the water, usually takes one drop of another liquid to turn the water into that liquid. With that in mind, I thought the dyes would work well with that same principle in mind. And thank you, I tried to think out as much as I could with the water of starbound. Unfortunately, though, I will not be making the mod, I actually have no modding skills what-so-ever. |D;;;

    However, if someone reads this and is willing to make it, I would be very happy! But that's only if they are willing. I have no idea how hard it would be to do a modding like this, as simple as it (hopefully!) sounds.
     
  4. Spacedino

    Spacedino Ketchup Robot

    I'm not gonna do it :p
    but you might want to (or want others to) look into liquid interactions.
    There should be a system in starbound for what happens when two liquids (aka colored water and clear water) connect.
    This could be used to spread color through the water, though you still need to get a first piece of colored liquid in via some other way.
    This also would require a modder to specify each variant of colored water in a .liquid file with its own details and possibly texture.
     
    Last edited: Jan 5, 2016
  5. TheElderScroller

    TheElderScroller Pangalactic Porcupine

    With that system it should be doable very easily.
     
  6. rosennetyle

    rosennetyle Void-Bound Voyager

    Haha, fair enough.:D

    I've been looking through all the files for liquids and their interactions, but my biggest problem is, I pretty much don't know coding. I have had a bit of help from Monijir and modding guides, but I'm still a newbie at this.
    But could there be some files that aren't in the assets, or under different names that aren't quite related to liquid physics? I've been looking and only found a few files that might be what's needing modding for the water.
    I was told that the watering can coding might be a good start, And I guess I could cheat in some colored liquid (after making assets for them first) with their own unique item IDs...
    But I would still be unsure on some (If not most) of the details due to not knowing the data values in the .liquid file. But would probably be easier to make copies of it and mess with that.
     
  7. Peacecrafter

    Peacecrafter Void-Bound Voyager

    I mean its really easy to design and add a new liquid into the game. It gets harder when you want a way to create that in-game outside of a crafting table....I will throw one together that involves a crafting table and 3 different liquids really quick but it would probably take me ages to figure out how to set up liquid interactions.
     
  8. Peacecrafter

    Peacecrafter Void-Bound Voyager

    Alright I started a little bit ago but I'm hung up on the liquid ID value, starting to search for where that links too, other then that I'm done.[DOUBLEPOST=1452058830][/DOUBLEPOST]Never mind, I just set it to a super high value because I realized I was defining two presets from water. I'll start at 50. So I'm done I'll post a link to the download. If you like it I'll make more colors. In the mean time I will look into scripting the addition of dyes and the interaction between liquids. ANY and ALL information on liquids, including location, color values, update times and similar mods would be helpful.[DOUBLEPOST=1452059703][/DOUBLEPOST]http://community.playstarbound.com/resources/colored-water-mod.3340/[DOUBLEPOST=1452061558][/DOUBLEPOST]I understand I'm giving you all a bunch to read when you wake up, but I'm sick and this is keeping my mind off of it. I figured out how to work the waters interactions, it's currently immiscible with other liquids and will form like oil on water . . . but chunkier. I'll start creating different colors and change red water to fake lava and such. Give me ideas for water interactions and I'll incorporate them. I'm leaning away from the idea of water returning to the regular color after you pick it up as its already caused me sufficient headache when testing it. If you have a good argument for it let me know. I tried the changing of liquids upon adding dye and I think it crashed me on lag alone. I might tinker with it but it's not exactly simple.
     
    Last edited: Jan 6, 2016
  9. Spacedino

    Spacedino Ketchup Robot

    One note on modding liquids: Every liquid in Starbound needs a unique id or else there might be errors (Freezes, crahses, liquid may not show up at all etc.)
    The id has to be a number, which complicates things unfortunately. If two mods use the same liquid id for one of their liquids, the mods are incompatible.
    For example using liquid id 50 will make your mod incompatible with Frackin Universe, since that also uses the 50 for one of its liquids.

    Ah what the hell, i need to spill my ideas now too:
    Liquid color depends on the "color" specified in the .liquid file and the color of the liquids texture.
    To change the color of a liquid you will need to change the color values and give it a texture that supports the color you want (so a red texture for a red liquid)
    This is kind of a simple explanation but thats all there is to the color as far as i know.

    To create a new liquid you will have to create a liquid item as well. The .liquid files of existing liquids should have the names of their corresponding liquid items in them, so you know what to search for.
    To create new liquid items you can pretty much copy-paste one and change the name and icon. If theres a liquid-id value somewhere in the liquid item file you will have to set that to match your new liquid as well.

    With that you should be able to spawn your custom liquid via cheats at least.

    Some form of cleaning machine, or cleaning liquid that will remove color and return it to regular water.
     
  10. Peacecrafter

    Peacecrafter Void-Bound Voyager

    Yep I've figured it all out now the first three color values represent RGB and the fourth is transparency, liquid numbers represent each liquid and assign it an ID specifically for retrieval and interactions. Textures have no bounds on color despite their appropriate shading. I found this out when I noticed poison referenced the water texture. I've created fake lava, fake poison and red colored water in this next mod patch. Knowing that Frackin Universe uses liquid ID 50 is super helpful, if there was a master list of liquid #'s claimed for capability or a workaround that'd be awesome to hear about. I'm trying my best to avoid having to use inventory cheats, despite me frequently using them for testing, as it'd be nice to implement these into someones game with a fair basis. I saved the crafting recipes under plain tier 1 so everyone should have them if they have the mod. It's starting to become pretty smooth and as soon as I clean up more code and get some feedback I might just go all in and make a dyed water crafting station and move the recipes there.[DOUBLEPOST=1452072949][/DOUBLEPOST]I love you idea about a cleaning machine so I'll probably throw that in there if I make the unique crafting stand!
     
  11. Spacedino

    Spacedino Ketchup Robot

    Another one of my ideas that I'm too busy to implement right now, is to use an activeitem to change watercolor somehow. That way coloring water might work more similar to Starbounds painting tool. As you can see from my profile picture, I'm no stranger to the custom watering can, but i don't have enough experience / knwoledge yet to replace liquids using an activeitem, or to change the state of the item to change the target to different colors.
     
  12. Peacecrafter

    Peacecrafter Void-Bound Voyager

    I tried using a active item to replace segments of water and I crashed without an error code, I assume lag but not enough time spent investigating. I hope I can still bother you for help if I get stuck up-ahead but I'm calling it a night for now! G'night hopefully I will tackle this active item and new crafting station with a clear head tomorrow!
     
  13. Mackinz

    Mackinz The Waste of Time

    To keep track of the liquid IDs which are in use, please use this resource:

    http://starbounder.org/Modding:Liquids:Mods
     
  14. Peacecrafter

    Peacecrafter Void-Bound Voyager

    That's sick thanks! Also I keep running into things like this in the vanilla code
    "value" : "Golden Moustache"
    It's honestly wonderful
     
  15. Peacecrafter

    Peacecrafter Void-Bound Voyager

    I just posted the first usable version that has something near 20 new liquids, I'll take all ideas for new recipes, its also got a neat new crafting table and such.
    rosennetyle working on some more art atm, go check it out if you can spare the time.
     
  16. TheElderScroller

    TheElderScroller Pangalactic Porcupine

    You could make the liquids apply the color statusEffects to the player. Like Green Water colors one green. Or make a "strong" version of each color which only paints entities.
    You would also have to add some color effects then....
     
    Peacecrafter likes this.

Share This Page