You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am reporting a problem I encountered in v 1.14.0. #120 This is related to the automatic resolution of ISubscriber<> and IPublisher<>.
I am using MessagePipe along with a tiered VContainer.
For example, a ParentContainer (SceneContainer) with a ChildContainer (EnemyContainer) placed under it.
So, when an event occurs in ChildContainer, you may want to notify ParentContainer of it.
For example, when an Enemy dies and spawns a drop item, this kind of messaging would allow us to keep the Enemy and the spawned item separate.
I used this method a lot.
Until now, if I had not written a RegisterMessageBroker in ChildContainer, the MessageHandler's Publisher in ParentContainer was automatically Injected to EventTrigger in ChildContainer.
However, with the automatic resolution of ISubscriber<> and IPublisher<>, even if the RegisterMessageBroker is not written in ChildContainer, it will be automatically registered, and the automatically generated MessageHandler generated automatically in ChildContainer will be injected.
Events that occur in ChildContainer are not notified to the ParentContainer's Handler, and the expected behavior is not achieved.
Is there an option to disable auto-registration in some Containers?
Or is the design itself not very good to try to separate functions using messaging in this manner?
I am reporting a problem I encountered in v 1.14.0. #120 This is related to the automatic resolution of
ISubscriber<>
andIPublisher<>
.I am using MessagePipe along with a tiered VContainer.
For example, a ParentContainer (SceneContainer) with a ChildContainer (EnemyContainer) placed under it.
So, when an event occurs in ChildContainer, you may want to notify ParentContainer of it.
For example, when an Enemy dies and spawns a drop item, this kind of messaging would allow us to keep the Enemy and the spawned item separate.
I used this method a lot.
Until now, if I had not written a RegisterMessageBroker in ChildContainer, the MessageHandler's Publisher in ParentContainer was automatically Injected to EventTrigger in ChildContainer.
However, with the automatic resolution of
ISubscriber<>
andIPublisher<>
, even if the RegisterMessageBroker is not written in ChildContainer, it will be automatically registered, and the automatically generated MessageHandler generated automatically in ChildContainer will be injected.Events that occur in ChildContainer are not notified to the ParentContainer's Handler, and the expected behavior is not achieved.
Is there an option to disable auto-registration in some Containers?
Or is the design itself not very good to try to separate functions using messaging in this manner?
--my environment
Unity2022.3.10
VContainer1.15.4
MessagePipe1.8.1
The text was updated successfully, but these errors were encountered: