Commit Graph

155 Commits

Author SHA1 Message Date
Michael Bayne 32dee3cbaf 405 modified source files and 17,367 lines of diffs later we now enforce
more discipline when handling names in our code base. Any user entered
name should find its way into a Name object as soon as it comes out of a
text field or whatnot, and stay that way until it makes its way into a
text field or into a database record (for which String objects are vastly
simpler because of JORA magic).

Dear God, let me never again make a change this large for the rest of my
mortal life.

Unfortunately, this means we have to keep an eye out for funny business
pretty much everywhere. However, since we will absolutely want to test
market stalls and so forth on Azure, we'll have an opportunity to iron out
any funny business that might fall under the radar during our internal
testing.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2980 542714f4-19e9-0310-aa3c-eee0fc999fb1
2004-03-06 11:29:19 +00:00
Michael Bayne d618d3c771 Eclipse suggested cleanup.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2971 542714f4-19e9-0310-aa3c-eee0fc999fb1
2004-02-25 14:50:28 +00:00
Michael Bayne 0601c94e42 Cope.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2875 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-11-25 22:35:10 +00:00
Michael Bayne 94e10e81cd Scratch that we can deal with this in DutyPuzzleManager.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2869 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-11-24 18:09:03 +00:00
Michael Bayne 4415472bef Allow that warning to be disabled for duty puzzles.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2868 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-11-24 18:07:58 +00:00
Michael Bayne d06c0fad00 Some debug logging to try to track down the "I entered the puzzle but it
never started and the server eventually gave me the boot."


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2776 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-08-16 00:28:43 +00:00
Ray Greenwell 829f3ad0eb Start transactions outside of the try-finally clause so that if there
is a problem with starting a transaction, we don't get an exception
for failing to commit the transaction.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2712 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-07-16 18:03:30 +00:00
Michael Bayne 81460a9496 Added getGameConfig().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2686 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-29 23:11:23 +00:00
Michael Bayne 13fba9919e Make our AI tick frequency public.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2673 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-21 15:32:29 +00:00
Ray Greenwell 5f515133c3 Chat revamp, phase 2.
- FeedbackMessage has been subsumed into SystemMessage, which now has three
  modes: INFO, FEEDBACK, or ATTENTION.
- Cleaned up methods for sending those system messages.
  - on the server: sendInfo(), sendFeedback(), sendAttention()
  - on the client: displayInfo(), displayFeedback(), displayAttention().


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2635 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-04 02:50:19 +00:00
Ray Greenwell 40afe3cb94 Chat revamp, phase 1.
- Repackaged crowd/chat
- All messages are delivered to the client via ChatMessage messages,
  including tells.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2631 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-03 21:41:33 +00:00
Michael Bayne ae764ca382 Report the game state in GameObject.which().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2610 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-26 23:46:46 +00:00
Michael Bayne ce735b7b69 Make these public so that our delegates can access them. Sigh.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2609 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-26 21:27:18 +00:00
Michael Bayne 2c94e12490 Regenerated DObject definitions with new policy.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2514 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-04-30 22:45:57 +00:00
Michael Bayne 1bf86bf495 Cope with lack of game object in a few methods.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2402 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-04-11 21:29:21 +00:00
Michael Bayne baa595d65c Not to freak out if we don't yet have _playerOids.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2401 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-04-11 21:22:30 +00:00
Michael Bayne 30b02ababe Cleaned up the code to be more sensible.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2344 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-03-27 23:45:04 +00:00
Michael Bayne 5c0879a964 Whoops, spoke to soon. That wasn't really a bug, just a misunderstanding.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2343 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-03-27 23:25:59 +00:00
Michael Bayne 8876bd90e4 Fixed a bug pointed out by Muffy. We love more eyes on the code!
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2342 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-03-27 23:20:55 +00:00
Michael Bayne dec635a9a4 That feller needs to be transient.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2317 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-03-23 02:20:49 +00:00
Ray Greenwell 712d3f8ab5 Two GameConfigs are not equal unless they are of the exact same class.
This was originally in yohoho's PuzzleConfig, but apparently got deleted
a while back, and this is where it should be anyway.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2313 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-03-20 19:50:35 +00:00
Michael Bayne 56b0012782 Use Comparable for the to be removed distributed set key.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2290 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-02-26 17:54:56 +00:00
Michael Bayne 1a0a1c8951 Created a PartyGameConfig interface and rejiggered party game support a
bit to incorporate it.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2261 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-02-12 05:34:53 +00:00
Michael Bayne d02a247d76 Added a which().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2114 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-01-13 18:36:18 +00:00
Walter Korman 183e25307f Catch and report any exceptions game managers may throw while being
ticked.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2094 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-01-03 02:47:33 +00:00
Walter Korman ebd50b80f5 Tick all game managers every five seconds to allow them to engage in any
activity that isn't driven by player actions.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2093 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-01-03 02:35:41 +00:00
Michael Bayne 48823b10f9 More revamped serialization cleanup.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2079 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-20 23:41:27 +00:00
Michael Bayne 41fe126611 Make sure that we remove ourselves as a listener even if our unknown and
untrustable derived class freaks out in gameDidEnd().


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2072 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-16 05:31:00 +00:00
Walter Korman cbbda03e23 Added convenience class to facilitate performing a one-time server-side
action when a game ends.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2071 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-16 05:06:58 +00:00
Walter Korman 96888709ff Not to call addClientObserver() since we extend BasicDirector which
already does that for us.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2063 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 23:55:31 +00:00
Michael Bayne a1e8ffa65a Cancel any game that isn't already over in placeBecameEmpty(), log more
useful info when we abort a game because of a complete no-show.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2008 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-11-29 21:25:37 +00:00
Michael Bayne 5f4108823c Make it easy for derived classes to opt-out of the no show timer; fixed
checkForNoShows() to only claim a partial no-show when one or more players
have not reported readiness.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2006 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-11-29 20:56:06 +00:00
Michael Bayne 779640972d A few things: added support for detecting no-shows after 30 seconds;
no longer call gameDidStart() directly from startGame() but wait for the
game state event to dispatch and then call it;

removed gameDidReset() because no one was using it and it is funny because
it was being called after gameWillStart() and gameDidStart() were already
called and what in the heck would you be doing that wasn't part of the
normal game startup procedure that you didn't already do in
gameWillReset().


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1995 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-11-26 09:12:10 +00:00
Michael Bayne 260c304fbe Report more useful information if an already in-play game is requested to
start.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1895 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-11-05 02:24:42 +00:00
Walter Korman c81cf22659 Don't complain about receiving playerReady() for non-players if the game
is a party game.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1885 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-11-02 01:20:59 +00:00
Walter Korman 5c189fbb14 Added isWinner() and getWinnerIndex().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1855 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-29 02:09:03 +00:00
Walter Korman 883f912a30 Added gameWillEnd(), and GameObject.winners that details the winners of
the game, as assigned by GameManager.assignWinners() when the game ends.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1853 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-27 23:54:32 +00:00
Michael Bayne 31baef425a Director audit: make sure these guys clean up after themselves when the
client logs off.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1846 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-27 22:23:14 +00:00
Michael Bayne 14a313486b Documentation repairs.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1842 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-27 18:49:51 +00:00
Michael Bayne dd912c3d7d Need to use getPlayerSlots() not getPlayerCount().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1825 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-24 19:05:46 +00:00
Michael Bayne 58d33880b1 Added getPlayerSlots() which returns the maximum number of players allowed
in the game and which doesn't choke if called before we have a game
object. Modified code to use it where appropriate.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1824 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-24 18:51:41 +00:00
Walter Korman d46423ea7b Added addPlayerAt(). Don't send gameReady notification to players when
added since it's (at least currently) assumed that the puzzle has already
been created and the player is fully present in the puzzle room.
Sanity-check to disallow adding a player to a game more than once.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1823 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-24 07:01:08 +00:00
Walter Korman ff85d1b284 Oops; make getPlayerCount() public, as it was always intended to be.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1803 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-16 00:19:23 +00:00
Walter Korman 21c599cd0a Revamped the player array in the game object to allow sparse player arrays
that may have one or more null player entries so that party games can
create their game with the maximum number of players they support and can
use the player index as the player's "seat".  Simplified some of the
jockeying we had to do when adding and removing players.  Complexified
some of the turn game management in order to deal properly with the sparse
player arrays.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1802 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-15 23:07:23 +00:00
Walter Korman 7d092846cd Replaced by com.threerings.util.RandomUtil.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1800 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-15 22:46:43 +00:00
Michael Bayne 646696e5d0 Report more useful information in this failure case.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1784 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-07 18:42:21 +00:00
Michael Bayne 37c4f866fd No longer do we set the players in an explicit call to
GameManager.setPlayers(), now it is simply provided as part of the game
config object which is cleaner and makes the information available during
the initialization and permissions checking phases.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1778 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-06 00:53:15 +00:00
Michael Bayne 939e4ce5a9 Enhanced logging.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1776 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-06 00:44:16 +00:00
Michael Bayne e26fd18b38 Brevity is the soul of a happy log file.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1770 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-10-03 17:16:15 +00:00
Michael Bayne 6c9c3d82f0 Changed service field to gameService; added code to clear out game service
registration when game goes away.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1726 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-09-20 04:53:42 +00:00