Please Fix the Battery Creation and Recharge Exploits

JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
There are exploits to get around both creating and recharging batteries. I really think they should be fixed.

Information current as of Experimental 54573.


Exploit #1. Create alternate-cost Batteries via the Repair Tool blueprint.

The Repair Tool blueprint creates a fully charged Battery inside the Repair Tool without needing Copper, using mats more easily obtained than Copper:

Silicone rubber + Cave Sulphur + Titanium => Fabricator => Repair Tool (100% charge)

While Cave Sulphur can be tricky to get, its only uses in early game are for Flares and Repair Tools. Not a big demand. So with the other mats each Cave Sulphur can be made into a Repair Tool, which has a fully charged Battery inside that can be extracted and used anywhere. This exploit is made worse together with the recharge one, as this one then only needs to be done to create enough Batteries.


Exploit #2. Recharge Batteries for trivial cost via the Scanner blueprint.

Currently, blueprints with a Battery as a component ignores the charge of the incoming Battery and always make a fully charged Battery in the created item. This means by consuming a single Titanium, a Fabricator can recharge a Battery via the Scanner blueprint:

Battery (0% charge) + Titanium => Fabricator => Scanner (100% charge)

The fully charged Battery can then be extracted and used elsewhere.


To fix these exploits there are two approaches, which can be both be used.


Solution #1. Make the blueprints of items that contain a Battery require a Battery as a component. And transfer the charge state of the component Battery to the charge of the Battery in the created item.

The Repair Tool blueprint would then become:


Silicone rubber + Cave Sulphur + Titanium + Battery (X% charge) => Fabricator => Repair Tool (X% charge)


and similarly all other blueprints would carry over the charge of the component Battery to the created items' internal Batteries.


Solution #2. Make the blueprints of items that use Batteries create the items empty of their Battery.

The Repair Tool blueprint would then become:


Silicone rubber + Cave Sulphur + Titanium => Fabricator => Repair Tool (no battery)


and similarly other blueprints could be changed to drop the Battery component as well as creating the item empty of a Battery.


This second solution might not be such a good idea as some players may not realise their tools come "batteries not included". Perhaps better to do the first solution.
«1

Comments

  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    edited September 2017
    I agree completely. See a previous thread I created:

    https://forums.unknownworlds.com/discussion/152836/i-will-never-run-out-of-batteries-already-now-that-batteries-dont-need-copper-hurray#latest

    In my opinion, the DEVs made the repair tool / scanner recipes easy so new players can get started in the game more quickly. I wish there were some way to code it so that you could only ever create one of each tool. But I know that would create its own sort of headaches when people misplace those tools and thus want to craft another one.

    I had another idea:

    What if the recipes for both tools were much more complex but you could create the first version of each tool using some resource found in the Life Pod? For example:

    Repair Tool Recipe : "Old" Repair Tool found in Life Pod 5 plus other stuff you find easily.

    If they want to make the Scanner Recipe only require a battery plus a piece of titanium, then the easy solution is to just directly transfer the charge from the battery to the new scanner as mentioned by other folks much smarter than me.
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    garath wrote: »
    What if the recipes for both [ Scanner and Repair Tool ] were much more complex but you could create the first version of each tool using some resource found in the Life Pod?
    Or there could be a Scanner and a Repair Tool that could be found in two different locations. Perhaps without a battery or a discharged one.

  • BelgarelBelgarel Join Date: 2017-07-03 Member: 231570Members, Subnautica Developer
    edited October 2017
    EDIT: For context, this was posted before I started working here.

    New players probably wouldn't learn how to game this until after it no longer mattered.

    If wanting to really solve it though, a lazy solution without causing balance issues would be to add an 'unstable power source' battery they spawn with by default which is destroyed on removal.
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    Belgarel wrote: »
    New players probably wouldn't learn how to game this until after it no longer mattered.
    That may be true for some players, but exploits like this get passed around and searched for. UWE removed the infinite-energy Powercell usage on the Cyclops, so I would think they'd fix these too.

    Belgarel wrote: »
    If wanting to really solve it though, a lazy solution without causing balance issues would be to add an 'unstable power source' battery they spawn with by default which is destroyed on removal.
    I think pursuing that solution would be more difficult internally and likely to cause bugs. Going with Solution #1, adding a Battery to the Repair Tool blueprint and having item creation carry over the charge state of component Batteries is more likely to solve this and not create further issues once implemented.

  • scifiwriterguyscifiwriterguy Sector ZZ-9-Plural Z-α Join Date: 2017-02-14 Member: 227901Members
    Really, the simple solution to both problems is just to go "batteries not included." Any tool fabricated doesn't have a battery; you'll have to fab one separately or find one in a supply crate.

    While it's logically simple to just pass the value of the battery being used to make a tool to the value of the battery in the tool, from a coding standpoint, it's probably not possible without a lot of reworking. Function calls have established value passes; software functions can't just access all of the data being used by the application - the programmers decide which variables are needed and pass only those. "Okay, so just add those variables." Usually not as easy as that when the function wasn't designed that way from the start. Adding variables - particularly ones which will have values altered and passed back to the main function - is a pain. If you hadn't counted on having to do that, you'll probably have to create a new variable to handle the value manipulation. "So add the new variable." Again, this creates all kinds of potential knock-on effects...we call them bugs. Your function calls the wrong variable, or you update the wrong variable, or the math references the wrong variable, or this function calls everything correctly but that one is still using the old variable names - speaking from an abundance of personal experience, it's a pain, and that's being excessively polite.

    It is, however, relatively straightforward to adjust which objects a function creates in a game world - and when it comes to whether an object is "loaded" in some form, it's even easier; you set the state flag or the variable state to whichever setting you've established as "it has nothing" and wham, you're done. So if the UWE coders decided that a device without a battery has a charge value of -1, then you set the default charge value not at 100 like it is currently, but to -1. Now the new whatzit doesn't have a battery and the exploit is closed.

    There's a reason programmers like Occam and his razor. ;)
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    Really, the simple solution to both problems is just to go "batteries not included." Any tool fabricated doesn't have a battery; you'll have to fab one separately or find one in a supply crate.

    While it's logically simple to just pass the value of the battery being used to make a tool to the value of the battery in the tool, from a coding standpoint, it's probably not possible without a lot of reworking.
    Oh, I do understand the coding side. But this must be a solved problem in Subnautica.

    When the Battery is removed from a device, the program creates a Battery with the current charge state of the item and puts it into inventory, then changes the item to have no battery. When a Battery is exchanged, the program creates a Battery with the current charge state of the item, then sets the charge state of the item to that of the incoming Battery, then destroys the incoming Battery.

    That code could be used or adapted to work for the Fabricator as well.
  • scifiwriterguyscifiwriterguy Sector ZZ-9-Plural Z-α Join Date: 2017-02-14 Member: 227901Members
    edited October 2017
    Jacke wrote: »
    Really, the simple solution to both problems is just to go "batteries not included." Any tool fabricated doesn't have a battery; you'll have to fab one separately or find one in a supply crate.

    While it's logically simple to just pass the value of the battery being used to make a tool to the value of the battery in the tool, from a coding standpoint, it's probably not possible without a lot of reworking.
    Oh, I do understand the coding side. But this must be a solved problem in Subnautica.

    When the Battery is removed from a device, the program creates a Battery with the current charge state of the item and puts it into inventory, then changes the item to have no battery. When a Battery is exchanged, the program creates a Battery with the current charge state of the item, then sets the charge state of the item to that of the incoming Battery, then destroys the incoming Battery.

    That code could be used or adapted to work for the Fabricator as well.

    Sorry; didn't mean to impugn your coding knowledge. :) I tend to build explanatory posts so that folks who aren't up on the technicals can understand the depth of the issue.

    Absolutely this needs fixing; it's an immersion-breaking exploit. It could be handwaved by saying that the fabricator charges the battery during the process, but that just reeks of weak retconning and actually kinda makes it worse.

    The battery exchange point is valid, but don't forget that's calling a different function; the variable passes for item creation probably don't include battery state because, well, they never have (or at least never have shown any evidence of doing so). Adding that function could be a problem. Even kludging the battery-exchange function into the fabrication function probably wouldn't work, since I doubt the fabrication function receives any variables - the ingredients-present check is probably run before the function is even called and the items are removed from inventory before the fab process is started, so the object has probably already been deleted from the database.

    But I think you're onto something. If a global slop variable were created to store the battery's charge before the objects are removed from the player inventory, the fabrication function called and executed, the new object created, then its charge remaining variable set to the temp value...that should do it, and wouldn't involve modifying the fabrication function at all. Plus, we're only adding one int var, so it's not like there's going to be any performance impacts.
    Pseudocode - a shot in the dark since we don't know their actual structure and vars:
    int batt_chg=0;

    if(inv_diamond >= 1 && inv_titanium>= 1 && inv_crash_powder >= 1 && inv_battery >= 1){
    batt_chg=0;
    batt_chg=inv_battery.charge;
    Fabricate(laser_cutter); //Assuming that the Fabricate function is a void and handles inventory deposit without a passback
    inv_laser_cutter.charge = batt_chg;
    }

    Technically, that slop var could be used for nearly any temporary-hold feature, which means that there could well already be a temp var for that purpose.

    Alternatively, the object_ID could be pushed into a storage variable, the fab process run, and rather than having a new battery object_ID created, dump the stored object_ID into the new container (the tool)...but that would probably mean being able to pass the object_ID to the fabrication function, and it doesn't look like the function can take that.


    Either way, you're right on both counts: it's a loophole that needs fixing and it should be very plausible to get it done. Personally, I'm behind the "no included battery" approach purely for the sake of simplicity, but the value-set approach should work, too.
  • KurasuKurasu Join Date: 2017-06-24 Member: 231322Members
    edited October 2017
    Personally, I feel that the easiest way would be to go "Batteries Not Included", and have your original pod contain a handful of batteries for powering of the important tools.

    Say, three batteries: That would give you enough for a Scanner, Repair Tool, and Seaglide.

    The mats for batteries are easy to find for the most part: copper is the one thing you may have to dig a bit for, whereas acid mushrooms are everywhere... *EVERYHWHERE*.

    There are also tons of batteries in vacuum packs around the world. I have two full battery chargers, *and* about 10 spare batteries, *and* all the tools I've crafted, and only created perhaps one or two batteries in total.
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    I'm finding Copper isn't tight now after a few hours, partly due to Silver being really tight and thus not making a lot of things that need Batteries or Copper Wire. I've made Batteries for the blueprints and 3 spares. One of the spares I drove to discharge to test the recharge exploit (I reloaded after testing, so the Battery is still discharged). I have more than enough Copper and plenty of Acid Mushrooms around my initial base underneath Lifepod 5 to keep my tools in Batteries until I do find more Silver and frags to advance my game.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    I agree. In a previous game a few weeks back, copper seemed quite sparse. But in my game last week, I had 25 spare copper by about hour four and nothing to make with it. Thus, I really wished the beacon recipe used copper wire. In the game I started yesterday, I don’t have quite that much but definitely have enough that it is faster to craft batteries from copper than go collect them araound the Aurora.
  • WarzouzWarzouz Join Date: 2016-11-05 Member: 223674Members
    It may have been said but all tools should be coming without battery. Even more, the Seamoth, Prawn and Cyclop should come without cells.

    Batteries and cells are separate parts, they should be independent.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    Just saw this on the Trello:

    https://trello.com/c/7JJZqCVE/6655-address-battery-exploit-in-welder

    I assume this is in response to being able to just spam build welder (Repair Tool) for free batteries.
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    garath wrote: »
    Just saw this on the Trello:

    https://trello.com/c/7JJZqCVE/6655-address-battery-exploit-in-welder

    I assume this is in response to being able to just spam build welder (Repair Tool) for free batteries.

    Good. The recharge exploit by crafting a Scanner with a dead battery still needs to be fixed too.
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @Kurasu
    Personally, I feel that the easiest way would be to go "Batteries Not Included", and have your original pod contain a handful of batteries for powering of the important tools.
    I like this suggestion it is simple, it avoids exploits and it doesn't alienate new players.
    However I would suggest only two batteries. To me the seaglide already marks the transition from the early game to a more exploratory phase, one that will require more batteries to fulfill their exploratory needs.
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @scifiwriterguy
    While it's logically simple to just pass the value of the battery being used to make a tool to the value of the battery in the tool, from a coding standpoint, it's probably not possible without a lot of reworking.
    I fail to see why it would be such a pain. They shouldn't need to modify any of the existing code.
    Couldn't they just save the charge of the ingredient battery to a new variable. After the item is fabricated (with a fully charged battery) add a single function call that would change the new battery charge to the one previously stored.

    Please don't think I'm being condescendent. I consider myself to code at a very basic level, so I might really be missing the mark.
  • kingkumakingkuma cancels Work: distracted by Dwarf Fortress Join Date: 2015-09-25 Member: 208137Members
    Maalteromm wrote: »
    @scifiwriterguy
    While it's logically simple to just pass the value of the battery being used to make a tool to the value of the battery in the tool, from a coding standpoint, it's probably not possible without a lot of reworking.
    I fail to see why it would be such a pain. They shouldn't need to modify any of the existing code.
    Couldn't they just save the charge of the ingredient battery to a new variable. After the item is fabricated (with a fully charged battery) add a single function call that would change the new battery charge to the one previously stored.

    Please don't think I'm being condescendent. I consider myself to code at a very basic level, so I might really be missing the mark.

    In theory, yes. But there would need to be a new variable for each battery, and then you'd have to mess with the battery charger code and the loot crates...
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @kingkuma
    I still fail to see it. The variable I suggested doesn't need to exist outside of the fabrication loop.
    You create the variable after initiating the fabrication process (only if it require batteries), after the process is complete (but before the player access the item) you change the battery charge level to the stored variable and then delete the variable.

    Nothing else would change in the game.
  • kingkumakingkuma cancels Work: distracted by Dwarf Fortress Join Date: 2015-09-25 Member: 208137Members
    Maalteromm wrote: »
    @kingkuma
    I still fail to see it. The variable I suggested doesn't need to exist outside of the fabrication loop.
    You create the variable after initiating the fabrication process (only if it require batteries), after the process is complete (but before the player access the item) you change the battery charge level to the stored variable and then delete the variable.
    one
    Nothing else would change in the game.
    @Maalteromm
    You would then have to create two kinds of "battery" objects, one being the crafted battery, and one being the one found in boxes. When each battery is made, it must be of the crafted variety. Having two kinds of batteries would make modding EVERY RECIPE using a battery, because there would need to be two recipes, one for each kind of battery. You'd also have to modify the charger. Also, deleting a variable inside said fabricator loop still uses memory, so it would possibly create lag. The battery power level itself is a variable, and, in at least the languages I've coded in, deleting a variable can have far - reaching effects in other joined programs.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    kingkuma wrote: »
    Maalteromm wrote: »
    @kingkuma
    I still fail to see it. The variable I suggested doesn't need to exist outside of the fabrication loop.
    You create the variable after initiating the fabrication process (only if it require batteries), after the process is complete (but before the player access the item) you change the battery charge level to the stored variable and then delete the variable.
    one
    Nothing else would change in the game.
    @Maalteromm
    You would then have to create two kinds of "battery" objects, one being the crafted battery, and one being the one found in boxes. When each battery is made, it must be of the crafted variety. Having two kinds of batteries would make modding EVERY RECIPE using a battery, because there would need to be two recipes, one for each kind of battery. You'd also have to modify the charger. Also, deleting a variable inside said fabricator loop still uses memory, so it would possibly create lag. The battery power level itself is a variable, and, in at least the languages I've coded in, deleting a variable can have far - reaching effects in other joined programs.

    Can you please explain why you need two kinds of battery objects? All batteries in the game already have a charge already.

    As @Maalteromm has said, we only need for the Fabricator to transfer the charge from the battery that is an ingredient to the battery contained in the fabricated object. The battery ingredient already has a charge, and the battery in the constructed item also has a charge. This is only a very simple problem of making the fabricator transfer the charge from the input battery to the battery contained in the "output" constructed item.

    As @Maalteromm mentioned, any variable has a very short life as it exists only for the milliseconds required to construct an item and is used to insure the charge is transferred from the input battery to the battery in the output object.

    I cannot figure out why you would think there need to be two kinds of batteries; all batteries have a charge. We are simply talking about making the fabricator "preserve" the charge of the input battery and transfer it to the battery in the constructed object. So, instead of getting a scanner with a 100% battery when constructed with a 15% battery, you instead get a scanner with a 15% battery.

    This should be a trivial piece of code to write, I think. And, it should be trivial to test.

  • kingkumakingkuma cancels Work: distracted by Dwarf Fortress Join Date: 2015-09-25 Member: 208137Members
    Natural batteries and crafted batteries would need different classes, as the crafted ones have to have that additional code @Maalteromm mentioned. I guess you could make all batteries the crafted kind, that might work.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    kingkuma wrote: »
    Natural batteries and crafted batteries would need different classes, as the crafted ones have to have that additional code @Maalteromm mentioned. I guess you could make all batteries the crafted kind, that might work.

    Here is what I'm reading in the previous posts:

    1. @scifiwriterguy wants to avoid changing the fabricator code. I assume his approach requires new battery objects.
    2. @Maalteromm *does* want to change the fabricator code. Zero changes to batteries.

    Assuming I'm understanding what @Maalteromm is suggesting, there are NEVER any changes to the batteries in his approach. Rather, there is only a change to the fabricator itself. The fabricator reads the charge of the batteries and transfers that charge to the output battery. All batteries in the game already have a charge. It's just that the fabricator doesn't consider the charge of the battery used to construct an item. There are no changes to batteries. All batteries are exactly the same. The changed code is only in the fabricator. Again, I think @scifiwriterguy wants to avoid changing the fabricator while @Maalteromm *does* want to change the fabricator. I agree wholeheartedly with @Maalteromm's approach.
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @garath
    Actually, I share the opinion of @scifiwriterguy and others, as stated above and repeated here:
    I like this suggestion it is simple, it avoids exploits and it doesn't alienate new players.
    However I would suggest only two batteries. To me the seaglide already marks the transition from the early game to a more exploratory phase, one that will require more batteries to fulfill their exploratory needs.
    I was following @Kurasu last statement.

    However I got intrigued by the supposed difficulty to change the batteries charge level, since it looks super simple to me.

    @kingkuma
    You would then have to create two kinds of "battery" objects, one being the crafted battery, and one being the one found in boxes. When each battery is made, it must be of the crafted variety. Having two kinds of batteries would make modding EVERY RECIPE using a battery, because there would need to be two recipes, one for each kind of battery. You'd also have to modify the charger. Also, deleting a variable inside said fabricator loop still uses memory, so it would possibly create lag. The battery power level itself is a variable, and, in at least the languages I've coded in, deleting a variable can have far - reaching effects in other joined programs.

    I cannot see the difference between batteries crafted and batteries found on the environment. And the memory used/possible lag should be negligible since it's probably a small, single precision, float number that will exist for no more than a few seconds.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    edited October 2017
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @garath
    It sure is funny, but it is no loling matter for the devs.
    They will certainly fix it before launch, as indicated by the SN development trello you linked yourself.

    Whatever path they choose, will require changing code. Both solutions seems simple enough.
    To me it will probably be a matter of game design instead of programming. Is it more immersive to spawn the item 'use ready' or make the player 'reload' the item before its first use?

    Another solution that we didn't even explore (and that should also be simple) is to force the player to use fully charged batteries while crafting.

    Personally, I find this discussions super entertaining.
  • garathgarath Texas Join Date: 2017-02-08 Member: 227730Members
    I started a game on Saturday and had so much extra cave sulfur that I made five *EXTRA* repair tools just for the free batteries. Now, I'm ten hours into the game, and I have maybe 50-60 copper. So, I can make a TON of batteries. Except... I don't want the hassle of going to grab the mushrooms. I haven't made a battery charger yet because I have so many spare batteries already. But just now, I misplaced my stockpile of batteries. I'm trying to decide which is easier:

    1. Use six Titanium to make six scanners to recharge my batteries, or
    2. Build a battery charger, load 4 batteries, wait for them to charge, and load the remaining two batteries.

    I have a ton of Titanium. So, I'm probably just going to burn the six Titanium to quickly recharge my six batteries.

  • cdaragorncdaragorn Join Date: 2016-02-07 Member: 212685Members
    Maalteromm wrote: »
    I cannot see the difference between batteries crafted and batteries found on the environment. And the memory used/possible lag should be negligible since it's probably a small, single precision, float number that will exist for no more than a few seconds.

    I REALLY hope they didn't use floats for these things. Horribly inaccurate with progressive problems as you do math on them. A simple int will more than suffice to represent what a battery charge needs to be.

    While I agree the implementation should be fairly simple, I'd actually prefer they just make everything craft without batteries. I'd find it more enjoyable to have to craft the power I need to run them from the beginning.
  • MaalterommMaalteromm Brasil Join Date: 2017-09-22 Member: 233183Members
    @cdaragorn
    I REALLY hope they didn't use floats for these things. Horribly inaccurate with progressive problems as you do math on them. A simple int will more than suffice to represent what a battery charge needs to be.
    For something so simple the error would be negligible. But I agree with you, an int should suffice.
    It's a vice really,
    I can't work with ints, so to me every number in a computer is a float.
  • scifiwriterguyscifiwriterguy Sector ZZ-9-Plural Z-α Join Date: 2017-02-14 Member: 227901Members
    garath wrote: »
    kingkuma wrote: »
    Natural batteries and crafted batteries would need different classes, as the crafted ones have to have that additional code @Maalteromm mentioned. I guess you could make all batteries the crafted kind, that might work.

    Here is what I'm reading in the previous posts:

    1. @scifiwriterguy wants to avoid changing the fabricator code. I assume his approach requires new battery objects.
    2. @Maalteromm *does* want to change the fabricator code. Zero changes to batteries.

    Assuming I'm understanding what @Maalteromm is suggesting, there are NEVER any changes to the batteries in his approach. Rather, there is only a change to the fabricator itself. The fabricator reads the charge of the batteries and transfers that charge to the output battery. All batteries in the game already have a charge. It's just that the fabricator doesn't consider the charge of the battery used to construct an item. There are no changes to batteries. All batteries are exactly the same. The changed code is only in the fabricator. Again, I think @scifiwriterguy wants to avoid changing the fabricator while @Maalteromm *does* want to change the fabricator. I agree wholeheartedly with @Maalteromm's approach.

    Actually, I'm not advocating any new objects at all. Sorry if it came off that way.

    My suggestion was to remove batteries completely from the fabrication recipes. Players then fabricate a battery separately and install it in whatever device. The same base object that batteries ever were, only now no longer part of the finished fabrication routine. We've no need to create a new object class. (As a side bonus, it also introduces players to the battery replacement mechanic in the game. Build your new tool, stick a battery in it.)

    Changing code is a problem. Always. Whenever you start messing with code that works, you run the very serious risk of ending up with bugs you never had and, really, never needed to have. As a result, you only mess with your code when it doesn't do the job it needs to do or it's become bloated. The fabricator code works. Adding new variables to push around values that, in the end, don't need to be pushed around is just inviting headaches. It's a lot easier, simpler, and safer to update an object or case table to remove a result than it is to muck around with the function itself to play musical chairs with a variable.

    When you're at alpha build stage, sure, code editing is part and parcel with creating the product. But when you're in a nearly finished state, going back and changing function calls that are fundamental to the operating of the software as a whole is irresponsibly dangerous except in the most severe circumstances. (And this is experience talking - having to build a machine language compiler is a powerful learning experience on the comparative value of code editing.)

    Simpler solutions are nearly always better. Faster, cheaper, and safer.
  • JackeJacke Calgary Join Date: 2017-03-20 Member: 229061Members
    Changing code is a problem. Always. Whenever you start messing with code that works, you run the very serious risk of ending up with bugs you never had and, really, never needed to have. As a result, you only mess with your code when it doesn't do the job it needs to do or it's become bloated. The fabricator code works. Adding new variables to push around values that, in the end, don't need to be pushed around is just inviting headaches. It's a lot easier, simpler, and safer to update an object or case table to remove a result than it is to muck around with the function itself to play musical chairs with a variable.

    When you're at alpha build stage, sure, code editing is part and parcel with creating the product. But when you're in a nearly finished state, going back and changing function calls that are fundamental to the operating of the software as a whole is irresponsibly dangerous except in the most severe circumstances. (And this is experience talking - having to build a machine language compiler is a powerful learning experience on the comparative value of code editing.)

    Simpler solutions are nearly always better. Faster, cheaper, and safer.
    And not necessarily as simple as they appear at first look. You've got to look at the larger use cases. UWE is selling a game that people play. The solution has to consider the impact on the game and how people play it.

    If the game properly introduces the players to the concept that they are crafting items "batteries not included" and playing with "batteries not included" doesn't have sufficient impact on the players to handle all new items as "batteries not included", then the two solutions are close to equivalent in their impact on the use cases.

    But pursuing the "batteries not included" solution means more has to be done besides just changing the blueprints to exclude batteries and to have them produce items empty of batteries. The game will have to introduce new players to this important concept. The worst cases won't be the Seamoth, Cyclops, or PRAWN, as they won't move without power. The problem is if players keep making tools and swim out without realising there's no batteries in the tools. If they have enough spares in their inventory and have sufficient knowledge to know how to fix things, great. Assuming they're not dead because of this.

    And adding such an important gameplay tutorial section to a game this close to release is an issue in itself. And I think changing blueprints and the Fabricator and Mobile Vehicle Bay to make items with no batteries in them aren't trivial either. So both solutions have their own complexities.
  • 0x6A72320x6A7232 US Join Date: 2016-10-06 Member: 222906Members
    edited October 2017
    Mmm, on first fab of buildable with power type 'battery', pop up message "Batteries not included. Please be sure to fabricate batteries as needed." Or somesuch.
Sign In or Register to comment.