Results 1 to 2 of 2

Thread: BroadcoastMSG on different ApplicationInstance client is on

  1. #1
    Join Date
    Mar 2013

    Default BroadcastMSG on different ApplicationInstance client is on

    Hi Guys,

    I was wondering how to use broadcastmsg on a different ApplicationInstance than a client is currently on - either manually, or by detecting it. What I want to do is user broadcastmsg to the "default" application instance, but instead it's only broadcasting to the "default2" instance. Here's what I have for example:

    public IApplicationInstance _appInstance; // this is coming in as 'default2' when i check the appinstance
    public void onDisconnect(IClient client) {
    _appInstance.broadcastMsg("dothis"); // but right here I want to broadcast the function dothis to the "default" appinstance - not default 2

    Is it possible to use broadcastMsg on a manually named Appinstance?

    Last edited by comewhatmay; 03-25-2013 at 02:07 PM.

  2. #2
    Join Date
    Dec 2007


    You can do IApplicationInstance.broadcastMsg() on any app instance that exists. It won't work if it has not already been instantiated.

    IApplicationInstance appInstanceDefault2 = client.getApplication().getAppInstance("default2");

Similar Threads

  1. Is ApplicationInstance.BroadcastMsg the same as Stream.sendDirect ?
    By Neutralo in forum Server-side Modules and Code Samples Discussion
    Replies: 2
    Last Post: 01-23-2012, 03:07 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts