Hi Hilaire
A short note concerning the archetecture of my PicturesInYourHead app.
In interactive fiction the story unfolds depending on the activity of the reader, the reader 'reads', then decides for some response and the next section of text
is presented depending of this response.
In the PicturesInYourHead app. The server may respond on
one Textual channel, two sound channels and three image channels.
The channels may be updated each time the user responds.
Furthermore the authoring platform makes it possible to set up delayed action events on server side.
When such an event occurs one or more channels may have to be updated too.
-------
I knew Smalltalk but had no knowledge of Server or Web architecture, HTML or CSS.
But studying the AIDA architecture and bolts and nuts - ' How is this happening?', 'Can I copy this trick?' i ended up with
the following architecture of the client server interface:
--------
1 Sound channels
The server maintains two queues of soundfiles to play.
Whenever the client observes it has no sound to play/playing it asks the server to deliver one.
This request is set up through a timer controlled ajax (soundhandling itself needed javascript, was not that simple)
I could not use a page refresh, because ongoing playing sounds was then disturbed, (repeated/ truncated/stopped).
2 Image channels
The server will update each channel at each reader response if needed.
I use an Ajax construct for that, so only the Image page elements are updated
because a page refresh would disturb an ongoing sound.
3 Textual channels
This channel is updated through ajax too, to just change this channels element on the page.
4 Delayed events on server side.
This is actually 'COMET' architecture i suppose.
A timed request is repeatedly sent to the server from the client.
And if a delayed event has happened, the server will ask the channels to update the client.
Here is a link to the non web parts of the platform (Warning everything is in danish) ;-)
http://picturesinyourhead.vpweb.dk/many regards
Søren