1165 lines
51 KiB
HTML
1165 lines
51 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
|
<!-- NewPage -->
|
|
<html lang="en">
|
|
<head>
|
|
<!-- Generated by javadoc (1.8.0_31) on Sat Mar 14 10:07:08 PDT 2015 -->
|
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
|
<title>GameObject (Vilya Core 1.6 API)</title>
|
|
<meta name="date" content="2015-03-14">
|
|
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
|
|
<script type="text/javascript" src="../../../../../script.js"></script>
|
|
</head>
|
|
<body>
|
|
<script type="text/javascript"><!--
|
|
try {
|
|
if (location.href.indexOf('is-external=true') == -1) {
|
|
parent.document.title="GameObject (Vilya Core 1.6 API)";
|
|
}
|
|
}
|
|
catch(err) {
|
|
}
|
|
//-->
|
|
var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10};
|
|
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
|
|
var altColor = "altColor";
|
|
var rowColor = "rowColor";
|
|
var tableTab = "tableTab";
|
|
var activeTableTab = "activeTableTab";
|
|
</script>
|
|
<noscript>
|
|
<div>JavaScript is disabled on your browser.</div>
|
|
</noscript>
|
|
<!-- ========= START OF TOP NAVBAR ======= -->
|
|
<div class="topNav"><a name="navbar.top">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a name="navbar.top.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="class-use/GameObject.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li><a href="../../../../../com/threerings/parlor/game/data/GameConfig.html" title="class in com.threerings.parlor.game.data"><span class="typeNameLink">Prev Class</span></a></li>
|
|
<li><a href="../../../../../com/threerings/parlor/game/data/UserIdentifier.html" title="class in com.threerings.parlor.game.data"><span class="typeNameLink">Next Class</span></a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../../../../index.html?com/threerings/parlor/game/data/GameObject.html" target="_top">Frames</a></li>
|
|
<li><a href="GameObject.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_top">
|
|
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_top");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li><a href="#nested.classes.inherited.from.class.com.threerings.crowd.data.PlaceObject">Nested</a> | </li>
|
|
<li><a href="#field.summary">Field</a> | </li>
|
|
<li><a href="#constructor.summary">Constr</a> | </li>
|
|
<li><a href="#method.summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li><a href="#field.detail">Field</a> | </li>
|
|
<li><a href="#constructor.detail">Constr</a> | </li>
|
|
<li><a href="#method.detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a name="skip.navbar.top">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ========= END OF TOP NAVBAR ========= -->
|
|
<!-- ======== START OF CLASS DATA ======== -->
|
|
<div class="header">
|
|
<div class="subTitle">com.threerings.parlor.game.data</div>
|
|
<h2 title="Class GameObject" class="title">Class GameObject</h2>
|
|
</div>
|
|
<div class="contentContainer">
|
|
<ul class="inheritance">
|
|
<li><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li>com.threerings.presents.dobj.DObject</li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li>com.threerings.crowd.data.PlaceObject</li>
|
|
<li>
|
|
<ul class="inheritance">
|
|
<li>com.threerings.parlor.game.data.GameObject</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<div class="description">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<dl>
|
|
<dt>All Implemented Interfaces:</dt>
|
|
<dd>com.threerings.crowd.chat.data.SpeakObject, com.threerings.io.Streamable</dd>
|
|
</dl>
|
|
<dl>
|
|
<dt>Direct Known Subclasses:</dt>
|
|
<dd><a href="../../../../../com/threerings/parlor/card/data/CardGameObject.html" title="class in com.threerings.parlor.card.data">CardGameObject</a>, <a href="../../../../../com/threerings/puzzle/data/PuzzleObject.html" title="class in com.threerings.puzzle.data">PuzzleObject</a></dd>
|
|
</dl>
|
|
<hr>
|
|
<br>
|
|
<pre>public class <span class="typeNameLabel">GameObject</span>
|
|
extends com.threerings.crowd.data.PlaceObject</pre>
|
|
<div class="block">A game object hosts the shared data associated with a game played by one or more players. The
|
|
game object extends the place object so that the game can act as a place where players actually
|
|
go when playing the game. Only very basic information is maintained in the base game object. It
|
|
serves as the base for a hierarchy of game object derivatives that handle basic gameplay for a
|
|
suite of different game types (ie. turn based games, party games, board games, card games,
|
|
etc.).</div>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="summary">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- ======== NESTED CLASS SUMMARY ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="nested.class.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Nested Class Summary</h3>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="nested.classes.inherited.from.class.com.threerings.crowd.data.PlaceObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Nested classes/interfaces inherited from class com.threerings.crowd.data.PlaceObject</h3>
|
|
<code>com.threerings.crowd.data.PlaceObject.ManagerCaller</code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="nested.classes.inherited.from.class.com.threerings.crowd.chat.data.SpeakObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Nested classes/interfaces inherited from interface com.threerings.crowd.chat.data.SpeakObject</h3>
|
|
<code>com.threerings.crowd.chat.data.SpeakObject.ListenerOp</code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="nested.classes.inherited.from.class.com.threerings.io.Streamable">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Nested classes/interfaces inherited from interface com.threerings.io.Streamable</h3>
|
|
<code>com.threerings.io.Streamable.Closure</code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- =========== FIELD SUMMARY =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="field.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Field Summary</h3>
|
|
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
|
|
<caption><span>Fields</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier and Type</th>
|
|
<th class="colLast" scope="col">Field and Description</th>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#CANCELLED">CANCELLED</a></span></code>
|
|
<div class="block">A game state constant indicating that the game was cancelled.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#GAME_OVER">GAME_OVER</a></span></code>
|
|
<div class="block">A game state constant indicating that the game ended normally.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#IN_PLAY">IN_PLAY</a></span></code>
|
|
<div class="block">A game state constant indicating that the game is in play.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#IS_PRIVATE">IS_PRIVATE</a></span></code>
|
|
<div class="block">The field name of the <code>isPrivate</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#IS_RATED">IS_RATED</a></span></code>
|
|
<div class="block">The field name of the <code>isRated</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isPrivate">isPrivate</a></span></code>
|
|
<div class="block">Indicates whether the game is "private".</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isRated">isRated</a></span></code>
|
|
<div class="block">Indicates whether or not this game is rated.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYER_IN_PLAY">PLAYER_IN_PLAY</a></span></code>
|
|
<div class="block">The player status constant for a player whose game is in play.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYER_LEFT_GAME">PLAYER_LEFT_GAME</a></span></code>
|
|
<div class="block">The player status constant for a player whose has been knocked out of the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYER_STATUS">PLAYER_STATUS</a></span></code>
|
|
<div class="block">The field name of the <code>playerStatus</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>com.threerings.util.Name[]</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#players">players</a></span></code>
|
|
<div class="block">The usernames of the players involved in this game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYERS">PLAYERS</a></span></code>
|
|
<div class="block">The field name of the <code>players</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>int[]</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#playerStatus">playerStatus</a></span></code>
|
|
<div class="block">If null, indicates that all present players are active, or for more complex games can be
|
|
non-null to indicate the current status of each player in the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PRE_GAME">PRE_GAME</a></span></code>
|
|
<div class="block">A game state constant indicating that the game has not yet started and is still awaiting
|
|
the arrival of all of the players.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#SESSION_ID">SESSION_ID</a></span></code>
|
|
<div class="block">The field name of the <code>sessionId</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#sessionId">sessionId</a></span></code>
|
|
<div class="block">A unique identifier for each game session.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#state">state</a></span></code>
|
|
<div class="block">The game state, one of <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PRE_GAME"><code>PRE_GAME</code></a>, <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#IN_PLAY"><code>IN_PLAY</code></a>, <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#GAME_OVER"><code>GAME_OVER</code></a>, or
|
|
<a href="../../../../../com/threerings/parlor/game/data/GameObject.html#CANCELLED"><code>CANCELLED</code></a>.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#STATE">STATE</a></span></code>
|
|
<div class="block">The field name of the <code>state</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colFirst"><code>boolean[]</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#winners">winners</a></span></code>
|
|
<div class="block">Whether each player in the game is a winner, or null if the game is not yet over.</div>
|
|
</td>
|
|
</tr>
|
|
<tr class="rowColor">
|
|
<td class="colFirst"><code>static <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#WINNERS">WINNERS</a></span></code>
|
|
<div class="block">The field name of the <code>winners</code> field.</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="fields.inherited.from.class.com.threerings.crowd.data.PlaceObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Fields inherited from class com.threerings.crowd.data.PlaceObject</h3>
|
|
<code>manager, OCCUPANT_INFO, occupantInfo, occupants, OCCUPANTS, SPEAK_SERVICE, speakService</code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="fields.inherited.from.class.com.threerings.crowd.chat.data.SpeakObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Fields inherited from interface com.threerings.crowd.chat.data.SpeakObject</h3>
|
|
<code>DEFAULT_IDENTIFIER</code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Constructor Summary</h3>
|
|
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
|
|
<caption><span>Constructors</span><span class="tabEnd"> </span></caption>
|
|
<tr>
|
|
<th class="colOne" scope="col">Constructor and Description</th>
|
|
</tr>
|
|
<tr class="altColor">
|
|
<td class="colOne"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#GameObject--">GameObject</a></span>()</code> </td>
|
|
</tr>
|
|
</table>
|
|
</li>
|
|
</ul>
|
|
<!-- ========== METHOD SUMMARY =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="method.summary">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Summary</h3>
|
|
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
|
|
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption>
|
|
<tr>
|
|
<th class="colFirst" scope="col">Modifier and Type</th>
|
|
<th class="colLast" scope="col">Method and Description</th>
|
|
</tr>
|
|
<tr id="i0" class="altColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#getActivePlayerCount--">getActivePlayerCount</a></span>()</code>
|
|
<div class="block">Returns the number of active players in the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i1" class="rowColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#getPlayerCount--">getPlayerCount</a></span>()</code>
|
|
<div class="block">Returns the number of players in the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i2" class="altColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#getPlayerIndex-com.threerings.util.Name-">getPlayerIndex</a></span>(com.threerings.util.Name username)</code>
|
|
<div class="block">Returns the player index of the given user in the game, or <code>-1</code> if the player is
|
|
not involved in the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i3" class="rowColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#getWinnerCount--">getWinnerCount</a></span>()</code>
|
|
<div class="block">Returns the number of winners for this game, or <code>0</code> if the winners array is not
|
|
populated, e.g., the game is not yet over.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i4" class="altColor">
|
|
<td class="colFirst"><code>int</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#getWinnerIndex--">getWinnerIndex</a></span>()</code>
|
|
<div class="block">Returns the winner index of the first winning player for this game, or <code>-1</code> if
|
|
there are no winners or the winners array is not yet assigned.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i5" class="rowColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isActivePlayer-int-">isActivePlayer</a></span>(int pidx)</code>
|
|
<div class="block">Returns whether the given player is still an active player in the game.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i6" class="altColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isDraw--">isDraw</a></span>()</code>
|
|
<div class="block">Returns true if the game is ended in a draw.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i7" class="rowColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isInPlay--">isInPlay</a></span>()</code>
|
|
<div class="block">Returns whether the game is in play.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i8" class="altColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isOccupiedPlayer-int-">isOccupiedPlayer</a></span>(int pidx)</code>
|
|
<div class="block">Returns whether the given player index in the game is occupied.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i9" class="rowColor">
|
|
<td class="colFirst"><code>boolean</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isWinner-int-">isWinner</a></span>(int pidx)</code>
|
|
<div class="block">Returns whether the given player index is a winner, or false if the winners are not yet
|
|
assigned.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i10" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setIsPrivate-boolean-">setIsPrivate</a></span>(boolean value)</code>
|
|
<div class="block">Requests that the <code>isPrivate</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i11" class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setIsRated-boolean-">setIsRated</a></span>(boolean value)</code>
|
|
<div class="block">Requests that the <code>isRated</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i12" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setPlayers-com.threerings.util.Name:A-">setPlayers</a></span>(com.threerings.util.Name[] value)</code>
|
|
<div class="block">Requests that the <code>players</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i13" class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setPlayersAt-com.threerings.util.Name-int-">setPlayersAt</a></span>(com.threerings.util.Name value,
|
|
int index)</code>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>players</code> field be set to the specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i14" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setPlayerStatus-int:A-">setPlayerStatus</a></span>(int[] value)</code>
|
|
<div class="block">Requests that the <code>playerStatus</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i15" class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setPlayerStatusAt-int-int-">setPlayerStatusAt</a></span>(int value,
|
|
int index)</code>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>playerStatus</code> field be set to the specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i16" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setSessionId-int-">setSessionId</a></span>(int value)</code>
|
|
<div class="block">Requests that the <code>sessionId</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i17" class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setState-int-">setState</a></span>(int value)</code>
|
|
<div class="block">Requests that the <code>state</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i18" class="altColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setWinners-boolean:A-">setWinners</a></span>(boolean[] value)</code>
|
|
<div class="block">Requests that the <code>winners</code> field be set to the
|
|
specified value.</div>
|
|
</td>
|
|
</tr>
|
|
<tr id="i19" class="rowColor">
|
|
<td class="colFirst"><code>void</code></td>
|
|
<td class="colLast"><code><span class="memberNameLink"><a href="../../../../../com/threerings/parlor/game/data/GameObject.html#setWinnersAt-boolean-int-">setWinnersAt</a></span>(boolean value,
|
|
int index)</code>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>winners</code> field be set to the specified value.</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="methods.inherited.from.class.com.threerings.crowd.data.PlaceObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class com.threerings.crowd.data.PlaceObject</h3>
|
|
<code>addToOccupantInfo, addToOccupants, applyToListeners, getChatIdentifier, getOccupantInfo, initManagerCaller, removeFromOccupantInfo, removeFromOccupants, setOccupantInfo, setSpeakService, shouldBroadcast, updateOccupantInfo</code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="methods.inherited.from.class.com.threerings.presents.dobj.DObject">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class com.threerings.presents.dobj.DObject</h3>
|
|
<code>acquireLock, addListener, addListener, addSubscriber, addToSet, cancelTransaction, changeAttribute, checkPermissions, checkPermissions, commitTransaction, destroy, getAccessController, getAttribute, getLocal, getLocals, getManager, getOid, getSet, inTransaction, isActive, notifyListeners, notifyProxies, postEvent, postMessage, postMessage, releaseLock, removeFromSet, removeListener, removeSubscriber, setAccessController, setAttribute, setDestroyOnLastSubscriberRemoved, setLocal, setManager, setOid, startTransaction, toString, updateSet, which</code></li>
|
|
</ul>
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
|
|
<code><a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
<div class="details">
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<!-- ============ FIELD DETAIL =========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="field.detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Field Detail</h3>
|
|
<a name="STATE">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>STATE</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> STATE</pre>
|
|
<div class="block">The field name of the <code>state</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.STATE">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="IS_RATED">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>IS_RATED</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> IS_RATED</pre>
|
|
<div class="block">The field name of the <code>isRated</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.IS_RATED">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="IS_PRIVATE">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>IS_PRIVATE</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> IS_PRIVATE</pre>
|
|
<div class="block">The field name of the <code>isPrivate</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.IS_PRIVATE">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="PLAYERS">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>PLAYERS</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> PLAYERS</pre>
|
|
<div class="block">The field name of the <code>players</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.PLAYERS">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="WINNERS">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>WINNERS</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> WINNERS</pre>
|
|
<div class="block">The field name of the <code>winners</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.WINNERS">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="SESSION_ID">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>SESSION_ID</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> SESSION_ID</pre>
|
|
<div class="block">The field name of the <code>sessionId</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.SESSION_ID">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="PLAYER_STATUS">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>PLAYER_STATUS</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public static final <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> PLAYER_STATUS</pre>
|
|
<div class="block">The field name of the <code>playerStatus</code> field.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.PLAYER_STATUS">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="PRE_GAME">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>PRE_GAME</h4>
|
|
<pre>public static final int PRE_GAME</pre>
|
|
<div class="block">A game state constant indicating that the game has not yet started and is still awaiting
|
|
the arrival of all of the players.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.PRE_GAME">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="IN_PLAY">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>IN_PLAY</h4>
|
|
<pre>public static final int IN_PLAY</pre>
|
|
<div class="block">A game state constant indicating that the game is in play.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.IN_PLAY">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="GAME_OVER">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>GAME_OVER</h4>
|
|
<pre>public static final int GAME_OVER</pre>
|
|
<div class="block">A game state constant indicating that the game ended normally.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.GAME_OVER">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="CANCELLED">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>CANCELLED</h4>
|
|
<pre>public static final int CANCELLED</pre>
|
|
<div class="block">A game state constant indicating that the game was cancelled.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.CANCELLED">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="PLAYER_IN_PLAY">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>PLAYER_IN_PLAY</h4>
|
|
<pre>public static final int PLAYER_IN_PLAY</pre>
|
|
<div class="block">The player status constant for a player whose game is in play.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.PLAYER_IN_PLAY">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="PLAYER_LEFT_GAME">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>PLAYER_LEFT_GAME</h4>
|
|
<pre>public static final int PLAYER_LEFT_GAME</pre>
|
|
<div class="block">The player status constant for a player whose has been knocked out of the game. NOTE: This
|
|
can include a player choosing to leave a game prematurely.</div>
|
|
<dl>
|
|
<dt><span class="seeLabel">See Also:</span></dt>
|
|
<dd><a href="../../../../../constant-values.html#com.threerings.parlor.game.data.GameObject.PLAYER_LEFT_GAME">Constant Field Values</a></dd>
|
|
</dl>
|
|
</li>
|
|
</ul>
|
|
<a name="state">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>state</h4>
|
|
<pre>public int state</pre>
|
|
<div class="block">The game state, one of <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PRE_GAME"><code>PRE_GAME</code></a>, <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#IN_PLAY"><code>IN_PLAY</code></a>, <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#GAME_OVER"><code>GAME_OVER</code></a>, or
|
|
<a href="../../../../../com/threerings/parlor/game/data/GameObject.html#CANCELLED"><code>CANCELLED</code></a>.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isRated">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isRated</h4>
|
|
<pre>public boolean isRated</pre>
|
|
<div class="block">Indicates whether or not this game is rated.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isPrivate">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isPrivate</h4>
|
|
<pre>public boolean isPrivate</pre>
|
|
<div class="block">Indicates whether the game is "private".</div>
|
|
</li>
|
|
</ul>
|
|
<a name="players">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>players</h4>
|
|
<pre>public com.threerings.util.Name[] players</pre>
|
|
<div class="block">The usernames of the players involved in this game.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="winners">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>winners</h4>
|
|
<pre>public boolean[] winners</pre>
|
|
<div class="block">Whether each player in the game is a winner, or null if the game is not yet over.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="sessionId">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>sessionId</h4>
|
|
<pre>public int sessionId</pre>
|
|
<div class="block">A unique identifier for each game session. Every time the game is started, this value will
|
|
be incremented to provide a unique identifier for that particular session.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="playerStatus">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>playerStatus</h4>
|
|
<pre>public int[] playerStatus</pre>
|
|
<div class="block">If null, indicates that all present players are active, or for more complex games can be
|
|
non-null to indicate the current status of each player in the game. The status value is one
|
|
of <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYER_LEFT_GAME"><code>PLAYER_LEFT_GAME</code></a> or <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#PLAYER_IN_PLAY"><code>PLAYER_IN_PLAY</code></a>.<p> Subclasses of GameObject may use
|
|
other means to determine a player's status in the game, so call <a href="../../../../../com/threerings/parlor/game/data/GameObject.html#isActivePlayer-int-"><code>isActivePlayer(int)</code></a>
|
|
to see if a player is still participating in a game.</div>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- ========= CONSTRUCTOR DETAIL ======== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="constructor.detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Constructor Detail</h3>
|
|
<a name="GameObject--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>GameObject</h4>
|
|
<pre>public GameObject()</pre>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
<!-- ============ METHOD DETAIL ========== -->
|
|
<ul class="blockList">
|
|
<li class="blockList"><a name="method.detail">
|
|
<!-- -->
|
|
</a>
|
|
<h3>Method Detail</h3>
|
|
<a name="getPlayerCount--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getPlayerCount</h4>
|
|
<pre>public int getPlayerCount()</pre>
|
|
<div class="block">Returns the number of players in the game.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="getActivePlayerCount--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getActivePlayerCount</h4>
|
|
<pre>public int getActivePlayerCount()</pre>
|
|
<div class="block">Returns the number of active players in the game.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isActivePlayer-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isActivePlayer</h4>
|
|
<pre>public boolean isActivePlayer(int pidx)</pre>
|
|
<div class="block">Returns whether the given player is still an active player in the game. (Ie. whether or not
|
|
they are still participating.)</div>
|
|
</li>
|
|
</ul>
|
|
<a name="getPlayerIndex-com.threerings.util.Name-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getPlayerIndex</h4>
|
|
<pre>public int getPlayerIndex(com.threerings.util.Name username)</pre>
|
|
<div class="block">Returns the player index of the given user in the game, or <code>-1</code> if the player is
|
|
not involved in the game.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isInPlay--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isInPlay</h4>
|
|
<pre>public boolean isInPlay()</pre>
|
|
<div class="block">Returns whether the game is in play. A game that is not in play could either be awaiting
|
|
players, ended, or cancelled.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isOccupiedPlayer-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isOccupiedPlayer</h4>
|
|
<pre>public boolean isOccupiedPlayer(int pidx)</pre>
|
|
<div class="block">Returns whether the given player index in the game is occupied.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isWinner-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isWinner</h4>
|
|
<pre>public boolean isWinner(int pidx)</pre>
|
|
<div class="block">Returns whether the given player index is a winner, or false if the winners are not yet
|
|
assigned.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="getWinnerCount--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getWinnerCount</h4>
|
|
<pre>public int getWinnerCount()</pre>
|
|
<div class="block">Returns the number of winners for this game, or <code>0</code> if the winners array is not
|
|
populated, e.g., the game is not yet over.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="isDraw--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>isDraw</h4>
|
|
<pre>public boolean isDraw()</pre>
|
|
<div class="block">Returns true if the game is ended in a draw.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="getWinnerIndex--">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>getWinnerIndex</h4>
|
|
<pre>public int getWinnerIndex()</pre>
|
|
<div class="block">Returns the winner index of the first winning player for this game, or <code>-1</code> if
|
|
there are no winners or the winners array is not yet assigned. This is only likely to be
|
|
useful for games that are known to have a single winner.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setState-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setState</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setState(int value)</pre>
|
|
<div class="block">Requests that the <code>state</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setIsRated-boolean-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setIsRated</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setIsRated(boolean value)</pre>
|
|
<div class="block">Requests that the <code>isRated</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setIsPrivate-boolean-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setIsPrivate</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setIsPrivate(boolean value)</pre>
|
|
<div class="block">Requests that the <code>isPrivate</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setPlayers-com.threerings.util.Name:A-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setPlayers</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setPlayers(com.threerings.util.Name[] value)</pre>
|
|
<div class="block">Requests that the <code>players</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setPlayersAt-com.threerings.util.Name-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setPlayersAt</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setPlayersAt(com.threerings.util.Name value,
|
|
int index)</pre>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>players</code> field be set to the specified value.
|
|
The local value will be updated immediately and an event will be
|
|
propagated through the system to notify all listeners that the
|
|
attribute did change. Proxied copies of this object (on clients)
|
|
will apply the value change when they received the attribute
|
|
changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setWinners-boolean:A-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setWinners</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setWinners(boolean[] value)</pre>
|
|
<div class="block">Requests that the <code>winners</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setWinnersAt-boolean-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setWinnersAt</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setWinnersAt(boolean value,
|
|
int index)</pre>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>winners</code> field be set to the specified value.
|
|
The local value will be updated immediately and an event will be
|
|
propagated through the system to notify all listeners that the
|
|
attribute did change. Proxied copies of this object (on clients)
|
|
will apply the value change when they received the attribute
|
|
changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setSessionId-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setSessionId</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setSessionId(int value)</pre>
|
|
<div class="block">Requests that the <code>sessionId</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setPlayerStatus-int:A-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockList">
|
|
<li class="blockList">
|
|
<h4>setPlayerStatus</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setPlayerStatus(int[] value)</pre>
|
|
<div class="block">Requests that the <code>playerStatus</code> field be set to the
|
|
specified value. The local value will be updated immediately and an
|
|
event will be propagated through the system to notify all listeners
|
|
that the attribute did change. Proxied copies of this object (on
|
|
clients) will apply the value change when they received the
|
|
attribute changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
<a name="setPlayerStatusAt-int-int-">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="blockListLast">
|
|
<li class="blockList">
|
|
<h4>setPlayerStatusAt</h4>
|
|
<pre>@Generated(value="com.threerings.presents.tools.GenDObjectTask")
|
|
public void setPlayerStatusAt(int value,
|
|
int index)</pre>
|
|
<div class="block">Requests that the <code>index</code>th element of
|
|
<code>playerStatus</code> field be set to the specified value.
|
|
The local value will be updated immediately and an event will be
|
|
propagated through the system to notify all listeners that the
|
|
attribute did change. Proxied copies of this object (on clients)
|
|
will apply the value change when they received the attribute
|
|
changed notification.</div>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
<!-- ========= END OF CLASS DATA ========= -->
|
|
<!-- ======= START OF BOTTOM NAVBAR ====== -->
|
|
<div class="bottomNav"><a name="navbar.bottom">
|
|
<!-- -->
|
|
</a>
|
|
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
|
|
<a name="navbar.bottom.firstrow">
|
|
<!-- -->
|
|
</a>
|
|
<ul class="navList" title="Navigation">
|
|
<li><a href="../../../../../overview-summary.html">Overview</a></li>
|
|
<li><a href="package-summary.html">Package</a></li>
|
|
<li class="navBarCell1Rev">Class</li>
|
|
<li><a href="class-use/GameObject.html">Use</a></li>
|
|
<li><a href="package-tree.html">Tree</a></li>
|
|
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
|
|
<li><a href="../../../../../index-all.html">Index</a></li>
|
|
<li><a href="../../../../../help-doc.html">Help</a></li>
|
|
</ul>
|
|
</div>
|
|
<div class="subNav">
|
|
<ul class="navList">
|
|
<li><a href="../../../../../com/threerings/parlor/game/data/GameConfig.html" title="class in com.threerings.parlor.game.data"><span class="typeNameLink">Prev Class</span></a></li>
|
|
<li><a href="../../../../../com/threerings/parlor/game/data/UserIdentifier.html" title="class in com.threerings.parlor.game.data"><span class="typeNameLink">Next Class</span></a></li>
|
|
</ul>
|
|
<ul class="navList">
|
|
<li><a href="../../../../../index.html?com/threerings/parlor/game/data/GameObject.html" target="_top">Frames</a></li>
|
|
<li><a href="GameObject.html" target="_top">No Frames</a></li>
|
|
</ul>
|
|
<ul class="navList" id="allclasses_navbar_bottom">
|
|
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
|
|
</ul>
|
|
<div>
|
|
<script type="text/javascript"><!--
|
|
allClassesLink = document.getElementById("allclasses_navbar_bottom");
|
|
if(window==top) {
|
|
allClassesLink.style.display = "block";
|
|
}
|
|
else {
|
|
allClassesLink.style.display = "none";
|
|
}
|
|
//-->
|
|
</script>
|
|
</div>
|
|
<div>
|
|
<ul class="subNavList">
|
|
<li>Summary: </li>
|
|
<li><a href="#nested.classes.inherited.from.class.com.threerings.crowd.data.PlaceObject">Nested</a> | </li>
|
|
<li><a href="#field.summary">Field</a> | </li>
|
|
<li><a href="#constructor.summary">Constr</a> | </li>
|
|
<li><a href="#method.summary">Method</a></li>
|
|
</ul>
|
|
<ul class="subNavList">
|
|
<li>Detail: </li>
|
|
<li><a href="#field.detail">Field</a> | </li>
|
|
<li><a href="#constructor.detail">Constr</a> | </li>
|
|
<li><a href="#method.detail">Method</a></li>
|
|
</ul>
|
|
</div>
|
|
<a name="skip.navbar.bottom">
|
|
<!-- -->
|
|
</a></div>
|
|
<!-- ======== END OF BOTTOM NAVBAR ======= -->
|
|
<p class="legalCopy"><small>Copyright © 2015. All rights reserved.</small></p>
|
|
</body>
|
|
</html>
|