From a8fa2722199c841f5dbca74a5b9d1010e37c91d5 Mon Sep 17 00:00:00 2001 From: Michael Bayne Date: Thu, 5 Oct 2006 00:37:35 +0000 Subject: [PATCH] I justed checked this in in the other order, but somehow it insists on coming out in this order now. This should not be non-deterministic. Reflection should give me the methods in the order they are declared in the Java class so I don't know what the major malfunction is here, but if it keeps up I'm going to fucking alphabetize them and be done with it. git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@95 c613c5cb-e716-0410-b11b-feb51c14d237 --- src/as/com/threerings/parlor/data/Table.as | 44 +++++++++++----------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/src/as/com/threerings/parlor/data/Table.as b/src/as/com/threerings/parlor/data/Table.as index 85fe1a18..a6d0dc6a 100644 --- a/src/as/com/threerings/parlor/data/Table.as +++ b/src/as/com/threerings/parlor/data/Table.as @@ -79,17 +79,17 @@ public class Table } /** - * Get the type of party game being played at this table, or - * PartyGameCodes.NOT_PARTY_GAME. + * Count the number of players currently occupying this table. */ - public function getPartyGameType () :int + public function getOccupiedCount () :int { - if (config is PartyGameConfig) { - return (config as PartyGameConfig).getPartyGameType(); - - } else { - return PartyGameCodes.NOT_PARTY_GAME; + var count :int = 0; + for (var ii :int = 0; ii < occupants.length; ii++) { + if (occupants[ii] != null) { + count++; + } } + return count; } /** @@ -116,20 +116,6 @@ public class Table return players; } - /** - * Count the number of players currently occupying this table. - */ - public function getOccupiedCount () :int - { - var count :int = 0; - for (var ii :int = 0; ii < occupants.length; ii++) { - if (occupants[ii] != null) { - count++; - } - } - return count; - } - /** * For a team game, get the team member indices of the compressed * players array returned by getPlayers(). @@ -168,6 +154,20 @@ public class Table return (PartyGameCodes.NOT_PARTY_GAME != getPartyGameType()); } + /** + * Get the type of party game being played at this table, or + * PartyGameCodes.NOT_PARTY_GAME. + */ + public function getPartyGameType () :int + { + if (config is PartyGameConfig) { + return (config as PartyGameConfig).getPartyGameType(); + + } else { + return PartyGameCodes.NOT_PARTY_GAME; + } + } + /** * Requests to seat the specified user at the specified position in * this table.