Commit Graph

41 Commits

Author SHA1 Message Date
Jamie Doornbos 077c5e8053 At Ray's suggestion, go ahead and throw an error when the wrong type is read. Use the Type(obj) cast syntax (I was unaware that this would actually throw an error). Reading objects of a basic type like Array must still use "readObject(Array) as Array" so this is still supported, though not needed for user types.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5441 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-10-13 17:34:55 +00:00
Jamie Doornbos a3cc67348e Gah, this was part of the implementation, but in the end I took it out but missed the import
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5439 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-10-11 06:21:54 +00:00
Jamie Doornbos e12ff0e9f3 Optional type checking for readObject
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5438 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-10-11 06:06:06 +00:00
Ray Greenwell 76ebba1614 Added readLong and writeLong to our streaming classes.
Use that in PongResponse.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5358 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-09-04 22:21:03 +00:00
Ray Greenwell ec2b50c153 - Changed some stuff around with streaming.
- Before, the Input/OutputStream classes handled Streamables directly
    and Streamers were never created for them. Simplified the code somewhat
    by always creating a Streamer. It's now more like the Java side, too.
  - No more BAD_STREAMER, since null now means "bad".
- Built-in support for streaming enums.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5352 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-09-04 01:27:18 +00:00
Michael Bayne 9674176268 More debugging when debug is activated.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@5255 542714f4-19e9-0310-aa3c-eee0fc999fb1
2008-07-22 18:28:36 +00:00
Ray Greenwell fcdace5589 Some method documentation.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4902 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-12-05 02:25:44 +00:00
Ray Greenwell a920f02030 Found and fixed the "Mother Fucker of a Bug(tm)" that was causing
Zyraxxis to hork.
Deep within our streaming code, ArrayMask objects were being created with
zero length when streaming non-final arrays with a zero length. This tickled
a "feature" of Adobe's IDataInput code, which reads *all available bytes*
if you pass readBytes() a length of 0.
What's really annoying is that this worked fine if you were notified
of the zero-length array via a PropertySetEvent, because that event
would come in on its own frame and so if the array's length was zero then
there were no more bytes to read. But if you entered a game and had
to receive all the usercode properties at once, it booched.
There are clumps of my pulled-out hair all around my desk from that.
And: this is ultimately my own fault, as my old code didn't handle the
case of the passed-in ByteArray having 0 length.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4900 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-12-05 02:09:59 +00:00
Ray Greenwell 376f5e680a Sorry, Log, no more free ride for you.
Putting you at the top level screws up use of another Log class.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4874 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-11-13 09:30:23 +00:00
Michael Bayne 84855f8fe0 Enhanced debuggery, reenabled new streaming bits because now they should really
really work.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4705 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-05-09 01:17:13 +00:00
Michael Bayne 80f242616e Final refactor bits.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4677 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-05-01 22:42:22 +00:00
Michael Bayne 09f0bee0f3 Yet more header patrol.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4602 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-02-24 00:39:27 +00:00
Ray Greenwell 789fe8e433 Found the streaming bug:
I was looking up streamers by java name, but passing in the actionscript
name. This was only affecting Object[]'s containing String elements
due to the addition of String to Translations.

Previously, 'java.lang.String' wasn't getting translated into the
actionscript equivalent, so it just worked. Two bugs can cancel each other out.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4567 542714f4-19e9-0310-aa3c-eee0fc999fb1
2007-02-12 21:29:57 +00:00
Ray Greenwell 0650d58006 Improved the debug-mode logging a bit.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4384 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-09-27 23:54:09 +00:00
Ray Greenwell 608be4557b Some changes required for the new compiler.
- Import bleeding may be fixed, as I had to import a bunch of things I
  should have had to earlier.
- NOW they make duplicate variable definitions bad (but without block
  scoping... yay).
- Another hoopjump.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4233 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-06-28 22:04:19 +00:00
Ray Greenwell a442646791 Supress extra debuggy logging.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4169 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-06-02 02:22:11 +00:00
Ray Greenwell a22ca8b079 Simplified logging facilities.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4131 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-19 22:47:44 +00:00
Ray Greenwell 64e87bb907 Added the keys() function to the Map interface, replaced instances of
SimpleMap with HashMap. Discarded SimpleMap.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4122 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-16 21:06:06 +00:00
Ray Greenwell d123c61606 Use the ArrayStreamer to stream regular Arrays as well.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4113 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-11 23:58:21 +00:00
Ray Greenwell fe3350dc3c More streaming fixups.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4106 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-10 02:35:01 +00:00
Ray Greenwell b82108ecea Streaming fixups on the path towards getting things working in beta3.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4105 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-10 00:40:15 +00:00
Ray Greenwell e100ef4faf Updated to match API changes in Beta3.
InvocationRegistration had a constructor called Registration. I wonder if
that was causing the compile error with beta2.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4104 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-05-09 23:03:47 +00:00
Ray Greenwell 64d7f32178 Lots of debug logging, some casting.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@4001 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-04-06 20:05:28 +00:00
Ray Greenwell 16a28de8bc Report from brown team, engaged in Operation Slam Your Dick in a Door:
"Still purple and bruised, sir!"

I'm working around more bugs. In theory everything should log in and join
the chat room, but the browser crashes- every single time.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3986 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-28 23:17:52 +00:00
Ray Greenwell 90e4017801 A bit more, more streaming issues. I might need to rework some stuff.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3985 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-28 02:02:22 +00:00
Ray Greenwell 4a1fdbbbe8 A few things, now that I'm running again (I downgraded to the older beta).
I'm now pounding my head against new limitations that I'd not seen before, now
that the Client class that I'm using is not in the presents.client package.
Macromedia can go fuck themselves with a hot poker.
The .swf is already 200k and I've barely begun working on UI elements.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3972 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-24 02:28:26 +00:00
Ray Greenwell 7d3ef496fd More faffing about.
- started making chat UI stuff
- upgraded SimpleMap some to use the new Dictionary class
- Lots of experimenting with attaching functions to interface implementations.
I've upgraded to the new beta of Flex and it's giving me the pain. There's
new compiler bugs and I am working blind right now.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3966 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-22 02:10:37 +00:00
Ray Greenwell b82b079469 It seems that Array streaming now works.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3924 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-08 03:28:09 +00:00
Ray Greenwell d8276bb4a9 More crap, some new discoveries, backtracking, annoyance.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3918 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-07 03:49:33 +00:00
Ray Greenwell a75f496e76 Checkpoint.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3912 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-04 02:43:14 +00:00
Ray Greenwell cec3ffe59d Fixed up some things and added streaming translations.
I'm to the point where I need to go back to array streaming and straighten
that out.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3905 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-03-02 03:44:37 +00:00
Ray Greenwell 465b680aa2 Fixed some bugs with reading data back from the server, including
subtracting 4 from the length of the frame and fixing the reading
of fields for which we have a basic streamer.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3885 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-23 22:22:57 +00:00
Ray Greenwell ea0a3dce06 Well, it compiles.
It's not functional, there are still large holes in the implementation.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3868 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-20 03:53:04 +00:00
Ray Greenwell 7a80c5cb43 Got compiling working under Linux, now correcting various errors.
Checkpoint.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3866 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-20 02:38:56 +00:00
Ray Greenwell 7a353e6722 Checkpoint.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3864 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-19 23:35:22 +00:00
Ray Greenwell bb379347f0 The readField()/writeField() methods are for marshalling objects that have
basic streamers defined for them (String, Integer, Boolean) and not
other arbitrary objects.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3863 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-19 03:19:54 +00:00
Ray Greenwell 97953e7668 More progress.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3862 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-18 02:37:14 +00:00
Ray Greenwell 74c35b6d65 More progress.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3861 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-17 05:11:31 +00:00
Ray Greenwell 1d36299e3c Some work on streaming.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3855 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-15 01:41:14 +00:00
Ray Greenwell 4d7fb64b8c More progress.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3849 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-14 04:07:02 +00:00
Ray Greenwell 3f9c6c6081 Beginnings of the ActionScript 3.0 client: checkpoint checkin.
There's a long way to go and I think I need to rethink the way streaming
will work, but this is a start. These classes all compile under
the flex environment.


git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@3842 542714f4-19e9-0310-aa3c-eee0fc999fb1
2006-02-09 03:33:58 +00:00