[Tutorials] Slipstream tweaks Empyrion

Discussion in 'The Hangar Bay' started by Slipstream, Dec 26, 2017.

  1. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    With the honor of being pinned to the wall by @Hummel-o-War, I have edited the first post to serve as a table of contents/organizational/informational "First Post". Click on a link below to jump to that tutorial/post!

    Discussion/theorycrafting posts:
    Configuration/coding snippet posts:
    Other very useful handbooks, guides, and universities:
     
    #1
    Last edited: Dec 31, 2017
    Andipro, Na_Palm and Hive like this.
  2. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Did you know that 'projectiles' (rockets, plasma cannon shots) have a maximum duration of 10 seconds? Well, now you do! This means if you set speed that is slower than 1/100th of the range, your weapon won't actually have that range.

    Example:

    Set the speed of the SV Plasma Cannon ammo to 10. The projectile will be removed from the playfield in 10 seconds, or 100m. 100m is now your maximum range.

    ---

    Not many folks will be playing around down at these speeds, but it's a fun fact. :)

    Bonus party trick: Set the speed of an SV rocket to about 50, fire a spread, then fly ahead of them. Make sure your server is set for "Friendly Fire". Amaze your friends!

    ---

    Share what YOU'VE broken using the config file!

    ---

    For your amusement, the results of the experiment to load ship-killing torpedoes on SVs. Note: The effects are set high for exaggeration/clarity. I would not, for example, give a weapon 99999 damage/99 blast/99999 blast damage...



     
    #2
    Last edited: Dec 31, 2017
    Andipro likes this.
  3. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Let's talk RCSes, shall we? *dodges pies, fruit, sledgehammers*

    Millions of electrons have died in discussions about the general turnableness of ships in Empyrion. Here, I'm going to take a look at the factors behind the madness. We'll focus for the moment on the Elephant in the room, aka the T2 CV RCS.

    This isn't about the real world, this is about presentation in the game, and a smidgen of expectations.

    The humble T1 CV RCS stats out thusly:
    • Block Size: 1x1x1
    • Energy consumption: 1 Watt
    • Mass: 40,000 Kilograms
    • Torque: 20,000 Newtons (this is how much rotational force it provides)
    • Construction Costs:
      • Constructor: Advanced
      • Time: 15 seconds
      • Energy Matrix (2) - Cobalt (4) Copper (2), Silicon (2)
      • Electronics (3) - Copper (3), Silicon (1)
      • OpticalFiber (3) - Silicon (1.5)
      • SteelPlate (20) - Iron (4)
      • Oscillator (4) - Neodymium (20), Cobalt (8), Sathium (8)
      • TOTALS
        • Cobalt Ingot (12)
        • Copper Ingot (5)
        • Iron Ingot (4)
        • Neodymium Ingot (20)
        • Sathium Ingot (8)
        • Silicon Ingot (4.5 [5])
    We won't discuss Tech Level or Unlock Points, because those are truly arbitrary. You can hit L25 in a very short while, so those numbers are irrelevant for the comparison.

    The key restriction here is the 'rare' elements. While Cobalt can be acquired on any starting planet by boulder-busting, the rest either comes from loot crates or deconstruction. Of course, if you have access to space, then 'rare'...isn't.

    Let's look at the T2:
    • Block Size: 1x1x1
    • Energy consumption: 1 Watt
    • Mass: 60,000 Kilograms
    • Torque: 500,000 Newtons (!)
    • Construction Costs:
      • Constructor: Advanced
      • Time: 15 seconds
      • RCS (T1) - See Above
      • Energy Matrix (3) - Cobalt (6) Copper (3), Silicon (3)
      • Electronics (3) - Copper (3), Silicon (1)
      • OpticalFiber (3) - Silicon (1.5)
      • PowerCoil (4) - Erestrum (24), Zascosium (24), Sathium (8), Neodymium (20), Cobalt (8)
      • TOTALS
        • Cobalt Ingot (26)
        • Copper Ingot (11)
        • Erestrum Ingot (24)
        • Iron Ingot (4)
        • Neodymium Ingot (40)
        • Sathium Ingot (16)
        • Silicon Ingot (9)
        • Zascosium Ingot (24)
    Again, the gate-keeping here is the classic requirement of E & Z ingots. Everything else is readily available in any of the starting playfields. It is also very important to note the Advanced Constructor requirement, which applies to both devices. To build a Capital Vessel, you need to find an Advanced Constructor, or enough E&Z to build one. Finding enough E&Z to build a T2 RCS means deciding where to put this momentarily limited resource to use. Once the availability of E&Z becomes plentiful, when a player acquires the ability to warp to other systems, the gate-keeping is removed entirely.

    Why did I type all this out, then? To show that there is, effectively, no actual barrier to building T1 or T2 RCSes after the first couple of play sessions.

    That leaves us with the hard metrics on performance:

    T1 RCS
    • Energy consumption: 1 Watt
    • Mass: 40,000 Kilograms
    • Torque: 20,000 Newtons
    T2 RCS
    • Energy consumption: 1 Watt
    • Mass: 60,000 Kilograms
    • Torque: 500,000 Newtons
    I've highlighted what I feel are the two issues. Mass is not a substantial issue, especially given the torque differential. Both devices are the same size. Both have the same blast radius/damage potential, which means there's no risk increase in combat.
    1. The fact that BOTH RCSes require only a single Watt of energy is the biggest problem. Spinning up a gyroscope that can rotate 40-60,000 kilograms (IE: Just the RCS itself) requires a lot of power. This is what we talk about when we discuss 'energy efficiency'. RCSes are the most energy efficient structure in the game. This needs to be adjusted.
    2. For what we have demonstrated is a negligible "cost" increase, the T2 RCS delivers 12.5 times the force of a T1 RCS. That's over an order of magnitude. This is unworkable.
    Looking at the other statistics of T1/T2/T3 devices, I honestly think the 500,000 newton figure on the T2 RCS was either a debugging choice, or a typo. Going from 20,000 to 50,000 would seem to be a much more reasonable performance increase.

    To anyone looking to tweak your Config.ecf file, this is where I'd suggest starting. Set the Torque of the T2 RCS to 50,000, and up the energy consumption.

    Good luck, and tell me how it goes!
     
    #3
    Andipro, rainyday and SacredGlade like this.
  4. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Today, I tested a theory:

    Can you block-limit things other than weapons?

    Based on the observation that Repair Bays are limited to one (1) per whatever, I decided to mod my experimental Config.ecf file to see if I could crash Empyr...make changes to suit my needs.

    Yes, Virginia, you CAN block-limit pretty much anything.

    Keep Calm and Block-limit RCSes.

    --B.
     
    #4
    Ephoie, Andipro and SacredGlade like this.
  5. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Experimentation today shows us that 'perish time' is a bizarre number, unrelated to anything, really. :D

    It appears that each Perish Tick is equivalent to 3 minutes.

    This makes an egg (currently, the fastest perish time at 15) last about 45 minutes, real-time.

    A can of meaty-mc-meatstuff will last approximately 1050 minutes, or 17.5 hours.

    And now you know. And knowing is half the battle*

    --Brian

    *The other half is lasers. Honest.
     
    #5
    Ephoie and Andipro like this.
  6. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    So, one of the things you can do in Config.ecf is mess with the tech tree. You can:
    1. Set the tech level.
    2. Set the cost (in upgrade points).
    3. Set parents (IE: You have build the T1 pistol before you can unlock the T2 pistol).
    4. Set which tab (if any) the item shows up on.
    5. Add almost any item to the tech tree.
    6. Have an item added to the Constructor list (Survival, Mobile, etc.)
    There's more, but this is what I'm focusing on, in today's post.

    For example, I have added the Auto Miner Core to the tech tree at TL25, with a cost of 100, as part of the fuel pack branch:

    upload_2017-12-29_23-30-27.png

    In this case, I've also used the Localization.csv file to rename the Auto Miner Core to Fusion Core. I've now added the ability to construct cores in Empyrion.

    Neat, huh?

    Some notes on the Tech Tree UI:
    • There are only NINE columns in the UI. It no longer scrolls left/right. It used to.
    • If you set a TL for an item above 25, you cannot unlock it because there's a hard-coded limit of 25 in the game. However, it WILL show up on the tech tree...
    • ...if you make sure the TL of the item fits in the column. Using the above picture, if I had set my new "Fusion Core" to level 25, it would still show up, as it is the only item in L20. The column would change to "Level 25". Or "Level 50" if I had set it at that level.
    • If you have nine columns of tech levels, and you add a tenth TL, it will not show up, due to the loss of left/right scrolling.
    • If an item is set so it does not display on the UI, is of a TL higher than 25, or marked as hidden in the Config.ecf file, you can still grant it via a PDA mission. One possibility to use this is to set certain technologies as "Alien Supertech", and make it only available through PDA missions. Which gives a new reason to have to raid PoIs.
    And now you know!

    --Brian
     
    #6
    Andipro, Sephrajin, Exacute and 3 others like this.
  7. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Who likes the current medical/healing system? Don't be shy, raise your hand. Well, for those of you who did NOT raise their hand, let's take a look and what I have for you, today:

    upload_2017-12-30_3-23-29.png

    What does this achieve?
    1. Bandages, Ointment, and Stomach Pills are craft-able on the starter planets, and in the survival constructor. For those of you who are wondering, the wood planks are turned into activated charcoal. ;)
    2. Adrenaline and Energy Pills now burn off some 'food', to represent the increased metabolism hit. You need to visit both planets for a good supply of the raw materials for these, as it's easier to find thorns on Akua (but they are available on other worlds.)
    3. Anti-Rad pills require visiting both Omicron and Akua, in the beginning. Antidote injections require alien parts as that's a DNA sample of the creature. Purified water seemed a logical requirement for injections.
    4. We can use the 'lesser' healing items as components for the higher level ones, thus allowing the crafting of the heavy hitters to have a LOW crafting time in the food processor, by having other items pre-made. No waste, and allows for the forward-thinking folks to pre-stock important stuff which is useful BY ITSELF, and also as part of a higher tier of equipment. As the weight restrictions come in, this will also come to bear fruit. Right now, a great way to save on inventory space.
    5. As of right now, healing is magic. While it takes a smidgen of time for the healing effects to kick in, clearing the various debuffs is instant. I added a Stamina hit to the various pieces of kit to encourage people to slow down a tad/represent the effect of shock and trauma.
    If they give us the ability to assign buffs/debuffs, this list will get tweaked a bit. It would be nice to be able to make the Large Medkit into a true Field Kit that could heal every debuff.

    Let me know what you think!

    --Brian.

    PS: On the new server I'm designing, many of these items will require Plastic, to represent the casing. Injectors will probably need some form of metal, but that's a balance issue I'm still mulling over in my head.
     
    #7
    Andipro likes this.
  8. Fractalite

    Fractalite Rear Admiral

    Joined:
    Aug 10, 2016
    Messages:
    4,315
    Likes Received:
    8,845
    This is very interesting, nice work. I believe I am going to pass this up the chain.
     
    #8
    victusfate and Hive like this.
  9. Brimstone

    Brimstone Rear Admiral

    Joined:
    Dec 11, 2017
    Messages:
    632
    Likes Received:
    1,982
    Indeed. Hopefully the first thing they take from it is "fix the side scroll on the tech tree" ;)
     
    #9
  10. Robot Shark

    Robot Shark Rear Admiral

    Joined:
    Jul 3, 2016
    Messages:
    2,198
    Likes Received:
    5,768
    I wonder if you can tweak a survival constructor to be mountable in a CV?

    A long time ago I made a low-cost emergency CV that I envisioned players building to limp away from the battlefield after their battleship was destroyed. Since you cannot craft survival constructors, I wanted to include one in the blueprint.
     
    #10
    Hive likes this.
  11. Hummel-o-War

    Hummel-o-War Administrator Staff Member Community Manager

    • Developer
    Joined:
    Jun 15, 2015
    Messages:
    5,410
    Likes Received:
    8,429
    Nope. Placement switches are not possible via config.
     
    #11
  12. Hummel-o-War

    Hummel-o-War Administrator Staff Member Community Manager

    • Developer
    Joined:
    Jun 15, 2015
    Messages:
    5,410
    Likes Received:
    8,429
    #12
    Hive likes this.
  13. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    NOW I'm in trouble.
     
    #13
    Hive and Needleship like this.
  14. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    As Hummel says above, no. Which is sad, because it means no SV turrets, either. ;)

    HOW-EV-ER,

    You have control over what any given constructor is capable of building (Technical Boring Part: You're setting where a given block can be produced). So, in theory, should you choose to, say, mess with the power of the large and advanced constructors, you can.

    Not much use for anyone specifically building for Default Config (tm), but interesting for... THE FUTURE.
     
    #14
    Hive likes this.
  15. Robot Shark

    Robot Shark Rear Admiral

    Joined:
    Jul 3, 2016
    Messages:
    2,198
    Likes Received:
    5,768
    Hoped dashed, dreams shattered, but an answer, and appreciated.
     
    #15
    Hive likes this.
  16. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Also, there's no such thing as Santa Claus.
     
    #16
    Hive and Robot Shark like this.
  17. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    This will be the first config/coding snipping post. Today, we'll get comfortable with the structure of the Config.ecf file, and how to start doing some tweaking of your own!

    First, put on your safety glasses:
    • Do not directly edit Config_Example.ecf. This is the file provided by Empyrion and will be over-written willy-nilly by updates. Editing this file is the fastest route to anger, which leads to hate, which leads to the Dark Side.
    • Make a copy of Config_Example.ecf and work on that.
    • When you're ready, make a copy of your custom file, and name it Config.ecf.
    • Launch the game.
    • Bonus safety tip: Empyrion loads all configuration files at launch (NOT game creation/loading). Any changes you make to these files will not by applied to the game until you restart Empyrion.
      • Something to test: Connecting to an Empyrion Dedicated Server might be a way to enable a faster testing cycle, as I believe the config files are loaded on the first connection. However, you'd then have to restart the dedicated server each time.
      • Dearest developers, please add something like 'reloadconfig' to the command line. Thanks!
    Ready? Let's go!

    Below, are the entries for the three CV Fuel Tanks in the game. In the original game design capital vessels were referred to as MS instead of CV. I'm still decoding what all the entries represent, but there's a few that are very clear, or I've tested already.

    Devs (or anyone else) please correct my mistakes, and I'll update the post! :)


    { Block Id: 259, Name: FuelTankMSSmall # Block ID is the DB reference, Name is the internal name
    Group: cpgFuelTank # Control Panel Group, probably used for auto-sorting
    Material: metallight # This is used to modify weapon damage. metallight == basic steel block
    ShowBlockName: true # Unknown
    IsLockable: true # Allows the use of a lock code on the device/block
    IsOxygenTight: false, display: true # Airtight true/false. Display refers to when you mouse-over the icon
    StackSize: 5 # How many of these can be stacked. Max Stack Count: 999
    Info: bkiFuelTank, display: true # Unknown
    Category: Devices # General grouping, such as Devices, BuildingBlocks. Unknown what this affects
    Mass: 35000, type: int, display: true, formatter: Kilogram # Mass of the block, numerical precision, display in tool-tip, format
    EnergyIn: 1, type: int, display: true, formatter: Watt # Energy draw., precision, display, and format
    HitPoints: 25, type: int, display: true # How much damage it can take, precision, display
    FuelAccept: "EnergyCell, EnergyCellLarge, EnergyCellHydrogen, FusionCell, BioFuel" # Names of acceptable fuel items
    FuelCapacity: 1200, type: int, display: true # How much fuel can it take?
    BlastRadius: 5 # How large is the explosion when this block is destroyed?
    BlastDamage: 500 # How much damage does it do in the blast radius?
    Radiation: 0.25 # How much rad does this device put out?
    UnlockCost: 4 # Tech Tree: How many Unlock Points are required?
    UnlockLevel: 3 # Tech Tree: What Player Level is required to be able to use Unlock Points to unlock building the device?
    TechTreeNames: "Base,Capital Vessel" # Tech Tree: What tab(s) does this device appear upon?
    }

    Block Id and Name should never be changed. Ever. If you need/want to rename something, search for the Block's name in Localization.csv, and change it there. If you're hosting a multi-lingual server, hire someone to translate the rest for you, or, at least, toss it into Google Translate. Be kind, where you can, and people will flock to your server in gratitude. Maybe.

    You cannot invent your own Tech Tree tabs. Yet. (HINT HINT, DEVS) But you can put devices on any of the existing ones. Want to put the various generators (water, oxygen, hydrogen) on the Tools tab? Well, now you can.

    type (precision): If it is int, that means whole numbers. If it is float, that means you can use the decimal point. If there is no type defined, use the context of the file and lament the underpaid developers, toiling for your amusement.

    BlastRadius and BlastDamage are seen TWICE, both in the device statistics, and the statistics for weapons. Please do not confuse the two.

    The Tech Tree: notes are for folks who want to build their own tech tree for fun and profit.

    +---+

    Now, let's take a look at a 'child' or 'sub-block' entry. The important info is highlighted, below:


    { Block Id: 260, Name: FuelTankMSLarge,
    Ref: FuelTankMSSmall
    Mass: 75000, type: int, display: true, formatter: Kilogram
    HitPoints: 40, type: int, display: true
    FuelAccept: "EnergyCell, EnergyCellLarge, EnergyCellHydrogen, FusionCell, BioFuel"
    FuelCapacity: 2700, type: int, display: true
    Info: bkiFuelTank, display: true
    Radiation: 0.4
    UnlockCost: 12
    UnlockLevel: 10
    TechTreeParent: FuelTankMSSmall
    TechTreeNames: "Base,Capital Vessel"
    }

    Note the new entry on the first line, Ref: This means "bring in all the data from the block named <Blockname>". In theory, this means you only have to change what you want to change. I think they added the ability to Ref a parent object in the DB later on in the coding, and didn't clean up DB entries that were already more fleshed out. Examples of simpler parent-child entries are seen farther down the .ecf file.

    Trivia: I suspect the .ecf file is a quickly-coded dump of the internal database, which is then slurped back up when the game is first launched.

    TechTreeParent is the new addition, which determines what you must unlock, before you can unlock this device. This is how you can create dependencies in your custom tech tree. We'll talk about that more fully in a later post.

    +---+

    Let's look at the second 'child' of the MS fuel tank family:


    { Block Id: 1035, Name: FuelTankMSLargeT2, Ref: FuelTankMSLarge
    Mass: 159000, type: int, display: true, formatter: Kilogram
    HitPoints: 80, type: int, display: true
    FuelCapacity: 6000, type: int, display: true
    Radiation: 0.8
    UnlockCost: 20
    UnlockLevel: 15
    TechTreeParent: FuelTankMSLarge
    TechTreeNames: "Base,Capital Vessel"
    }

    Note, again, how you can change just what's needed. For example, the Info: bkiFuelTank, display: true is missing here. but it works, because it is inheriting it from FuelTankMSLarge. For sanity's sake, it appears to be best-practice to reference the next-parent-up the tree. Here the T2 CV Fuel tank's parent is set to FuelTankMSLarge in both the Ref and the TechTreeParent lines, whereas the T1 CV Fuel Tank references the original parent block/device.

    +---+

    Everything above, by the way, is NOT in the same location! As they add block/devices, they go into the DB wherever the next ID pointer is. We jumped from 259 and 260 to 1035 when they added the T2 CV Fuel Tank.

    Additionally, the crafting requirements are in a completely separate section of the Config.ecf file. Thankfully, you can search by the block/device Name field. Which is another fine reason why it is terribly important NOT to change the name field. Don't change the name field. Seriously. Don't make me turn this survival game around.


    { Template Name: FuelTankMSSmall
    # Matches the name field of the block/device
    CraftTime: 10 # Base crafting time, modified by settings. I have to experiment with how much time this actually is. [See: Perish times]
    Target: "SurvC,SmallC,LargeC,AdvC" # Where can I make this? Prank: Add FoodP to make, say, Erestrum Gel in the Food Processor.
    { Child Inputs # The existential question answered: What am I made of?
    Electronics: 5
    SteelPlate: 15
    OpticalFiber: 4
    }
    }

    I'm amazed you've read this far. Please have some Pumpkin Cookies and Mule Milk.

    Where can you make things?

    # Target Abbreviations:
    # SurvC = Survival Constructor
    # SmallC = ConstructorSV / ConstructorHV
    # LargeC = ConstructorT1V2
    # AdvC = ConstructorT2
    # FoodP = FoodProcessorV2
    # Furn = Furnace

    Here, I'd like to remind you, again, to close your [Explicative Deleted -- Ed.] parenthesis. Note how there's two sets of {}'s here to close! This WILL kill Empyrion! I promise!

    This is where I also remind you that an editor like Notepad++, which has built-in checking for such things, is a true miracle.


    { Template Name: FuelTankMSLarge
    CraftTime: 10
    Target: "LargeC,AdvC"
    { Child Inputs
    Electronics: 10
    CobaltAlloy: 6
    OpticalFiber: 8
    SteelPlate: 30
    }
    }

    { Template Name: FuelTankMSLargeT2
    CraftTime: 20
    Target: AdvC
    { Child Inputs
    Electronics: 20
    SteelPlateArmored: 30
    OpticalFiber: 16
    CobaltAlloy: 8
    }
    }

    You'll need to search through the .ecf file to find all the names of the various components. Child Inputs can be anything. If you want your Advanced Constructors to be made entirely from plant fibers*, please feel free.

    Note that you can also use child inputs that have their own construction costs. The game is smart enough to figure it out, and this is how you stack sub-assemblies into larger assemblies. I'm not sure what the hard limit is, in a constructor, for sub-components, so I'd keep the child inputs to a reasonable number of reasonably-not-complex-in-themselves items. A bad idea, for example, might be for a Repair Bay to require a Food Processor, Advanced Constructor, Cargo Block, T3 Fuel Tank, Dino Stew Royal, and an ATM.

    In general, keep things to five (5) Child Inputs, whose own Child Inputs are limited to 1-3 entries. If you add something complex, such as requiring a T1 miner to build a T2 miner, reduce the Child Inputs of the T2 autominer down. See below for the actual template entries.

    { Template Name: AutoMiningDeviceT1
    CraftTime: 50
    Target: AdvC
    { Child Inputs
    CapacitorComponent: 5
    SteelPlateArmored: 15
    Motor: 4
    FluxCoil: 5
    AutoMinerCore: 1
    }
    }
    { Template Name: AutoMiningDeviceT2
    CraftTime: 50
    Target: AdvC
    { Child Inputs
    CapacitorComponent: 5
    ZascosiumAlloy: 5
    PowerCoil: 5
    AutoMinerCore: 1
    }
    }
    { Template Name: AutoMiningDeviceT3
    CraftTime: 50
    Target: AdvC
    { Child Inputs
    CapacitorComponent: 5
    ZascosiumAlloy: 10
    PowerCoil: 5
    AutoMinerCore: 1
    }
    }


    I hope this helps someone. Bon chance!

    --Brian

    *"So Professor, you made this CV entirely out of bamboo, huh?"
     
    #17
    Last edited: Dec 31, 2017
    Syncretos, Andipro, Bollen and 5 others like this.
  18. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    Want to run the annual Nate's Akua Island Corn Dog eating contest? Easy!

    Set the ROF of the Corn Dog item to .1, stack size to 999, reload your server, pick a bunch of Corn Dogs (or use 'itemmenu' from the command line to give yourself a few stacks).

    Give every "competitor" a stack of Corn Dogs, and have at it. They can eat 'em as fast as they can click. Once everyone gets Food Poisoning, whomever has the smallest stack 'wins'.

    The prize?

    Stomach Pills for everyone.

    --Brian
     
    #18
    Syncretos, Hive, Sofianinho and 3 others like this.
  19. Slipstream

    Slipstream Captain

    Joined:
    Sep 22, 2016
    Messages:
    429
    Likes Received:
    964
    All the traders are SO FRIENDLY. Let's change that. Today, a look at the file TraderNPCConfig.ecf
    • As always: SAVE EARLY, SAVE OFTEN. As TraderNPCConfig.ecf is the live file, make sure you make a copy, and work in there, else you will LOSE ALL OF YOUR WORK WHEN AN UPDATE ROLLS AROUND.
    • Don't change the order of the traders. It breaks things. Add what you want at the top of the file.
    Now that the safety glasses are on, let's get to work!

    Look, a trader!

    upload_2017-12-31_15-28-41.png

    Let's talk to them.

    upload_2017-12-31_15-27-11.png

    { Trader Name: OkYMedical # Both the reference name and the name displayed on mouse-over. NO SPACES.
    SellingText: "Welcome to Ok'Y Medical Care!" # Text displayed in the UI trading dialog box. Be creative.
    SellingGoods: "trwMedical" # Internal, unexplained, seemingly-irrelevant reference. Fun, huh?
    Item1: "Medikit02, 97-145, 3-5, 77-97, 5-10" # Entry in the item list, explained below. Note: Don't skip numbers!
    Item2: "Medikit03, 194-292, 3-5, 156-194, 5-10"
    Item3: "Bandages, 19-29, 0-10, 15-19, 10-20"
    Item4: "AntidoteInjection, 36-54, 0-10, 29-36, 10-20"
    Item5: "AntidotePills, 48-72, 0-10, 38-48, 10-20"
    Item6: "StomachPills, 38-56, 0-10, 30-38, 20-20"
    Item7: "AntibioticOintment, 63-95, 0-10, 51-63, 10-20"
    Item8: "OxygenBottleSmall, 24-36, 50-100, 19-24, 100-500"
    }

    Developer Side Notes and Questions for @Hummel-o-War, @Pantera:

    What do the various SellingGoods groups mean?

    I'd like to see TraderDisplayName which would allow spaces, and would be displayed on mouse-over. This would allow more customization, enabling us to display the name of OkYMedical as Brant McDoctor of Ok'Y Medical. Thank you!


    +---+

    So, let's get to tweaking!


    To add an item for sale, just add a line:
    Item#: "<reference name>, <sell price range>, <available stock range>"

    To add an item for sale and the trader buys as well:
    Item#: "<reference name>, <sell price range>, <available stock range>, <buy price range>, <max purchase amount>"

    And, to add an item the trader only purchases:
    Item#: "<reference name>, 0, 0, <buy price range>, <max purchase amount>"

    Always make sure that your item numbers start at 1 and are consistent. Do not skip numbers! If you have five items on the list, they need to be Item1, Item2, Item3, Item4, Item5. The fastest way to break this is to remove an item line, and forget to reset the numbers.

    Typos, missing commas, missing quotes, missing parenthesis will all crash Empyrion as it tries to load this file.

    Also, changing the TraderNPCConfig.ecf and reloading the game will NOT update the Traders! These are baked into the PoI's data file when the PoI is spawned. To see changes, you'll have to create an entirely new game.
    #developer-side-eye

    +---+


    So, what now? Let's make an eeeeeeeeeeeeevil Trader. I'm going to modify PaxPurgatory for this. However, to prevent me from having to build a custom PoI, I'm just going to use the Medical one for the in-game screenshots.

    { Trader Name: SlavePenMaster
    SellingText: "Whaddya want, scum? Some of my precious Terrans? Well, if you have enough money, maybe I'll consider your offer. And don't even think about trying to take them by force. My guards will exact a price far greater than money."

    SellingGoods: "trwFood"
    Item8: "HumanNPCBlocks, 80000-120000, 1-10"

    }

    No, I don't know why HumanNPCBlocks show up under trwFood in the trader config file. Maybe you shouldn't be asking these questions.

    upload_2017-12-31_16-49-17.png

    "I have some wine? What will that get me?"


    Yes,
    HumanNPCBlocks, if setup to be crafted in a constructor, cost a measly 5 gold coins by default. I'm telling you, popping out clones is cheaper than dealing with these slavers' extortion.

    { Template Name: HumanNPCBlocks
    CraftTime: 20
    Target:
    { Child Inputs
    GoldCoins: 5
    }
    }


    --Brian

    PS: This was some hard won battle knowledge. The trader configuration is FRAGILE.


     
    #19
    Hive, Needleship and Robot Shark like this.
  20. Brimstone

    Brimstone Rear Admiral

    Joined:
    Dec 11, 2017
    Messages:
    632
    Likes Received:
    1,982
    You can. of course, add survival constructors to the tech tree, make them craftable. If you don't want to put a large constructor on that CV for space reasons, you could make the SV constructor mountable on a CV.
     
    #20
    Last edited: Jan 1, 2018
    Hive likes this.

Share This Page