Commit Graph

2477 Commits

Author SHA1 Message Date
Ray Greenwell d1e2c532e4 Fixed typo with previous checkin. Must get sleep.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2640 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-05 00:33:43 +00:00
Ray Greenwell 7dd942b673 Start out the ping interval id at -1 so we can tell if it needs to be
unregistered.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2639 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-05 00:29:45 +00:00
Ray Greenwell 6cb3d605d7 Be sure to unregister the interval, even if the the reader exits before
we logoff.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2638 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-05 00:26:16 +00:00
Michael Bayne 10f5536a6a Not to create a key every time we do a lookup. Only create a key when we
know we're adding a new entry.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2637 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-04 22:00:59 +00:00
Ray Greenwell 35f7f0806b Make sure that the transparent color is first in the colormap so that
Java's png encoder doesn't get confused and merge black pixels into
the transparency.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2636 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-04 05:56:58 +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
Michael Bayne 01b123b9f8 Added some utility methods for selecting a random element from an array or
iteration of known size.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2634 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-04 00:03:58 +00:00
Ray Greenwell 674523b365 Tell feedback message.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2633 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-03 23:46:10 +00:00
Ray Greenwell d3f3995cb7 Allow an optional ResultListener to be passed into requestTell that will
tell us whether or not the tell succeeded.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2632 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-03 23:36:18 +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 368cd940b6 Make all of our object radial menus the same size; having them scale to
the size of the object is not at all useful.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2630 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-02 18:57:15 +00:00
Michael Bayne ba73cc55df Deal as gracefully as possible if we don't have any data for the final
field or fields of a streamed object. This allows us to add new fields to
the end of a streamable without causing all existing serialized versions
to become unreadable.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2629 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-06-02 17:24:18 +00:00
Michael Bayne 73a4a02aa1 A few substantial changes:
- Tiles are initialized after being constructed which makes life simpler
  for custom tiles which no longer have to have their own constructor that
  passes Tile's stuff down to it.

- Tiles are no longer LRU cached (because we blow through that cache
  instantly on all but the smallest of scenes), and are now tracked by
  weak references so that we guarantee that only one instance of a tile is
  ever in memory.

- Added code to track and report memory usage of weak cached tiles as well
  as "stray" tiles which are created through other means than asking a
  TileSet for a tile (fringe tiles being the most prolific example).


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2628 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-31 00:56:38 +00:00
Michael Bayne 6d3d80c58e Keep a rectangle around with our tile coordinate footprint and use that
for overlapping calculations.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2627 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-31 00:52:15 +00:00
Michael Bayne d35e7b8180 Change the default resource directory to .narya so that we can leave the
code in that blows away .naryarsrc without having it constantly conflict
with the tools that we run.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2626 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 16:35:59 +00:00
Ray Greenwell 3f0d839400 Noted that I had changed the QUICK constant to false.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2625 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 03:08:37 +00:00
Ray Greenwell c941c96141 Color reduction algorithm. From web, with modifications to support
transparency.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2624 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 03:02:38 +00:00
Ray Greenwell 99ccd996df Oops, remove these too.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2623 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 01:59:17 +00:00
Ray Greenwell af504ef8aa Added MisoUtil.getTileHash(), made both SceneBlock and AutoFringer use
it to pick random tiles based on x/y location.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2622 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 01:58:06 +00:00
Ray Greenwell bace19ea71 The AutoFringer picks which fringe tile to use next by querying a
Random, instead it relies on a duplicatable hashing method.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2621 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-29 01:04:58 +00:00
Ray Greenwell 5f8309f118 publicized computeTips().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2620 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-28 18:15:26 +00:00
Michael Bayne 41a69ba13f Whoops, that'll need to actually be Streamable.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2619 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-28 01:18:41 +00:00
Ray Greenwell d407253540 Iterate over the entries and save the key and value without having to
look up the value.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2618 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 23:00:22 +00:00
Ray Greenwell 1176ca526e No need to do hash lookups in writeObject().
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2617 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 22:54:36 +00:00
Michael Bayne 5c9a0246d9 A streamable hash map.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2616 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 22:48:31 +00:00
Michael Bayne f6325c5d4c Pass all the object info along when visiting.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2615 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 19:04:29 +00:00
Michael Bayne a5e3752a7b Make it possible to refresh our object tile if we've had our colorizations
changed.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2614 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 18:25:19 +00:00
Michael Bayne acfea90fe4 Make our colorization options available.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2613 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 18:25:04 +00:00
Michael Bayne 79715e61a4 Screw unpacking our bundles on the fly. Just unpack them once when they
are downloaded and leave them be until the bundle is updated.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2612 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 07:52:45 +00:00
Michael Bayne 2d958634c0 Provide a post-download hook that is run on the download manager thread.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2611 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-27 07:51:49 +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 6aba06219d Make where() available to the delegates.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2608 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-26 21:24:56 +00:00
Michael Bayne 8d9b9f69d2 Quick hack to (hopefully) fix weird problem while I investigate.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2607 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-24 01:50:33 +00:00
Michael Bayne 3bacbbe803 More useful debugging information.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2605 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-23 19:35:11 +00:00
Michael Bayne 328f4786ba Report our resolution on the AWT thread rather than the scene block
resolution thread.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2604 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-22 22:18:27 +00:00
Michael Bayne 9ab9a7f84b Let's not freak out, but warn and return -1. This is one of those "should
never happen" things that keeps happening.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2603 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-22 22:18:02 +00:00
Michael Bayne d76d4e89ff Make it possible to have a distributed object destroyed when its last
subscriber is removed.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2602 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-22 17:23:53 +00:00
Michael Bayne 8197441658 Restructure our block visible warning so that derived classes can augment
it as well as inhibit it.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2601 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-22 16:10:54 +00:00
Michael Bayne 0642b97258 Warn if blocks take a long time to resolve; added debug logging to report
a histogram of block load times.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2600 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-21 17:10:41 +00:00
Michael Bayne 768da14b79 Allow derived class to turn off "block visible" warning. More debug
logging to help sort out the blue screen problem.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2599 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-21 17:10:05 +00:00
Michael Bayne 569522fd01 rethink() needs to return the number of "visible" blocks pending; added
code to log when we're not painting for lack of blocks and when we restore
painting so that we can further debug the proverbial blue screen situation.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2598 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-21 15:27:45 +00:00
Michael Bayne 98216ddcbb Account for blocks a bit below our visible bounds because otherwise there
can be serious popping when entire buildings don't come into view until
after we've started displaying.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2597 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-21 00:28:22 +00:00
Michael Bayne bf4142423f That should be debug not info.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2596 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 23:58:27 +00:00
Michael Bayne 5bdf72f615 Differentiate between blocks that are visible and those that probably
aren't (we can't truly know if a block is visible until we resolve it
because objects of arbitrary height can overlap the view bounds even if
the block's footprint does not); resolve the definitely visible ones first
and go ahead and start drawing once the known visible blocks are ready.
This cuts the time spent on the "blue screen" by about 75%.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2595 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 23:57:48 +00:00
Michael Bayne 8e820811bc No reason that embedded translation strings can't also be qualified (it's
quite necessary in fact).


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2594 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 20:58:31 +00:00
Michael Bayne 5bccc8482c Report the computed server/client time differential.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2593 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 19:07:52 +00:00
Ray Greenwell c7908862ff SetAdapter, because SetListener is a pain sometimes.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2592 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 18:41:46 +00:00
Michael Bayne 8c8cd1a2ea Allow the temporary cache directory to be explicitly specified.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2591 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 16:29:36 +00:00
Michael Bayne cb0d7713b5 Use our handy dandy new DelegatingPathable.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@2590 542714f4-19e9-0310-aa3c-eee0fc999fb1
2003-05-20 04:09:13 +00:00