comparison rlgterm.js @ 118:56a756695740

rlgterm.js: display the game's proper name when starting.
author John "Elwin" Edwards <elwin@sdf.org>
date Mon, 23 Jul 2012 09:32:46 -0700
parents d7d7cdcba3b4
children 54979d35611a
comparison
equal deleted inserted replaced
117:c08717cb7793 118:56a756695740
777 }; 777 };
778 ws.onmessage = function (event) { 778 ws.onmessage = function (event) {
779 var msgObject = JSON.parse(event.data); 779 var msgObject = JSON.parse(event.data);
780 if (msgObject.t == 's') { 780 if (msgObject.t == 's') {
781 termemu.resize(msgObject.h, msgObject.w); 781 termemu.resize(msgObject.h, msgObject.w);
782 message("You are now playing " + msgObject.g + "."); 782 message("You are now playing " + games[msgObject.g].name + ".");
783 } 783 }
784 else if (msgObject.t == 'd') { 784 else if (msgObject.t == 'd') {
785 writeData(msgObject.d); 785 writeData(msgObject.d);
786 } 786 }
787 }; 787 };