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

[WIP] Rebalancing of the control laptop, give robots a chance #30892

Conversation

matthemsteger
Copy link
Contributor

@matthemsteger matthemsteger commented May 27, 2019

Summary

SUMMARY: Balance "Robots have more defenses against the control laptop"

Purpose of change

The control laptop tends to trivialize labs and other high end content. Combined with the power of books, once you construct one and get a computer skill of ~6, you can reliably hack most anything in the game, and especially all content in labs. In fact, there is virtual no chance of failing at computer level 6. The only roll in the calculation is based on int, and its effect is extremely small.

That being said, the north star here is one of reality. In a world of autonomous robots deployed for security purposes, one would expect a certain degree of defense against hacking via the open airwaves. Especially against software that pops up on USB drives in street sweepers.

Describe the solution

Generally speaking the control laptop is a device that will:

  1. Scan an area for hostile receiving robots
  2. Allow the player to initiate a hack (by presumably writing code and thinking on their feet) that is long running to overcome a robots systems and make it see the player as friendly, and allow control

Added the following monster flags HACK_IMMUNE and HACK_DEFENSE.

  • HACK_IMMUNE - exactly what it says, basically used for the broken cyborg
  • HACK_DEFENSE - allows for certain robots to have hacking counter-measures

Added an effect not_receiving for AI robots. This effect essentially is a robot turning off its ability to receive input via wireless communication.

(WIP) The roll to hack has been made slightly harder and more interesting by introducing more chance to represent the multitude of patch levels, firmwares, versions and other complexities of finding and exploiting vulnerabilities on the fly.

Prior to the change, against a security bot with a difficulty of 10, in the lab finale rooms, a computer skill of >4 was no lose.

TBD (WIP): Now it is changed so that (I am currently play testing some different calculations). There is some code there to try out some cumulative rolls. I think I just want to make it a better curve, rather than a ceiling.

In addition, if you critically fail hacking actions during the long action of hacking, then a robot that has HACK_DEFENSE will exhibit the following behavior.

  1. They will say loudly Remote intrusion detected! Notifying network. Shutting down transmitter.
  2. They will contact robots within 10 distance of themselves (which are also HACK_DEFENSE and tell those robots to also shut down their transmitters.
  3. They will apply the not_receiving effect permanently. Presumably, pre-cataclysm this would mean a search of the premises and a tech enabling the robot after some sort of mitigation procedure.

I also added a quality of life improvement for the UI to show how many turns it will take to do control laptop actions.

Additional WIP items

  • Separate scan for robots action and actual long hack action
  • Make control laptop take an appropriate amount of charges for running a computer

Describe alternatives you've considered

  • I could have left it alone and increased some of the robots difficulty, but I think it would be hard to balance and ignores some fun aspects of encountering robots reacting
  • Only allow it to control consumer level robots that presumably aren't hardened to this kind of thing
  • Fulfilling the todo comment in the code around getting the robots attention. I thought about the most basic and foolproof way of stopping someone from hacking me .. turn off the vehicle they are using to do it (e.g. shut down my internet connection).

Additional context

It actually would be interesting if a robot also moved towards the player after some chance at triangulating and/or turned on some light towards triangulation, but I hope this is a good step in the right direction.

@Mecares
Copy link
Contributor

Mecares commented May 27, 2019

Personally I think at least average intelligence should be required to have any chance of success. We all agree that int could need a buff and is not worth enough compared to strength, any hacking should be much more rely on int than it does now.

/** @EFFECT_INT increases chance of successful robot reprogramming, vs difficulty */
/** @EFFECT_COMPUTER increases chance of successful robot reprogramming, vs difficulty */
const float success = p->get_skill_level( skill_id( "computer" ) ) - 1.5 * ( z->type->difficulty ) /
( ( rng( 2, p->int_cur ) / 2 ) + ( p->get_skill_level( skill_id( "computer" ) ) / 2 ) );
Copy link
Member

@anothersimulacrum anothersimulacrum May 27, 2019

Choose a reason for hiding this comment

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

While I'm not against this change, I think the real issue here is this formula.
This formula puts too much emphasis on the difficulty value. Here's a table of the min and max for hacking of a security bot and tank drone by intelligence and computer skill.
Values are (min,max) - even though they aren't that way for low intelligence.
Calculated from

const float success_min = p->get_skill_level( skill_id( "computer" ) ) - 1.5 *
                              ( z->type->difficulty ) /
                              ( ( 2 / 2 ) + ( p->get_skill_level( skill_id( "computer" ) ) / 2 ) );
const float success_max = p->get_skill_level( skill_id( "computer" ) ) - 1.5 *
                              ( z->type->difficulty ) /
                              ( ( p->int_cur / 2 ) + ( p->get_skill_level( skill_id( "computer" ) ) / 2 ) );

Security Bot - difficulty 14

0 1 5 10
1 -20,-inf -2,-5.5 6.5,5.8
2 -20,-20 -2,-2 6.5,6.5
3 -20,-20 -2,-2 6.5,6.5
4 -20,-9.5 -2,-0.25 6.5,7
5 -20,-9.5 -2,-0.25 6.5,7
6 -20,-6 -2,0.8 6.5,7.375
7 -20,-6 -2,0.8 6.5,7.375
8 -20,-4.25 -2,1.5 6.5,7.667
9 -20,-4.25 -2,1.5 6.5,7.667
10 -20,-3.2 -2,2 6.5,7.9
12 -20,-2.5 -2,2.375 6.5,8.0909
14 -20,-2 -2,-2.667 6.5,8.25
16 -20,-1.625 -2,2.9 6.5,8.384615

Tank Drone - difficulty 126

Int Comp 1 Comp 5 Comp 10
1 -188,-inf -58,-89.5 -21.5,-27.8
5 -188,-93.5 -58,-42.25 -21.5,-17
10 -188,-36.8 -58,-22 -21.5,-8.9
20 -188,-17.9 -58,-10.75 -21.5,-2.6
100 -188,-2.78 -58,1.365385 -21.5,6.563636

To me, it seems as though this formula cares too much about difficulty. It's probably like the electrohack formula #29898 - old and not making a huge amount of sense.
If the goal of this PR is to address the way that the control laptop trivializes things, I think the root of the problem is here.

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 agree about the formula, it is likely the root of the problems.

I see now that I had not dug into difficulty so my odds were off a bit (I assumed it was just from the json, but its a calculation itself).

@paulenka-aleh
Copy link

paulenka-aleh commented May 27, 2019

I don't really think "not_receiving" permanently it's a good idea. How would owner legitemately bring a robot with a rifle or flamethrower under control? Would you dare approach them after a hacking attempt and risk your life to manually reboot them? Furthermore a hacker could exploit it to render all robots on a facility out of control so that robots cannot be re-programmed, shut down, moved or controlled in any other way. So I would rather:
a) Make this effect not long-lasting, 5-15 minutes. As much as should be enough to pinpoint location of the attacker and take action; On later hacking failures it can block for more time, e.g. 1-3 hours, as much as needed to deal with any major emergency after which facility still has a chance to remain under control;
b) Assume robots stopped receiving over conventional channel but started to receive on another frequency and only limited number of commands and whatever else they could apply to make hacking much harder but remain under control. The goal, again, is to make hacking hard enough so that humans can pinpoint hacker's location and take action.
a) and b) can be combined, used independenly or only one can be implemented.
Finally if ideas above doesn't sound too convincing there should be one more failsafe way rather than control laptop to stop robots with receiver shut down.

P.S. I guess it should be "Notifying network. Shutting down receiver."

@SirPendrak
Copy link
Contributor

Here is a little idea you might consider as well:
What if it was not possible to compleetly, permamently hack a bot via remote control? Using control laptop you can only make it friendly/nonaggresive depending on your skill for like 5-30 mins, and during this time you need to find said robot, and reprogram it manually, standing next to it. This way, even your comp 8, 12 inteligence advanced survivor wont be able to hack national guard camp compleetly risk-free. It still would be very powerfull tool aganist robots, and defeating single robot in room or corridor will be easy, but to defeat room full of 5-10 dangerous robots, you either need some plan, or very high skills to make temporary hacks longer and give you enough time to manually shut down or reprogram all the robots at once. And maybe attacking temporarily hacked bots should aggro them before they are fully domesticated.

@matthemsteger
Copy link
Contributor Author

RE: making it permanent. I understand what you are saying, but we already have permanent consoles shutting down from bad hack attempts. In addition, we already have the notion of making a robot friendly, walking up to it, and deactivating it. Similar idea for turning off its transmitter, walking up to it, and turning it back on (though I don't plan on implementing that).

There are multiple ways to deal with these things (guns, EMP, etc). What I wanted to avoid was just allowing someone to wait to get another chance .. since many times you are "attacking" a robot behind a door it cannot open. If you are saying there should be an additional non-violent way to deal, thats not the vibe I have been getting from cataclysm, but I might be wrong.

RE: changing mechanic to put the robot into "accept reprogramming mode" and having the player have to walk up to it within a certain time period. That is an interesting idea. I wonder if it is too different from what we have today.

I was hoping this change would not change much the flavor of the control laptop .. just

  1. Make the formula used to calculate the chance of success harder and a bit more random
  2. Give robots some realistic defense against hacking once they know they are being hacked (i.e. you fail your roll)
  3. Be transparent about how much time it takes to hack

@paulenka-aleh
Copy link

paulenka-aleh commented May 27, 2019

Don't compare with terminals. First of all they're hooked up to a network so there might be a remote way to turn them on or even reprogram. Secondly terminals don't move around carrying guns, flametrowers, hadcuffs, grenades and tazers so walking to them to bring them back online after a bit of work with proper tools for an equiped technician is not a big worry. Lastly they might be shutting down not because of the anti-hacking measures but just hecause you crashed OS causing a shutdown (assuming they're normally brought online only remotely).

@matthemsteger
Copy link
Contributor Author

matthemsteger commented May 27, 2019

Ehhh, I am not particularly convinced. The fact that you have an autonomous robot that is able to search, path and target people with dangerous weapons means that the creators of such things would be very careful about how you could "turn them" against them with a wireless connection. Its already rather charitable that we can hack these things remotely AND permanently IMO!

But let me finish a working PR and test it and see what happens.

@jeremyshannon
Copy link
Contributor

This is excellent, and has been a long time coming IMO. The control laptop just makes things too easy. With the exception of the Chicken Walker's ability to just suddenly revert to hostile without warning (which is no fun, if I'm being honest) the laptop as it was turns every robotic obstacle into a cakewalk.

@paulenka-aleh
Copy link

creators of such things would be very careful about how you could "turn them" against them with a wireless connection

So I you're creator and you've got such thing turned against you what would be your way to get control back to you? If I were the creator I would leave a workaround for myself to access them wirelessly to shut them down. Or to make them reboot every X minutes (10-30) to restore IFF from read-only memory that can't be overridden wirelessly. Giving a thing with a gun an ability to turn off wireless controls completely is a terrible choice. Not game-balance-wise, just realism-wise.

@jeremyshannon
Copy link
Contributor

I would assume they're still open to some basic commands from the facility, but they've blocked you specifically. There should absolutely be a shutdown or reboot command that it will always accept, but it might have to be sent from the central computer.

@ZhilkinSerg ZhilkinSerg added [C++] Changes (can be) made in C++. Previously named `Code` [JSON] Changes (can be) made in JSON Game: Balance Balancing of (existing) in-game features. labels May 27, 2019
@tenmillimaster
Copy link
Member

tenmillimaster commented May 28, 2019

Most non-opportunistic attacks on software systems only harass or otherwise hinder the system. E.g. throwing enough chaff, overloading a carrier signal, flooding a system with packets, forcing the system to some non-primary routine.

Actually subverting and compromising or obtaining access usually is a lengthy, targeted endeavor, in which you either use known vulnerabilities and hope the system's software isn't up to date, or identifying unknown vulnerabilities and exploiting them.

I suggest that control laptops, generally, need to have more hardware components to create in the first place (possibly even components from a downed robot?) to communicate with the system in question. 2.4 and 5 GHz is probably not what these things are communicating on due to the congestion in these bands.

Secondly, the laptop can, without prior work, be used to harass (temp. shut down, shorten the range or expend ammo in a non-useful way, induce a malfunction that needs to be cleared, etc.)a robot.

Third, a recipe with one of the destroyed robots and the laptop, with a very long crafting time, could be made. Reverse engineering the software, identifying exploits, determining key weaknesses, etc. It'd require a significant amount of energy, a broken robot, and a laptop. One could break it down into robots by manufacturer, with one 'hackPRO: g.Atomix turret exploits' data for each. If the player has said data on the laptop, he can perform even better harassment like shutting down, damaging, messing with IFF identifying.

Finally, one could spend an even greater amount of time coding/reverse engineering the system and its protocols, backdoors, etc. This would generate a different item 'General Atomix turret IDE' or something. This would allow the laptop to behave as the current one does now. Possibly this data could spawn rarely in office buildings or labs, anywhere where the engineers who make or service these things might be.

Maybe another item could spawn with soldiers that would have similar, but very limited and rigid functions, like a 'control tablet', intended for use by soldiers (like the aerial reconnaissance tablets or this: https://www.popularmechanics.com/military/research/a15072/drone-strikes-tablet/ ).

int deliver_move_cost = std::max( 100, 1000 - p->int_cur * 10 - p->get_skill_level( skill_computer ) * 10 );
const int mode_move_cost = 100;

int choice = uilist(_("Welcome to hackPRO!:"),

Choose a reason for hiding this comment

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

Suggested change
int choice = uilist(_("Welcome to hackPRO!:"),
int choice = uilist(_("Welcome to hackPRO!"),

@Amoebka
Copy link
Contributor

Amoebka commented May 28, 2019

Knowing absolutely nothing about real-life hacking and speaking from purely gameplay perspective, shutting down the receiver forever is the only option that makes sense. Becoming immune to hacking for a limited time does absolutely nothing to solve control laptop being overpowered, because it simply encourages the player to fall back and wait it out before trying again.

@KyrasRisven
Copy link
Contributor

Personally I would say shutting down it's main frequency makes sense, as long as it has a much more difficult to hack "back door" frequency.

Like failing to hack a robot could lead to those messages, but you could still attempt a more difficult second hack. If that fails it's assumed to be compromised and blocks your future attempts (now that it "has a bead on you" so to say) while leaving that frequency open for proper operators to issue commands.

@paulenka-aleh
Copy link

shutting down the receiver forever is the only option that makes sense

  1. Make hacking via control laptop non-permanent. After unknown threshold make it reboot IFF to turn hostile again. Give a warning to the player about robot being rebooted.
  2. Get rid of IFF override via control laptop at all or make it a feature available only after decent amount of work involving INT, computer skill and remains of a robot, otherwise allow only temporary overload leading to a few kinutes of reboot.
  3. Adjust difficulty formula and time required to hack / overload.
  4. Make permanent IFF override possible only to adjacent robot which isn't hostile and still make hacking require decent skill, override and prepared upfront hacking software.
  5. Keep the idea of turning off receiver temporarely in response to failed hacking or overload. Keep an alert to robots nearby to do the same. Make it short as long as it would take human now-zombified personnel to reach the hacker and shut him down.

So, in mid-game one would be able to shut down 1-2 robots given some time, lsptop charge, patience and luck. Then pass by or bash them to death.

In end-game a real hacker who collected enough robot remains and spent about one in-game day per robot type would be able to get 1-2 friendly robots from a group given enough skill, time, charge, patience, luck and involving a hit of risk since you're to get adjacent to the bot in question and keep it on.

Though in end-game balance-wise you can just throw emp or another bomb into it, make use of your bionics, wait until it runs out of ammo if you can make it shoot without approaching, run a remotely-controlled vehicle into it and whatever else your imagination suggests. So if you're not a hacker and don't need a friendly bot you have even easier options.

So I'd probably I'd even not apply all of them. At least not in one PR...

@John-Candlebury
Copy link
Member

John-Candlebury commented May 29, 2019

I disagree with the idea of making temporary friends. The laptop already does that as a failure punishment, and it doesn't really work that well at all. Mostly it just causes unforeseen YASDs on unexperienced players.


Honestly I think @tenmilimaster has the best idea. Get better components now that we have them, and make it slightly more versatile early on.
Then make normal hack pro work only on cheap commercial robots, and then force the players to find lab software to hack other enemies.


Just make sure not to overnerf the laptop, it is still clearly end game content, something you have to work towards getting, and one of the few items that actually allow unique game play based on robots instead of the normal katana/rivtech/lasertruck murder combo endgame.

@AMurkin
Copy link
Contributor

AMurkin commented May 29, 2019

Add a narrow-angle directional antenna. And only work if the target hit the signal cone.

@Entity-y
Copy link
Contributor

Instead of nerfing, why not overhaul the control laptop. Give a menu with multiple options to deactivate (and reactivate), remove target parameters, and make friendly. I don't like the idea of a robot/turret randomly turning back on against me after a successful hack, I wouldn't even bother hacking anymore. Rather than a simple text prompt, make hacking into a minigame something similar to Robot Finds Kitten. With the smartphone becoming more of a universal tool, perhaps that too could be used as a hacking tool.

Slightly off topic, deactivated and shut down terminals should ideally be able to be restored by a skilled player, granting access to the contents within or allowing another attempt at getting into locked down areas.

@matthemsteger
Copy link
Contributor Author

Ok I have heard all the comments and all the ideas and maybe some things can be done in phases, but as a phase 1 I would like to do a "give/take" sort of adjustment to the control laptop.

  • GIVE control laptop has additional option of immobilizing for a duration (-difficulty)

  • TAKE control laptop overriding friend/foe is much harder with default laptop (++difficulty)

  • GIVE (?) hacking is more intelligence based, less against the robot difficulty

  • GIVE/TAKE introduce way to increase chances of friend/foe through a more realistic (maybe) process of trying to find vulnerabilities (see below)

  • Robots have a chance to drop Robotic Brain (maybe a more science-y name is needed), in addition to rare spawns elsewhere.

  • (want) Control laptop recipe book will include Robotic Brain Interface, which you can craft, required to interface with such brains

  • Control laptop menu now includes scan brain for vulnerabilities, so that it will increase your chance of hacking friend/foe

  • (want) Brains are different for each robot species, such that the control laptop stores the robots that you have previously scanned for vulnerabilities

Maybe this is more palatable?

Anyway .. this diversifies the control laptop a bit, makes it a bit more involved to craft up perhaps, and makes you think about how you are going to approach these robots without the control laptop before you unlock the ability to roll right through them.

@anothersimulacrum
Copy link
Member

For the parts, perhaps you could build on the robot salvage system #30456?

@matthemsteger
Copy link
Contributor Author

For the parts, perhaps you could build on the robot salvage system #30456?

Awesome call out, thanks!

@Mcrone617
Copy link

Hey @matthemsteger I'm working with @DracoGriffin to try to increase public participation and create public testing of PR's like this that can benefit from some large scale testing. This is done through posting PR tests on the subreddit, giving a rundown of the changes, and then having people test and leave feedback. For something like your balance change, it can really benefit from a bunch of people messing around with it. Of course, you're still working on your PR, so if you're interested in this, and once you have the PR in a spot you're happy with, let me know and we can work through getting a compiled and a downloadable version distributed. Hope to hear from you!

@matthemsteger
Copy link
Contributor Author

I hope to get back to this later this week. It has been very hot here and sitting an programming is not exactly pleasant at home :)

Further testing would be cool, as I am hoping I can let the scope get a little larger and not just somewhat include the robot salvage, but make it a cornerstone of successful and powerful hacking. Hacking without using the salvaged parts to learn about these robot systems will be limited to 1 to 1 "denial of service" hacking that happens between a laptop and a single robot, subject to the power draw over time while its doing this, turning the subject neutral and unable to deal with anything around it. At least that's the system I am thinking about. It would basically scale the control laptop naturally (as you salvage robots), while possibly giving it to players a little earlier since it won't be as powerful without other ways of salvage.

@matthemsteger
Copy link
Contributor Author

I am closing this for now .. I think a staged approach might be better improving laptops as a whole and then easing into the control laptop and hacking as part of using laptops property. Right now the control laptop is the only laptop, and all other laptops are said to be broken, which is not really realistic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[C++] Changes (can be) made in C++. Previously named `Code` Game: Balance Balancing of (existing) in-game features. [JSON] Changes (can be) made in JSON
Projects
None yet
Development

Successfully merging this pull request may close these issues.