Revamped some table stuff. First I don't know why I called players occupants,

that was stupid. Now they're called players. Next I added a list of watchers
rather than simply a count. If we're going to go to all the trouble to update
the table when the watchers change, let's have the goods.

This will probably break Bang and/or Yohoho. I'll fix them toot sweet.


git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@515 c613c5cb-e716-0410-b11b-feb51c14d237
This commit is contained in:
Michael Bayne
2007-12-06 00:37:32 +00:00
parent 0048bde6db
commit 32c4464a85
6 changed files with 118 additions and 99 deletions
@@ -318,7 +318,7 @@ public class TableDirector extends BasicDirector
}
// All this to check to see if we created a party game (and should now enter).
if (table.gameOid != -1 && (table.occupants.length == 0)) {
if (table.gameOid != -1 && (table.players.length == 0)) {
// let's boogie!
_pctx.getParlorDirector().gameIsReady(table.gameOid);
}
@@ -343,9 +343,9 @@ public class TableDirector extends BasicDirector
_ourTable = null;
}
// look for our username in the occupants array
// look for our username in the players array
var self :BodyObject = (_pctx.getClient().getClientObject() as BodyObject);
if (ArrayUtil.contains(table.occupants, self.getVisibleName())) {
if (ArrayUtil.contains(table.players, self.getVisibleName())) {
_ourTable = table;
}