From 3fd31717257aba307973f46c624dac7cd59d5d83 Mon Sep 17 00:00:00 2001 From: Ray Greenwell Date: Tue, 28 Apr 2009 17:35:28 +0000 Subject: [PATCH] Oh actionscript, you vex me so. git-svn-id: svn+ssh://src.earth.threerings.net/vilya/trunk@821 c613c5cb-e716-0410-b11b-feb51c14d237 --- .../parlor/game/client/GameController.as | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/as/com/threerings/parlor/game/client/GameController.as b/src/as/com/threerings/parlor/game/client/GameController.as index 3283d96e..fb9f21e8 100644 --- a/src/as/com/threerings/parlor/game/client/GameController.as +++ b/src/as/com/threerings/parlor/game/client/GameController.as @@ -171,18 +171,13 @@ public /*abstract*/ class GameController extends PlaceController /** * Returns the persistent user id for the supplied player name. + * + * @param spec a Name or OccupantInfo. */ - public function getPlayerPersistentId (name :Name) :int + public function getPlayerPersistentId (spec :*) :int { - return (_userIder == null) ? 0 : _userIder.getUserId(name); - } - - /** - * Returns the persistent user id for the supplied occupant info. - */ - public function getPlayerPersistentId (occInfo :OccupantInfo) :int - { - return getPlayerPersistentId(occInfo.username); + return (_userIder == null) ? 0 : + _userIder.getUserId((spec is OccupantInfo) ? OccupantInfo(spec).username : Name(spec)); } /**