Potential Issue with Multiple Udon Components Execution in SDK 3.7.5

In SDK 3.7.5, when a GameObject contains two or more UdonBehaviour components, it seems that only the first Udon component (in the order of attachment) executes its event or similar event logic during runtime. Any additional Udon components on the same GameObject do not appear to execute their logic as expected.OnInteract

  • Reproducible Steps:
    1. Attach two or more UdonBehaviour components to a single GameObject.
    2. Assign different logic to each Udon component.OnInteract
    3. Enter play mode or upload the world to VRChat.
    4. Interact with the object in question.
  • Expected Behavior: All Udon components on the GameObject should execute their respective (or other event-bound) logic.OnInteract
  • Observed Behavior: Only the first Udon component (in the inspector hierarchy) executes its logic. The other components remain unresponsive.

Testing and Findings

To confirm this is related to SDK version 3.7.5, I performed the following tests:

  1. Downgraded to SDK version 3.7.0 and repeated the same steps. Result: All Udon components on the GameObject executed their respective logic as expected.
  2. Upgraded again to SDK 3.7.5, where the issue reappeared.
  3. Tested with a clean project and a minimal setup (a single GameObject with two UdonBehaviour components). The behavior remained consistent, ruling out conflicts from other scripts or assets.
1 Like

I see, very interesting.

1 Like

I was wondering if this is an intentional design change or if it might be a bug. If it’s intentional, I’d love to understand the reasoning behind it, as it could help me adapt my workflow better.

Thanks for all the hard work you put into making VRChat amazing!

1 Like

Based on my extensive experience, this behavior is most likely not intentional. Multiple UdonBehaviour components should be able to execute their respective logic independently on the same GameObject. From my testing, I would consider this a bug.

Why It Could Be a Bug:

  • Udon’s Event System: Udon is designed to support multiple UdonBehaviour components on the same GameObject, with each component running its own logic independently. If this isn’t happening, it suggests there’s a bug in how events are dispatched and managed.
  • Version Regression: This issue only appears in SDK 3.7.5 and is not present in SDK 3.7.0, indicating that a regression was introduced between these versions. It’s likely that a change in SDK 3.7.5, whether intentional or not, is causing this behavior.

Possible Causes:

  • Event Dispatching: There may be an issue with how Udon handles event dispatching. It seems that only the first UdonBehaviour component is being registered to handle events (like OnInteract), while other components are ignored.
  • Internal SDK Changes: Changes in SDK 3.7.5 related to how Udon components are instantiated or managed could be interfering with the execution of event logic for additional components.

Temporary Workaround:

  • Downgrade to SDK 3.7.0: As you’ve found, downgrading to SDK 3.7.0 resolves the issue. This is a suitable temporary workaround, but it’s not a permanent fix. It’s important that this issue gets reported so it can be addressed in future SDK updates.

Thanks for the kind words! While I’m not a VRChat employee, I’m always happy to contribute and help out in the community as the helpful VRChat Guy.

If you continue to experience this issue or need further assistance, I’d recommend submitting a bug report directly to VRChat’s feedback platform:

Feel free to ask around there if the issue persists or if you need more support.


Let me know if you need anything else!

1 Like