Add CollisionSwitchComponent#344
Conversation
Codecov Report
@@ Coverage Diff @@
## master #344 +/- ##
=======================================
Coverage 83.91% 83.91%
=======================================
Files 125 125
Lines 6741 6741
=======================================
Hits 5657 5657
Misses 1084 1084 Continue to review full report at Codecov.
|
|
So I had a chance to look at the switch manager status. Since this same switch ID is currently hooked to 6 collision switches, the status is only updated when one of the collision switches is enabled. It looks like the switch statuses are stored in a dictionary by ID. Additional switches with the same ID, just override the dictionary value. So the last component is the one that is used for the status: Thoughts on this? |
That's okay, no? I agree it's a bit weird in the editor, but any of those elements triggers the same switch, so it's kinda logical that they all change status synchronously. The other way of handling this would be to additionally store switch statuses in a switch mapping -> status dictionary, just for the editor. I'd create a GitHub issue about this and move along. :) |
Sorry, I guess I didn't explain it properly. I'll create another issue. Switch
If the user hits However, if the user hits The Game Logic Engine will work fine and PinMame registers the switch for The SwitchPlayer statuses are a dictionary by ID So when the player is populating the dictionary, each ID So that's why the manager looks like its only monitoring one device. |


This component will expose switches for the following components that inherit
IApiHittableThis was needed as there are switches behind the drop target banks and non-slingshots in Rock.
This PR also does the following:
netstandard2.1and C# 9.0VisualPinball.Engine.Unity.slncompilation errors using Visual Studio.FluentAssertions to 6.2.0.unityfolder with latest managed dlls for compiling in Visual Studio without Unity(Copied from
/Applications/Unity/Hub/Editor/2021.2.3f1/Unity.app/Contents/Managed/UnityEngineandScriptAssemblies)Remaining:
CollisionSwitch(@freezy)IApiHittable)