Sending messages from Master Application to peer(s)

Hello, we are looking to find out if there is a way to send messages from Master application to a specific peer(s).

As we can see from "HiveGame.cs", we are able to send events to clients at will without having to go through a operation response. We are looking to see if to see if there is an alternative for the Master.

/// <summary>
/// Sends an event for all clients.
/// </summary>
/// <param name="eventCode">The code of the event.</param>
/// <param name="eventParameters">The parameters for the event.</param>
public void SendEventToAllClients (byte eventCode, object[] eventParameters)
{		
	try
        {
		var customEvent = new CustomEvent(0, eventCode, eventParameters);

		this.PublishEvent(customEvent, this.Actors, new SendParameters());
        }
	catch (System.Exception e)
        {
		throw new Exception("Unknown error in SendEventToAllClients: " + e.Message);
        }	
}
As you can see, "PublishEvent" allows us to achieve this, is there something similar to this in the Master application?

Thanks in advance.

Comments

  • Hi, @Samuelroos
    MasterApplication is Photon Application. So everything that is possible on GS, also possible on Master server. There is no such method as PublishEvent in MasterServer code, but you may copy there, right?

    best,
    ilya
Sign In or Register to comment.