Hi, Imagine you have a program that contains information on an entity called a Player. There can be lots of Players, say a thousand of them. Players have 20 or so attributes, two of them are an X and Y position. The Players'' attributes are updated many times per second. Now imagine you need to create a web app that shows a 2D overhead display of the all the Players. A grid should be drawn over the Players (representing latitude, or feet from the origin, or something). The web app''s user can zoom in and out and can move around in the world. The user should also be able to select a Player and view its information. Would Rails be a good choice for such an application? Or would you want to use Flash? Or something else? If Rails, I''m thinking something similar to how Google Maps works. Joe
On 6/28/06, Joe Van Dyk <joevandyk@gmail.com> wrote:> Hi, > > Imagine you have a program that contains information on an entity > called a Player. There can be lots of Players, say a thousand of > them. Players have 20 or so attributes, two of them are an X and Y > position. The Players'' attributes are updated many times per second. > > Now imagine you need to create a web app that shows a 2D overhead > display of the all the Players. A grid should be drawn over the > Players (representing latitude, or feet from the origin, or > something). The web app''s user can zoom in and out and can move > around in the world. The user should also be able to select a Player > and view its information. > > Would Rails be a good choice for such an application? Or would you > want to use Flash? Or something else? If Rails, I''m thinking > something similar to how Google Maps works.Oh, also the display should be updated once every 2-5 seconds or so. The Players should move around on the overhead display.
On Wed Jun 28, 2006 at 10:53:03PM -0700, Joe Van Dyk wrote:> Hi, > > Imagine you have a program that contains information on an entity > called a Player. There can be lots of Players, say a thousand of > them. Players have 20 or so attributes, two of them are an X and Y > position. The Players'' attributes are updated many times per second. > > Now imagine you need to create a web app that shows a 2D overhead > display of the all the Players. A grid should be drawn over the > Players (representing latitude, or feet from the origin, or > something). The web app''s user can zoom in and out and can move > around in the world. The user should also be able to select a Player > and view its information. > > Would Rails be a good choice for such an application? Or would you > want to use Flash?i''d proably use TkPath (or GlimR in a few weeks). unless the requirement was run in a browser, then the <canvas> widget or even plain divs..
On 6/28/06, carmen <_@whats-your.name> wrote:> On Wed Jun 28, 2006 at 10:53:03PM -0700, Joe Van Dyk wrote: > > Hi, > > > > Imagine you have a program that contains information on an entity > > called a Player. There can be lots of Players, say a thousand of > > them. Players have 20 or so attributes, two of them are an X and Y > > position. The Players'' attributes are updated many times per second. > > > > Now imagine you need to create a web app that shows a 2D overhead > > display of the all the Players. A grid should be drawn over the > > Players (representing latitude, or feet from the origin, or > > something). The web app''s user can zoom in and out and can move > > around in the world. The user should also be able to select a Player > > and view its information. > > > > Would Rails be a good choice for such an application? Or would you > > want to use Flash? > > i''d proably use TkPath (or GlimR in a few weeks). unless the requirement was run in a browser, then the <canvas> widget or even plain divs..Yeah -- it should be in a web browser (IE 6 or Firefox 1.0 - 1.5).
Joe Van Dyk wrote:> Would Rails be a good choice for such an application? Or would you > want to use Flash? Or something else? If Rails, I''m thinking > something similar to how Google Maps works.I think your difficulty in this would be the client-server nature of a web browser / server relationship. If you code properly, you could probably do it with a combination of Rails and AJAX. If you have to update all of the information in 2-5 second intervals, your primary concern is going to be round-tripping the communication. You may be able to break it up into more frequent calls of a smaller number of objects (though I doubt data transfer is going to be the main issue). Even on a quick broadband connection to a quick server, a page load round-trip will be within the timeframe you''re looking at. Worst case scenario, try it...it should take a little less than a weekend to mock it up in Rails. If it looks good, then refactor the sucker and make it production code. :) -Curtis
On 29-jun-2006, at 8:18, Joe Van Dyk wrote:>> > Would Rails be a good choice for such an application? Or would you >> > want to use Flash? >> >> i''d proably use TkPath (or GlimR in a few weeks). unless the >> requirement was run in a browser, then the <canvas> widget or even >> plain divs.. > > Yeah -- it should be in a web browser (IE 6 or Firefox 1.0 - 1.5).Flash + XML messaging without polling. Otherwise requests with 2-5 second delay might swamp the server (but what You will employ on the server depends on how much concurrency you will be handling). From Rails you can trivially message the Flash movie with xml packets in the style of: <player id="x" x="120" y="130" /> and then parse it on the Flash side and move the elements. -- Julian ''Julik'' Tarkhanov please send all personal mail to me at julik.nl