Commit graph

29 commits

Author SHA1 Message Date
John "Elwin" Edwards
b34eeb2de8 RLG-Web client: some visual improvements.
Hide the debugging messages by default.
2012-06-20 14:11:57 -07:00
John "Elwin" Edwards
2d9c8bd011 Display idle time of games in progress.
statusmsg() now includes games' idle times, and the client displays
them using getcurrent().
2012-06-20 11:37:05 -07:00
John "Elwin" Edwards
f750d9eb34 RLG-Web client: refresh the current games list.
Add a refresh button to the list of watchable games.  Also refresh it
if watching fails.
2012-06-20 09:12:26 -07:00
John "Elwin" Edwards
f711cdb591 Some status improvements.
Status messages now consistently use the game's uname, and the table
of choices puts the games in the right order.
2012-06-20 08:49:10 -07:00
John "Elwin" Edwards
4c27e44ef8 RLG-Web client: adjust polling for watching.
The ajaxterm state machine assumed data appears in response to user
actions, which is not true when watching.  It now uses different sets
of parameters for playing and watching.
2012-06-20 07:41:59 -07:00
John "Elwin" Edwards
0e31c3a3b7 RLG-Web client: initialize and restore the terminal when watching.
Since watchers might not get the curses initialization and ending
sequences, the terminal emulator needs to be set up for and restored
after watching.
2012-06-19 20:08:05 -07:00
John "Elwin" Edwards
67f187700c RLG-Web client: implement watching.
It is now possible to watch games currently being played through
RLG-Web, but not dgamelaunch.  Also, there are some deficiencies, like
getting chaos until an absolute cursor addressing happens.
2012-06-19 16:19:50 -07:00
John "Elwin" Edwards
553f07360c Move credentials into the drivers.
The session id, or whether the session is currently active on the
server, are better handled in the drivers than in termemu.js.
2012-06-19 13:40:30 -07:00
John "Elwin" Edwards
ceed48eee5 RLG-Web client: explain when there are no games to watch
If no games are available for watching, display a message saying so
instead of showing an empty table.
2012-06-18 16:53:44 -07:00
John "Elwin" Edwards
2bdd26b2f4 RLG-Web client: display a list of current games.
Incorporate information from /status to create a list of ongoing games.
Eventually these will be watchable.
2012-06-18 14:30:05 -07:00
John "Elwin" Edwards
1ffb72866a RLG-Web: make multiple watchers possible.
Split the TermSession class into the new TermSession, which handles the
PTY, and client classes, which handle HTTP sessions.  These are Player
and Watcher.  This allows multiple watchers per game, and other
improvements.
2012-06-18 13:43:51 -07:00
John "Elwin" Edwards
17159bf823 rlgterm.js: don't make nonfunctional button.
The "Game in progress" text shouldn't look like a button, because
clicking it doesn't do anything.
2012-06-11 14:04:35 -07:00
John "Elwin" Edwards
20d72fc066 RLG-Web: make login sessions time out.
After enough inactivity, log the user out automatically.
2012-06-09 21:20:14 -07:00
John "Elwin" Edwards
aba0a4b7da rlgterm.js: make the options table functional.
Enable launching games from the options table, and replace the old
select dialog.
2012-06-09 17:00:25 -07:00
John "Elwin" Edwards
d3abfbcea9 RLG-Web: put the game options into a table.
Create a nice table of options when the player logs in.
2012-06-09 15:22:56 -07:00
John "Elwin" Edwards
2e35e55925 rlgterm.js: present game options to the player.
Use the new player-status interface to display the state of any ongoing
games when the player logs in.
2012-06-09 14:13:07 -07:00
John "Elwin" Edwards
7e88c7cdc3 rlgterm.js: fix failure to recognize end of game
The RLG-Web client was failing to realize the game was over, because
a test was checking against the entire response instead of the proper
field in the response.
2012-06-09 10:44:11 -07:00
John "Elwin" Edwards
012c86faa8 RLG-Web: separate logging in and starting a game.
The user now logs in with a username and password, receiving a token
which is then used for any actions requiring authentication.  Starting
a game is one such action.  Games use a different set of id keys.
This allows users to supply their passwords once and then play any
number of successive games.  Also, newly registered users do not need
to supply their passwords again.
2012-06-07 15:43:06 -07:00
John "Elwin" Edwards
94e9fa330c RLG-Web: reduce polling further.
The ajaxstate object now reduces polling to 15-second intervals and
stops entirely after one minute.
2012-06-06 10:53:29 -07:00
John "Elwin" Edwards
520226a343 rglterm.js: reduce the server polling.
For roguelike games, most output will directly result from and follow
immediately after input from the user.  In other situations, data
should not be expected.
2012-06-05 22:33:41 -07:00
John "Elwin" Edwards
d0e3b1da2f rlgwebd.js: read commands from the console
The RLG-Web server can now be controlled with commands sent to stdin.
Currently, the only one implemented is "quit".  Some improvements to
the shutdown process were also made.
2012-06-04 14:21:41 -07:00
John "Elwin" Edwards
c1856a6184 Fix some typos.
Some code copied and pasted without updating the variable names was
causing crashes.
2012-05-23 14:28:47 -07:00
John "Elwin" Edwards
018adf9acf RLG-Web client: some cleanup
Separate RLG-specific CSS into its own file, fix some typos.
2012-05-23 07:46:08 -07:00
John "Elwin" Edwards
e36f058daf RLG-Web: add user registration
Update the server and client sides of RLG-Web to make use of the new
registration feature of sqlickrypt.
2012-05-22 20:54:33 -07:00
John "Elwin" Edwards
94f8630eb4 RLGWeb: switch to JSON protocol.
Port the JSON communication from WebTTY to RLGWeb.  Fixing out-of-order
messages is still not implemented on the server side.  Terminal size is
still hard-coded.  Unused code is still lying around.
2012-05-17 09:32:19 -07:00
John "Elwin" Edwards
02cc454ad1 Make the emulator screen resizable. 2012-05-09 13:38:05 -07:00
John "Elwin" Edwards
f40a08f3ef Put common key tables into a common file. 2012-05-07 13:08:24 -07:00
John "Elwin" Edwards
ed87e67faa Client: don't assume the terminal is 24x80. 2012-05-07 11:09:14 -07:00
John "Elwin" Edwards
8dec6dff87 Put this project under version control, finally. 2012-05-06 08:45:40 -07:00