RaiseEvent with ReceiverGroup.Others strange behavior

Options
My sequence of actions:
First client connect to server and create room. After other player joined I send the event from first client which is master client:

RaiseEventOptions eventOptions = RaiseEventOptions.Default;
eventOptions.CachingOption = EventCaching.DoNotCache;
eventOptions.Receivers = ReceiverGroup.Others;
PhotonNetwork.RaiseEvent((byte)eventType, content, true, eventOptions);
In this case work correctly. In the event handler on second client I receive on other client:
Sender ID:1 Own Id:2

Then I disconnect both clients and I do their connect again, but I change their places. Now second client create room and it is master client. In result of sending an event the master client receives a call and joined client receives nothing.
Response on the master client:
Sender ID:1 Own Id:1
Although it should be the opposite.
I'm confused.

Comments

  • Hi @Ocveran,

    when using the ReceiverGroup.Others option, the message only gets send to the other clients in the room. The sender himself won't receive the message. This is what you have seen correctly in the first case you described.

    To the second case: can you confirm, that this basically is the exact same test scenario except for the changed roles of the two clients? Do both clients join the same room? Is the same code executed as in the first case? Do you use any non-standard Room Options when creating the room?

    By default the sender ID will be always 1 (in this certain scenario) because the first MasterClient of the room always gets this ID.
  • Sathyaraj
    Options

    Even I noticed the same. If I raise an event to others and disconnect -> reconnect, the same message gets delivered to me as well. Strange.