Engine icon indicating copy to clipboard operation
Engine copied to clipboard

Bug: `logic_random_outputs` connection has an offset of 1

Open LambdaCore21 opened this issue 1 year ago • 1 comments

Describe the bug

https://developer.valvesoftware.com/wiki/Logic_random_outputs

In order to use the "OnTrigger" event properly, you have to use an offset of 1. This means that the first and last "Chance" option is entirely unusable, too.

In order to get a pair of randomness working, it looks like this:

grafik

https://github.com/StrataSource/Engine/assets/63379443/382fb63d-bb70-4c10-996b-52d699c3c675

To Reproduce

  1. Link two chances to the same number of "OnTrigger"
  2. Your logic doesn't work
  3. Repeat with an offset, now it is working

Issue Map

Any

Expected Behavior

Being able to use OnTrigger1Chance and OnTrigger8Chance

Operating System

No response

LambdaCore21 avatar Feb 25 '24 21:02 LambdaCore21

The only thing that is one off is OnTriggerChanceX keyvalue. FGD has values 1-8, but the game reads 0-7.

SCell555 avatar Feb 26 '24 05:02 SCell555