Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Autodoc installation program which almost guarantees flawless installation of basic-tier bionics #46808

Merged
merged 16 commits into from
Feb 6, 2021
Merged

Autodoc installation program which almost guarantees flawless installation of basic-tier bionics #46808

merged 16 commits into from
Feb 6, 2021

Conversation

Night-Pryanik
Copy link
Contributor

Summary

SUMMARY: Features "Autodoc installation program which almost guarantees flawless installation of basic-tier bionics."

Purpose of change

Following #46623, the goal is to make installation of bionics easier in early game where it really matters.

Describe the solution

  1. Added a basic autodoc installation data which has level of 3 bionic installation quality. This means that this item has detailed instructions on how to install the most common and easy-to-install bionics, i.e. with difficulty of 3 or less. While trying to install bionics, autodoc will automatically scan for this item in usual 6-tile crafting radius. If this item is found, autodoc automatically uses it and applies 10 level of skills required for bionic installation. This usually results in ~2% failure chance. This item is one-time use, so it will be consumed after bionic installation.
  2. Made this item spawn in electronic stores, hospitals, doctors' offices and rarely on zombie scientists. I had to make some adjustments in ordinary hospital mapgen to make it spawn in more "logical" place.

Describe alternatives you've considered

Lots, actually.

  1. Make installation data for every type of bionics rather than "generic" version capped by difficulty.
  2. Make this item have some low number of charges (3, for example) instead of 1.
  3. Make this item don't consume charges at all.
  4. Make query on whether player wants to use this item instead of auto-use.

Current version makes this item very helpful and rather easy to find and use in early game without being overpowered, balanced by it being one-time use.

Testing

Debug-spawned hospitals, doctors' offices, electronic stores to check if this item is spawned properly.

Tried to install Power Storage CBM (difficulty 1) without this item. The failure chance is 59% with my 8 intelligence and zero skills character. Then debug-spawned this item and get 2% failure chance. Debug-spawned Integrated Toolset CBM (difficulty 6) to check it's not affected by this item. Checked if item is properly removed after installing Power Storage and not removed after installing Integrated Toolset.

Additional context

Without installation data
изображение

With installation data
изображение

While the basic prefix of this item's name implies there could be "non-basic" versions, I'm not sure if we need such advanced things. And if we do, I think that we should cap maximum level of bionic it could flawlessly install with difficulty of 6, as Teleportation Unit CBM's (with difficulty of 7) description states that it is highly experimental, so any pre-written instructions should exist yet.

@Night-Pryanik Night-Pryanik added <Enhancement / Feature> New features, or enhancements on existing Items / Item Actions / Item Qualities Items and how they work and interact Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. Character / World Generation Issues and enhancements concerning stages of creating a character or a world labels Jan 16, 2021
@Ramza13
Copy link
Contributor

Ramza13 commented Jan 16, 2021

So this seems kinda similar to the part of #46376 about making first installs easier and subsequent installs harder. This is much more fleshed out but seems like it will be changed/removed when the exodii are in and CBM stuff is no longer findable in our reality in the next version.

@kevingranade
Copy link
Member

See #22877 (comment)

I've been saying for quite a while now that this kind of thing should be locked to specific CBMs, not a group. This also resolves the requirement to make the software disposable, since once you have a CBM installed, it's not generally necessary to install more of the same kind (in fact it's impossible except with batteries if I remember correctly).

Also @Ramza13 is correct, the plan going forward with vanilla DDA is to eliminate autodocs entirely in favor of installation by Exodii or perhaps some other faction. You might want to work with the Aftershock maintainers, who AFAIK are keeping autodocs around.

@John-Candlebury
Copy link
Member

John-Candlebury commented Jan 17, 2021

Even if they cant make it into standard DDA, I do like the general idea of these for Aftershock!

I wonder if it would be possible to make the given bonus more customizable so for example you can have bionics with very high difficulty say 15 that could only be installed with a software piece of matching difficulty (you could presumably just make the presence of data give an insanely high boost to the installation skills to achieve this).

@Night-Pryanik
Copy link
Contributor Author

I've been saying for quite a while now that this kind of thing should be locked to specific CBMs, not a group.

I could rework the whole stuff to work with specific CBMs, of course. I think it's just a ton of work for no profit. Why can't several instructions for several CBMs be packaged into one medium?

the plan going forward with vanilla DDA is to eliminate autodocs entirely in favor of installation by Exodii or perhaps some other faction.

Eliminate autodocs entirely? Then why I'm doing all this work to make autodocs more useful: #42527, #41729, #40474, and #31001?

@actual-nh
Copy link
Contributor

the plan going forward with vanilla DDA is to eliminate autodocs entirely in favor of installation by Exodii or perhaps some other faction.

Eliminate autodocs entirely? Then why I'm doing all this work to make autodocs more useful: #42527, #41729, #40474, and #31001?

I suspect what was meant was "eliminate autodocs doing CBM installation"; the work you've done helps give them a purpose besides CBM installation.

@actual-nh
Copy link
Contributor

I've been saying for quite a while now that this kind of thing should be locked to specific CBMs, not a group.

I could rework the whole stuff to work with specific CBMs, of course. I think it's just a ton of work for no profit. Why can't several instructions for several CBMs be packaged into one medium?

Why would the instructions for all of them get used up by one? (Why would instructions for installation get used up, anyway?) The most reasonable case, IMO, is that they aren't instructions - they're licensing keys. (In which case hacking may substitute, particularly if you can get into the guts of the autodoc...)

@Night-Pryanik
Copy link
Contributor Author

Night-Pryanik commented Jan 17, 2021

Why would the instructions for all of them get used up by one? (Why would instructions for installation get used up, anyway?)

Corporate making-money-on-everything politics. You want to install the next bionic, you buy another data cartridge.
Having several instructions on one cartridge is cheaper than producing separate cartridge for every bionic, especially if said cartridge is converted into a fancy but very expensive paperweight after only one use.

The most reasonable case, IMO, is that they aren't instructions - they're licensing keys.

In fact, they are instructions with embedded licensing keys.

@actual-nh
Copy link
Contributor

From corporate behavior around DMCA, unless they're also charging on updates, I suspect that they would just have the instructions already present but only unlocked with a key. They sold you a "functional" autodoc - it's just that the only programs you can access without keys are very, very basic...

@Nerezza
Copy link
Contributor

Nerezza commented Jan 18, 2021

Why would the instructions for all of them get used up by one? (Why would instructions for installation get used up, anyway?)

Corporate making-money-on-everything politics. You want to install the next bionic, you buy another data cartridge.
Having several instructions on one cartridge is cheaper than producing separate cartridge for every bionic, especially if said cartridge is converted into a fancy but very expensive papier mache after only one use.

The most reasonable case, IMO, is that they aren't instructions - they're licensing keys.

In fact, they are instructions with embedded licensing keys.

The autodoc is a machine that needs to be configured for surgeries, it doesn't have the configurations included in its software. To make more money off the autodoc, the corporations sell proprietary single-use encrypted configuration cartridges advertised as the "safest" way to use their auto-docs. Lawsuits were pending but those are on indefinite hold thanks to the cataclysm.

Manual configuration is possible, but probably in a very open-ended scripting system sort of manner requiring knowledge not only in medicine but also computers and electronic devices. Perhaps eventually the company intended to cerifty/license surgeons that complete training courses to configure their autodocs. Anything to suck as much money as possible out of the American healthcare industry ;P

@Night-Pryanik
Copy link
Contributor Author

Night-Pryanik commented Jan 18, 2021

Ok, I reworked the thing.
Now there are lots of AIDs (autodoc installation datum) for lots of low-tier (1-3 levels of difficulty) bionics. I deliberately excluded bionic fingerhack and bionic lockpics for having an AID for them as I think they are a little "shady" to be sold on open market.

From lore point of view this might seem a little illogical as now the corporation have to produce at least 23 types of different one-time cartridges with separate AIDs in each, which is of course much more expensive versus previous "one cartridge for lots of bionics" variant.
From technical point of view this is an enhancement as now we could decide which bionics should have an AID for them, and have a greater flexibility on this matter, and could easily create new AIDs.
From gameplay point of view... Well, seems like nothing changed.

@Xaleth
Copy link
Contributor

Xaleth commented Jan 18, 2021

It doesn't make sense to me that you would find software to endgame government top-secret materials in an electronics store.

@Night-Pryanik
Copy link
Contributor Author

It doesn't make sense to me that you would find software to endgame government top-secret materials in an electronics store.

You can't. All experimental, secret, or particularly hard to install bionics shouldn't have AIDs for them. This PR adds AIDs only for low-tier (1-3 levels of difficulty) bionics, like cranial flashlight or power storage CBMs.

@Night-Pryanik Night-Pryanik added Mechanics: Character / Player Character / Player mechanics and removed Character / World Generation Issues and enhancements concerning stages of creating a character or a world labels Jan 21, 2021
@kevingranade kevingranade merged commit e987eba into CleverRaven:master Feb 6, 2021
Comment on lines +1848 to +1849
const std::string AID_name = progs->typeId().c_str();
has_install_program = AID_name.substr( 4 ) == bionic_name;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry to comment after this has been merged, but I don't think it's good to make this functionality based on the ids of the items.
I don't think string hacking with the ids is good practice, and it places restrictions on how you can use these.
If you didn't implement it this way, and instead had some sort of field, this would be much more flexible, and would also very easily allow extension of this, such as the original implementation of it.

e.g. There's rare items that ease a large class of CBM installs, and less rare variants allowing only one or a few.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just went the easiest IMO way to implement it. The stuff can be refactored later if you think my approach is so bad.

@Night-Pryanik Night-Pryanik deleted the autodoc-installation-programs branch February 6, 2021 03:44
feinorgh pushed a commit to feinorgh/Cataclysm-DDA that referenced this pull request Feb 8, 2021
…ation of basic-tier bionics (CleverRaven#46808)

* Added autodoc installation data item with 'bionic installation' quality of 3
* Added installation data spawn to 'elecsto_stor' item group
* Added installation item spawn to electronic store, two types of hospital, private doctor's office, and zombie scientist drop list
* Increased available lines in the header of bionic installation menu from 2 to 3
* Made second line of hint fold
* Mark affected CBM's failure chance with an asterisk
* Apply 10 level of skills for calculation of success when using installation data
* Show hint about found installation data only if autodoc actually found it
* Created lots of AIDs for lots of 1-3 levels of difficulty
* Created item group with AIDs
* Replaced old autodoc software spawn with AIDs spawn
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
<Enhancement / Feature> New features, or enhancements on existing Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. Items / Item Actions / Item Qualities Items and how they work and interact Mechanics: Character / Player Character / Player mechanics
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants