Closed jkomoros closed 7 years ago
The hardest part is figuring out how to multi-plex /game-src/main-element
At some point in server we need to dispatch to the right manager based on type name.
This will be much easier to play around with and make work once we actually have two example game types.
Then we'll create an examples/metaserver that imports multiples.
Should we include the gamename in the URL? It is useful for people to see in the url they share with friends, and it would allow the route to extract which game renderer to load.
Then just gutcheck the name that comes back with the game is the same the route thinks it will be.
How do I make it so that it can fall back on rendering default content?
Maybe have a render-game-view that does the importHref, but renders default content before that loads.
Also note that if we have more fragments to load, we'll need to list more of them in polymer.json
This is actually now done now that we've captured the two remaining minor things in the two new issues.
Delegate.Name() should return something short and distinct, like "tictactoe" or "tickettoride". Delegate.DisplayName() returns what .Name() returns today. Unique, but pretty.
/api/new/game returns the game ID and its gamename so we can redirect correctly.
NewServer(takes multiple managers. When installed, each one is interrogated for its shortname) to hook those points. They should all use the same storage.
The rendering has /game-src//main-element