AdminMessageRequest Class |
Namespace: Sfs2X.Requests
public class AdminMessageRequest : GenericMessageRequest
Name | Description | |
---|---|---|
AdminMessageRequest(String, MessageRecipientMode) |
See AdminMessageRequest(string, MessageRecipientMode, ISFSObject) constructor.
| |
AdminMessageRequest(String, MessageRecipientMode, ISFSObject) |
Creates a new AdminMessageRequest instance.
|
void SomeMethod() { sfs.AddEventListener(SFSEvent.ADMIN_MESSAGE, OnAdminMessage); // Set the message recipients: all users in the Zone MessageRecipientMode recipMode = new MessageRecipientMode(MessageRecipientMode.TO_ZONE, null); // Send the administrator message sfs.Send( new AdminMessageRequest("Hello to everybody from the Administrator!", recipMode) ); } void OnAdminMessage(BaseEvent evt) { Console.WriteLine("The administrator sent the following message: " + (string)evt.Params["message"]); // .Net / Unity System.Diagnostics.Debug.WriteLine("The administrator sent the following message: " + (string)evt.Params["message"]); // UWP }