Commit Graph

2076 Commits

Author SHA1 Message Date
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 ee9049fe3e Factored out code for events that all shared a name; removed
hand-serialization code for fields which are now handled automatically.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2078 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-20 23:29:04 +00:00
Michael Bayne 70a79f48e9 Bye bye to all the hand-serialization code. Yay!
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2077 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-20 23:28:24 +00:00
Michael Bayne 00baff9000 Handle Object fields by using readObject() and writeObject() to serialize
them assuming they'll contain either a primitive type or an instance of
Streamable.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2076 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-20 23:27:52 +00:00
Michael Bayne a63d7446dd It turns out that we can make protected and private fields accessible to
the object serialization code which means that we can automatically
serialize said data members. Hooray!


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2075 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-20 23:27:12 +00:00
Michael Bayne 2fe2311e06 We override serialVersionUID in ComponentClass so we may as well do it in
PriorityOverride as well.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2074 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-19 21:44:12 +00:00
Ray Greenwell 822dabef8c added a way to remove observers
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2073 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-18 23:14:23 +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
Michael Bayne 6b273dbf0a Finished up custom render order support.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2070 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-16 03:08:39 +00:00
Walter Korman 3807953a55 Added MediaPanel.clearAnimations(), fixed up comments and removed
unnecessary SpriteManager.clearSprites().


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2069 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-15 23:12:37 +00:00
Michael Bayne b35f81cb62 A little more analysis revealed that we can avoid attempting to resume a
user's session if their client object is not yet resolved. When it does,
their session will be "started" for the first time and everything will
work itself out.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2068 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-15 18:32:19 +00:00
Michael Bayne aeab40a411 Let's be using the same code to enter a scene.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2067 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-14 01:51:00 +00:00
Walter Korman 1c4503efe5 Added toString(DisplayMode).
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2066 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-13 04:37:27 +00:00
Michael Bayne 90b76f1417 Added a toArray() method.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2065 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-13 02:07:27 +00:00
Walter Korman 90a919720a Removed code to disallow adding an observer more than once since the
observer list now takes care of that.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2064 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 23:56:36 +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
Walter Korman ce8fe382a3 Use observer lists, and remove code to disallow adding observers more than
once since the observer list now takes care of that.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2062 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 23:54:27 +00:00
Walter Korman 3d2e98f7da Fixed typo in comments. Tried to resist due to negligibility of typo, but
the perfectionist in me got the better of, me.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2061 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 22:27:25 +00:00
Michael Bayne d6f5a4da4d Added support for fully qualified translation messages which will be
fetched from the message bundle embedded in the fully qualified key even
if they are being translated within the context of another message bundle.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2060 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 22:24:51 +00:00
Michael Bayne df30c37892 Log a more informative message when we catch an exception.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2059 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 19:00:25 +00:00
Michael Bayne d79a6970e1 Need a package qualifier because this config file is meant to be
overridden.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2058 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 18:36:13 +00:00
Michael Bayne 8d5ba037f1 Added necessary jockeying to cause ant not to freak out if JAVA_LIBS is
not set.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2057 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 07:30:18 +00:00
Michael Bayne 18c7b2cf6f Complain loudly about listeners or subscribers that try to add themselves
more than once. Use testAndAddEqual() where appropriate now that
testAndAdd() doesn't use object equality.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2056 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-12 00:30:47 +00:00
Walter Korman 1b27d90286 Initial version of runtime miso scene business.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2055 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-11 23:07:21 +00:00
Walter Korman 2fde0b7117 Made to implement the RuntimeSpotScene interface as was surely intended.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2054 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-11 23:06:24 +00:00
Walter Korman 3ccbb4ad5b Whitespace change.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2053 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-11 23:05:07 +00:00
Michael Bayne 26065cef4a A test sound.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2052 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-10 21:37:10 +00:00
Michael Bayne 64ab1e11ae Got the sound manager test app mostly working again.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2051 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-10 21:36:53 +00:00
Michael Bayne a2c3741b2b A few things:
- Use Constant objects for the command constants because the toString()
output on those is more sensible.

- Fall back to the classpath if we don't find our resource in a bundle

- Don't make the sound manager thread a daemon thread as it provides a
  shutdown() which is a more civilized way to make it go away anyhow and
  allows the sound manager to be used in one-shot tools and test
  programs. At the moment, the sound manager (on Linux at least) seems to
  start up some threads that refuse to go away anyway but that's a problem
  for another time.

- Report if a command is queued up that we don't know about.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2050 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-10 21:36:33 +00:00
Michael Bayne 8943daf060 Revamped frame test to use new nio-based framing services.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2049 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-10 19:38:56 +00:00
Michael Bayne fd9a06a388 We don't need a SocketChannel. A ReadableByteChannel will suffice.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2048 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-10 19:33:22 +00:00
Michael Bayne 26ed72d109 Report an error rather than NPEing if we resume a session with a null
_clobj.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2047 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-09 17:19:04 +00:00
Michael Bayne 3b09893292 The end of more font hackery.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2046 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-09 05:13:45 +00:00
Walter Korman 100739bff5 Removed font hackery now that we've understood and fixed the "font bug",
which turned out to be due to improper restoring of the anti-aliasing
setting in graphics contexts.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2045 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-09 05:00:48 +00:00
Walter Korman 8ef2721d73 Fixed javadoc typo.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2044 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-09 04:44:33 +00:00
Walter Korman ee83234bee Removed unused imports.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2043 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-09 04:42:54 +00:00
Michael Bayne 5e81502af3 Track and report our average number of dirty regions per tick.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2042 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-08 02:49:53 +00:00
Michael Bayne 8ab0623a9c Refuse to allow a frame participant to be added more than once; enhanced
FPS display, made it possible for frame participants to add to the
performance status string. Also modified perf status to be double
buffered. It's not repainting exactly properly at the moment; soon to be
remedied.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2041 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-08 02:49:12 +00:00
Michael Bayne 42110dc8da Remove invocation receiver mappings from the receivers table when they are
unregistered. Flush invocation listener mappings after an expiry period if
they were not already removed by virtue of receiving a response.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2040 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-08 02:18:50 +00:00
Michael Bayne 6caca5fe5a Added code to easily disable the sound manager.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2039 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 22:41:10 +00:00
Michael Bayne d60e6a69d8 Implemented code to handle the rather complicated circumstance of not
being able to send a message immediately to the client due to it being too
large or the client's outgoing networking buffer being full for some other
reason (many messages sent very quickly or client that's reading messages
slowly).

I still need to add code to disconnect a client who fails to read messages
in a sufficiently timely manner.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2038 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 22:33:04 +00:00
Walter Korman 53d4108602 Added temporary fringe debug logging so that we can assess time and memory
usage.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2037 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 02:30:37 +00:00
Walter Korman e45ba41b0f Realized that the icon manager is caching icon tilesets, not icons
themselves, and accordingly dramatically reduced the cache size and fixed
comment.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2036 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 02:13:00 +00:00
Walter Korman eda77a227d Use an LRUHashMap to cache icons.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2035 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 02:09:45 +00:00
Walter Korman acaf39b070 Estimate memory usage in bytes rather than pixel area, assuming an int per
pixel for now.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2034 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 02:04:32 +00:00
Walter Korman ea545bcb66 Log the size of the cache along with its efficiency.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2033 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 01:10:25 +00:00
Walter Korman be34314e1a Report image cache performance in all relevant places.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2032 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 01:00:58 +00:00
Walter Korman 8c5d490b53 Use an LRUHashMap to cache images, and limit caching to 30 images.
Periodically log cache efficiency and estimated image size.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2031 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 00:58:00 +00:00
Michael Bayne 1558a6ec57 Throttle our action cache performance reports to once every 30 seconds.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2030 542714f4-19e9-0310-aa3c-eee0fc999fb1
2002-12-07 00:49:36 +00:00