com.threerings.whirled.spot.client
Interface SpotService

All Superinterfaces:
com.threerings.presents.client.InvocationService
All Known Implementing Classes:
SpotMarshaller

public interface SpotService
extends com.threerings.presents.client.InvocationService

Defines the mechanism by which the client can request to move around within a scene and between scenes (taking exit and entry locations into account). These services should not be used directly, but instead should be accessed via the SpotSceneDirector.


Nested Class Summary
static interface SpotService.SpotSceneMoveListener
          Used to communicate the response to a SceneService.moveTo(int, int, com.threerings.whirled.client.SceneService.SceneMoveListener) request.
 
Nested classes/interfaces inherited from interface com.threerings.presents.client.InvocationService
com.threerings.presents.client.InvocationService.ConfirmListener, com.threerings.presents.client.InvocationService.InvocationListener, com.threerings.presents.client.InvocationService.ResultListener
 
Method Summary
 void changeLocation(int sceneId, Location loc, com.threerings.presents.client.InvocationService.ConfirmListener listener)
          Requests that this client's body be made to move to the specified location.
 void clusterSpeak(String message, byte mode)
          Requests that the supplied message be delivered to listeners in the cluster to which the specified location belongs.
 void joinCluster(int friendOid, com.threerings.presents.client.InvocationService.ConfirmListener listener)
          Requests that this client start or join the specified cluster.
 void traversePortal(int sceneId, int portalId, int destSceneVer, SpotService.SpotSceneMoveListener listener)
          Requests to traverse the specified portal.
 

Method Detail

traversePortal

void traversePortal(int sceneId,
                    int portalId,
                    int destSceneVer,
                    SpotService.SpotSceneMoveListener listener)
Requests to traverse the specified portal.

Parameters:
sceneId - the player's current scene which is used to sanity check things when the request actually arrives.
portalId - the portal to be traversed.
destSceneVer - the version of the destination scene data that the client has in its local repository.

changeLocation

void changeLocation(int sceneId,
                    Location loc,
                    com.threerings.presents.client.InvocationService.ConfirmListener listener)
Requests that this client's body be made to move to the specified location. The user will be removed from any cluster from which they are an occupant.

Parameters:
sceneId - the id of the scene in which to change location.
loc - the location to which to move.

joinCluster

void joinCluster(int friendOid,
                 com.threerings.presents.client.InvocationService.ConfirmListener listener)
Requests that this client start or join the specified cluster. They will be relocated appropriately by the scene manager.

Parameters:
friendOid - the bodyOid of another user or the oid of an existing cluster; the calling user will be made to join the cluster or target user's cluster, or create a cluster with the target user if they are not already in one.

clusterSpeak

void clusterSpeak(String message,
                  byte mode)
Requests that the supplied message be delivered to listeners in the cluster to which the specified location belongs.

Parameters:
message - the text of the message to be spoken.
mode - an associated mode constant that can be used to identify different kinds of "speech" (emote, thought bubble, etc.).


Copyright © 2011. All Rights Reserved.