CorsixTH/CorsixTH — pull request #313 by benckx (2014-09-16 10:04:18+00:00)
Title: Drug casebook price impact [2]

Issue: So far prices have no impact whatsoever. So player can increase all prices up to 200% without any consequence. It provides an unbalanced and undeserved advantage (it's almost a cheat).

The idea behind this patch is to compute the gap between the expected price level (given staff skill, fatigue, treatment reputation, cure effectiveness, etc.) and the price level in the casebook. Patient happiness is adjusted proportionally. Hospital reputation can only be impacted if the price distortion reaches thresholds (e.g. a 30% gap) and randomly (1 out of 10); this way it's not too impacting.

One patch had already been discussed earlier. This change is partially based on this conversation: https://github.com/CorsixTH/CorsixTH/pull/266

It's quite difficult to know exactly how to adjust all the variables (weight/influence of each variable, randomness, reputation changes, etc.) After testing with a few different settings, when I finally got something nice and more or less balanced, I run the following simulations. Let me know if you find a nice setting. I would be interesting to test it with poorly skilled staff.

Initial:
- Reputation: 582
- Balance: +44,000
- Cured: 131
- Highly skilled staff
- Wage requests granted

If I let it run for one year without any manual intervention and with different price levels.

All prices at 50%:
- Reputation: 704
- Balance: -26,000
- Cured: 233
- Price distortion: -0.50 to -0.70

All prices at 100%:
- Reputation: 652
- Balance: +44,000
- Cured: 225
- Price distortion: -0.25 to -0.45

All prices at 200%:
- Reputation: 617
- Balance: +171,000
- Cured: 231
- Price distortion: 0.25 to 0.45

I didn't look how it works exactly but it seems like reputation does not influence the number of patients coming to the hospital. That could be for another patch.