From 0c641423facc7dd30587c91fc4550464d65d0990 Mon Sep 17 00:00:00 2001 From: "marcins78@gmail.com" Date: Tue, 4 Oct 2011 19:02:41 +0000 Subject: [PATCH] Added game manual. The "Card information" window will be bigger by default. In cases of most screen sizes it should be enough to see the whole card without scrolling window. --- .../com/gempukku/lotro/chat/ChatRoom.java | 2 +- .../src/main/webapp/includes/changeLog.html | 3 + .../src/main/webapp/includes/instruction.html | 2 + .../src/main/webapp/js/gameUi.js | 87 ++++++++++--------- 4 files changed, 51 insertions(+), 43 deletions(-) diff --git a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/chat/ChatRoom.java b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/chat/ChatRoom.java index 9fe022633..107b9f0b6 100644 --- a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/chat/ChatRoom.java +++ b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/chat/ChatRoom.java @@ -3,7 +3,7 @@ package com.gempukku.lotro.chat; import java.util.*; public class ChatRoom { - private int _maxMessageHistoryCount = 50; + private int _maxMessageHistoryCount = 150; private LinkedList _lastMessages = new LinkedList(); private Map _chatRoomListeners = new HashMap(); diff --git a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html index a45d6d724..020d75af8 100644 --- a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html +++ b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/changeLog.html @@ -5,6 +5,9 @@ - Added cards from sets 02 and 03 ("Mines of Moria" and "Realm of the Elf Lords"). - I think I finally found and fixed the problem that caused the wounds not to be displayed sometimes on the client, even though after page reload (F5) they were showing up. +- Added game manual. +- The "Card information" window will be bigger by default. In cases of most screen sizes it should be enough to see the +whole card without scrolling window. 26 Sept. 2011 - Changed the cost-to-effect actions to follow the "do as much as possible" route, rathern than can/can't do. diff --git a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/instruction.html b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/instruction.html index a925d170a..1e6da21b0 100644 --- a/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/instruction.html +++ b/gemp-lotr/gemp-lotr-web/src/main/webapp/includes/instruction.html @@ -1,5 +1,7 @@

Manual

+

Courtesy of Drachu84

+

GEMP-Lotr is an automatic game client for the Lord of the Rings Tradable Card Game. Below you will find basic information about using it.

diff --git a/gemp-lotr/gemp-lotr-web/src/main/webapp/js/gameUi.js b/gemp-lotr/gemp-lotr-web/src/main/webapp/js/gameUi.js index 1387209de..bb566300c 100644 --- a/gemp-lotr/gemp-lotr-web/src/main/webapp/js/gameUi.js +++ b/gemp-lotr/gemp-lotr-web/src/main/webapp/js/gameUi.js @@ -265,21 +265,21 @@ var GempLotrGameUI = Class.extend({ initializeDialogs: function() { this.smallDialog = $("
") .dialog({ - autoOpen: false, - closeOnEscape: false, - resizable: false, - width: 400, - height: 200 - }); + autoOpen: false, + closeOnEscape: false, + resizable: false, + width: 400, + height: 200 + }); this.cardActionDialog = $("
") .dialog({ - autoOpen: false, - closeOnEscape: false, - resizable: true, - width: 600, - height: 300 - }); + autoOpen: false, + closeOnEscape: false, + resizable: true, + width: 600, + height: 300 + }); var that = this; @@ -289,17 +289,20 @@ var GempLotrGameUI = Class.extend({ $(".ui-dialog-titlebar-close").hide(); + var width = $(window).width(); + var height = $(window).height(); + this.infoDialog = $("
") .dialog({ - autoOpen: false, - closeOnEscape: true, - resizable: true, - title: "Card information", - minHeight: 80, - minWidth: 200, - width: 600, - height: 300 - }); + autoOpen: false, + closeOnEscape: true, + resizable: true, + title: "Card information", + minHeight: 80, + minWidth: 200, + width: Math.max(600, width * 0.75), + height: Math.max(300, height * 0.75) + }); var swipeOptions = { threshold: 20, @@ -592,9 +595,9 @@ var GempLotrGameUI = Class.extend({ else if (zone == "DISCARD") $("#discard" + this.getPlayerIndex(playerId)).text("Discard: " + count); else if (zone == "DEAD") - $("#deadPile" + this.getPlayerIndex(playerId)).text("Dead pile: " + count); - else if (zone == "DECK") - $("#deck" + this.getPlayerIndex(playerId)).text("Deck: " + count); + $("#deadPile" + this.getPlayerIndex(playerId)).text("Dead pile: " + count); + else if (zone == "DECK") + $("#deck" + this.getPlayerIndex(playerId)).text("Deck: " + count); }, playerPosition: function(element) { @@ -753,7 +756,7 @@ var GempLotrGameUI = Class.extend({ if (index != -1) cardData.attachedCards.splice(index, 1); } - ); + ); var card = $(".card:cardId(" + cardId + ")"); var cardData = card.data("card"); @@ -874,7 +877,7 @@ var GempLotrGameUI = Class.extend({ if (index != -1) cardData.attachedCards.splice(index, 1); } - ); + ); } card.remove(); @@ -946,13 +949,13 @@ var GempLotrGameUI = Class.extend({ this.smallDialog .html(text + "
") .dialog("option", "buttons", - { - "OK": function() { - $(this).dialog("close"); - that.decisionFunction(id, $("#integerDecision").val()); - } - } - ); + { + "OK": function() { + $(this).dialog("close"); + that.decisionFunction(id, $("#integerDecision").val()); + } + } + ); $("#integerDecision").SpinnerControl({ type: 'range', typedata: { @@ -984,13 +987,13 @@ var GempLotrGameUI = Class.extend({ this.smallDialog .html(html) .dialog("option", "buttons", - { - "OK": function() { - $(this).dialog("close"); - that.decisionFunction(id, $("#multipleChoiceDecision").val()); - } - } - ); + { + "OK": function() { + $(this).dialog("close"); + that.decisionFunction(id, $("#multipleChoiceDecision").val()); + } + } + ); this.smallDialog.dialog("open"); }, @@ -1239,8 +1242,8 @@ var GempLotrGameUI = Class.extend({ $(div).find('LI.hover').removeClass('hover'); $(this).parent().addClass('hover'); }).mouseout(function() { - $(div).find('LI.hover').removeClass('hover'); - }); + $(div).find('LI.hover').removeClass('hover'); + }); var getRidOfContextMenu = function() { $(div).remove();