Got cluster chat support working. Made it an invocation service rather

than a place service (which may be changed back when place services
improve or I may change the main chat stuff to be an invocation service).


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@803 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
Michael Bayne
2001-12-16 21:02:18 +00:00
parent 4f716cd540
commit 1c02c2d6f4
6 changed files with 151 additions and 68 deletions
@@ -1,5 +1,5 @@
//
// $Id: SpotService.java,v 1.3 2001/12/16 05:18:20 mdb Exp $
// $Id: SpotService.java,v 1.4 2001/12/16 21:02:18 mdb Exp $
package com.threerings.whirled.spot.client;
@@ -48,4 +48,20 @@ public class SpotService implements SpotCodes
Log.info("Sent changeLoc request [sceneId=" + sceneId +
", locId=" + locationId + "].");
}
/**
* Requests that the supplied message be delivered to listeners in the
* cluster to which the specified location belongs.
*/
public static void clusterSpeak (
Client client, int sceneId, int locationId, String message,
SpotSceneDirector rsptarget)
{
InvocationDirector invdir = client.getInvocationDirector();
Object[] args = new Object[] {
new Integer(sceneId), new Integer(locationId), message };
invdir.invoke(MODULE_NAME, CLUSTER_SPEAK_REQUEST, args, rsptarget);
Log.info("Sent clusterSpeak request [sceneId=" + sceneId +
", locId=" + locationId + ", message=" + message + "].");
}
}