The International Simutrans Forum

 

Author Topic: Discomfort penalty does not appear to work correctly  (Read 194 times)

0 Members and 1 Guest are viewing this topic.

Offline Freahk

  • Devotee
  • *
  • Posts: 1257
  • Languages: DE, EN
Discomfort penalty does not appear to work correctly
« on: August 23, 2020, 07:41:48 PM »
I have just checked the simuconf and found the following:
Quote
max_luxury_bonus_differential=0
max_luxury_bonus_percent=0
max_discomfort_penalty_differential=220
max_discomfort_penalty_percent=25

From the descriptions, that means any comfort above the comfortable level won't give any bonus.
Any discomfort will cause a penalty, where the maximum penalty of 25% is applied at 220 discomfort.

From my above example, this does not seem to work correctly.
In case of IC2 it's roughly a ~1% penalty at 23 discomfort. I'd expect roughly 2.5% here.
In case of the oversea shipping, it's a ~5% comfort penalty at 36 discomfort, which is roughly fine, but the panalty won't increase further. At 220 discomfort it's still ~5%, where I would expect 25%

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 20207
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: Discomfort penalty does not appear to work correctly
« Reply #1 on: August 24, 2020, 10:01:18 PM »
Thank you for your report. I have split this from the general discussion topic as this appears to be a bug report, and bug reports need to go into their own threads so that I can keep track of them. I will look into this when I have a moment.

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 20207
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: Discomfort penalty does not appear to work correctly
« Reply #2 on: August 25, 2020, 11:36:58 PM »
I have spent some considerable time looking into this. The position is somewhat complex. Some time ago (before 2013), there appears to have been code added intentionally limiting fare after the discomfort penalty to 95% of the base fare, possibly for balancing reasons long since lost to history. This was shortly afterwards modified to 75% and the simuconf.tab comments, even now, reflected this. Somehow, this seems to have been reverted to 95%, although I was not able to find the commit in which this occurred. Given that we now have a configurable value in simuconf.tab, this 95% limit seems arbitrary and I have removed it.

However, there was another problem: the derating of the discomfort penalty with speed was not working properly due to byte size errors and produced erratic results. I have now fixed this. Thus, the comfort system should now work as designed.

I should be grateful if people could re-test with the next nightly build.

Offline Freahk

  • Devotee
  • *
  • Posts: 1257
  • Languages: DE, EN
Re: Discomfort penalty does not appear to work correctly
« Reply #3 on: August 26, 2020, 10:28:56 AM »
I was about to test this, but it doesn't seem to be fixed in #0b9ca7
Though, the server is running another build, so I am not sure if that is the latest build.

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 20207
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: Discomfort penalty does not appear to work correctly
« Reply #4 on: August 26, 2020, 10:33:08 AM »
I was about to test this, but it doesn't seem to be fixed in #0b9ca7
Though, the server is running another build, so I am not sure if that is the latest build.

I am not sure that I understand - the latest download is #a28e0e4, which is also running on the server. I should be grateful if you could test this version. Thank you.

Offline Freahk

  • Devotee
  • *
  • Posts: 1257
  • Languages: DE, EN
Re: Discomfort penalty does not appear to work correctly
« Reply #5 on: August 26, 2020, 01:42:20 PM »
It seems there was a general issue with the version this morning. It updated to the latest version now.

I had a quick look at this and it seems to be working as intended now. Will need to reconsider steam ships on intercontinental lines now :)

Offline jamespetts

  • Simutrans-Extended project coordinator
  • Moderator
  • *
  • Posts: 20207
  • Cake baker
    • Bridgewater-Brunel
  • Languages: EN
Re: Discomfort penalty does not appear to work correctly
« Reply #6 on: August 26, 2020, 01:54:51 PM »
Splendid, thank you for confirming.