Modding Discussion [WIP] Grey Goo

Discussion in 'Starbound Modding' started by Pinaz993, Nov 6, 2015.

  1. Pinaz993

    Pinaz993 Void-Bound Voyager

    I’m going to come out and say that I came here from the Minecraft modding community. For all its faults, that community has something that this one does not; the concept of automated mining and resource gathering. However, the concepts that are usually used for automated mining are simple, straightforward, dependable, easy-to-use… and boring. Placing down a block and a power supply and leaving it to dig a huge whole in the ground is not my kind of fun. I want something that you have to babysit a little. (Plus, I think that introducing the concept of machines that keep chunks loaded is a very bad idea.)


    While I have never made a mod in Minecraft myself, I have played with more than my fair share of mods and one of them sticks out as a (possibly) good idea to implement to fill that gap. It was simply called Grey Goo.


    While I am most likely not going to make a straight copy of the mechanics from the original Gray Goo mod for Minecraft, I am going to copy quite a few of the mechanics, namely:

    · Grey goo is your first, and will not be used for anything except developing other goo.

    · Mining Goo (brown) eats through the terrain and leaves ores in small destructible foreground goo pods. The items that it leaves behind will be determined by a whitelist set by the player at time of goo programming.

    · Liquid Goo (blue) eats into (and destroys) liquid

    · Aggressive Goo (red) eats other Goo

    · Stable Goo (green) sits there and doesn’t do anything

    · Linear Goo (orange) goes in straight lines and can be directed using Stable Goo

    · Unstable Goo (purple) Eats everything slowly and decays after itself, leaving a hole that looks diseased.


    Cancer is (or, rather, will be) the cost to using goo. If a block of goo mutates, it starts to grow out of control. I will be implementing it in a multi-staged, planet destroying way. I haven’t worked that out yet, but rest assured, Goo will be risky to use in some way, at some point in the future.


    I plan to make the different type of goo using an attributes system. A color will represent an attribute, and goo will be able to have multiple attributes applied to it. For example:

    · A red-brown goo would do the same as the brown goo, but it will act a lot faster, and will be limited in range.

    · A blue-green goo would eat into liquids, but will not decay after itself.

    · A red-purple goo would eat other goo, but decay after itself.

    I plan for all of these to be programmed individually, as I want specific control of their behavior.


    Lag is of course, a serious concern with this mod. We can’t just have exponential scripts eating up our system resources, can we? I plan to implement a global control variable that does not allow goo to replicate more than a certain number of times per game tick. I also plan for this limit to be modifiable by commands. The setting will persist between server boots.

    In addition, I plan for any and all stable goo to decay to a state that will no longer be running any scripts. I wish to use a “Langton’s Ant” style implementation, where only a small number of goo blocks are actually running scripts at a time for some types of goo, while other types of goo will decay over time reducing the number of instances.

    Alternately, I could use a global script to iterate over random goo blocks and activate them.


    I Need Your Help!
    • Please give me any and all suggestions about a good Lua code editor and syntax checker.
    • Is there any way to store small bits of data so that it can be accessed from anywhere in the universe, by any script?
    • Is there a way for me to change the biome of a planet after it is generated? (cancer related)
    • What are the limits of character-based chunk loading? (Are they even called chunks in this game?)
    • Any suggestions are welcome.
     
    Last edited: Nov 8, 2015
  2. The | Suit

    The | Suit Agent S. Forum Moderator

    You don't need any fancy IDE for starbound. After all you can only run specific functions and not the entire Lua environment.

    Blocks them selves cannot run scripts.
    The Goo them selves is going to be your ordinary entity script same thing as any monster.

    Biomes them selves are not defined once its generated - so the best you can do is simply change the blocks one at a time accordingly.

    There are no Global Variables - at best the variable is limited to the planet.
    Also only the area around the player is loaded. There used to be a mechanic to keep certain areas of the game loaded - even after the player leaves - but I am not sure if its still around.
     
  3. Graal

    Graal Big Damn Hero

    Isn't it set so that only what is on the screen is loaded?
    I remember zooming out to 0.25x in fullbright to see where my base was, it let me see a whole lot more than what I would be able to otherwise and it all loaded in as I zoomed out.
    As well as that, I could move the camera with ctrl and load even more.
    This DID eat up a hell of a lot of processing power though.
     
  4. Pinaz993

    Pinaz993 Void-Bound Voyager

    Alright!

    The reason I want an IDE is because it saves time tracking down errors., mostly with syntax stuff. Notepad++ sounds like it will work fine then.

    If all I have are planet variables, then I will have to make do with that. It may get a little taxing on multiplayer, but it should be fine. Maybe. If nothing else, I can petition the devs for a way to use globals, or something like it.

    As for entity scripts, can I make an entity that is invisible and doesn't take damage? If I need to, I can use the entity as an iterator, as long as the entity is allowed to teleport and be inside solid ground. As for blocks not running scripts, then I assume the liquids and various blocks that give you status effects are handled by the entity that touches them?

    As far a biomes go, I just want to change the biome if too much cancer is in the area. If I have block by block control (as I understand you are saying), I will be fine.

    If all that is loaded is what is on the screen, then I may have a big problem. However, crops don't seem to act that way. Maybe I can do something with that.
     
  5. 1hkem

    1hkem Void-Bound Voyager

    Since the goo can't be a block, why not make it a type if monster, like the goolix from pikmin? (Except smaller) then just set then to have a feature that allows them to delete blocks in front of them. Its like you basically make a pet in a lab, and that pet slowly destroys a world!
     
  6. The | Suit

    The | Suit Agent S. Forum Moderator

    '

    Yes - you can use invisible entities - a few mods use them to act as a go between to run scripts using call scripted entity function.
    The liquids which give status effects - are scripts which are hard coded.
    With that said though - liquids them selves cannot run the script but they can apply a S/E onto something thats about it.

    Crops are just updated upon load, they are not being actively updated.
     
  7. Pinaz993

    Pinaz993 Void-Bound Voyager

    I am not giving up on the idea just yet, however that is an amazing idea. I shall keep it in mind.

    Interesting. That is a really smart way to do crops.

    Invisible entities will limit what I can do, but at the same time will still allow me to do the whole 'world-eating nanomechanical experiment thing'.


    A few more ideas, written here for future reference and discussion:

    Those poop monsters you see in the Glitch-style sewer dungeons would make a great surface spreading technique. Change the texture and code in some behavior, and suddenly I have another thing to put in the "Cancer" file. (No, they would not create a goo spread entity every time they jumped, however they would cause the blocks under them to turn into goo and occasionally ma another goo spreader.)

    Health draining and goo spreading status effects will be a thing. As will antidotes for said effects. If you take one of those effects up to your ship, bad things might happen. A suit of armor designed to repel nanites might be a good thing to make before you get into this.
     

Share This Page