diff --git a/build.ant.properties b/build.ant.properties index 705308a864..ed4c7b784a 100644 --- a/build.ant.properties +++ b/build.ant.properties @@ -73,7 +73,7 @@ version_server = http://arianne.sourceforge.net/stendhal.version # current version of stendhal version.old = 0.84 -version = 0.84.5 +version = 0.85 # javac options javac.deprecation = true diff --git a/doc/CHANGES.txt b/doc/CHANGES.txt index 633ec3d2b8..b45034baf0 100644 --- a/doc/CHANGES.txt +++ b/doc/CHANGES.txt @@ -3,20 +3,37 @@ Changelog 0.85 *features* +- all gui components use a new wood panel theme (even ones which did not have wood before) +- character selection dialog after account login +- login profiles can be cleaned up - right click and 'Where' yourself -- experimental /listproducers command for working NPCs +- /listproducers command for working NPCs - quest to help Phalk with food and clothes -- a script for calculating item drop rarities -- actually slow down when walking over resisting entities -- raid creatures no longer have attack weakest profile even if the - creature normally would +- slow down when walking over resisting entities +- take resistance into consideration when choosing path +- use more karma at the well and count activities +- added descriptions to some npcs +- new npc in ados church +- new tutorial messages for receiving items and private messages +- can turn around on spot using mouse wheel +- rats in semos village are not cowards *code* - players can't use npc names or creature names - cannot add buddy who doesn't exist - refactored Kanmararn Soldiers quest -- style code completely rewritten as a swing look & feel, and extended to - all components used by stendhal +- style code completely rewritten as a swing look & feel, and extended to all components used by stendhal +- a script for calculating item drop rarities +- quests history refactored to not use xml +- many semos npcs reverted to not use xml for configuration + +*bugfixes* +- upper part of grain is not counted as grain (can move between grain fields) +- raid creatures no longer have attack weakest profile even if the creature normally would +- weekly item quest xp reward +- quest completed check where completed state is set to other than 'done' +- initial Hayunn dialog/tutorial cleaned up + 0.84 *features* diff --git a/libs/marauroa.jar b/libs/marauroa.jar index 0a5f14176c..14296dc374 100644 Binary files a/libs/marauroa.jar and b/libs/marauroa.jar differ diff --git a/runserver.bat b/runserver.bat index 9476a84ce2..d5496613d0 100644 --- a/runserver.bat +++ b/runserver.bat @@ -1,3 +1,3 @@ -set STENDHAL_VERSION=0.84.5 +set STENDHAL_VERSION=0.85 set LOCALCLASSPATH=.;data\script;data\conf;stendhal-server-%STENDHAL_VERSION%.jar;marauroa.jar;mysql-connector.jar;log4j.jar;commons-lang.jar;h2.jar java -Xmx400m -cp "%LOCALCLASSPATH%" marauroa.server.marauroad -c server.ini -l diff --git a/runserver.sh b/runserver.sh index 79be2b8de3..1a422d3540 100644 --- a/runserver.sh +++ b/runserver.sh @@ -1,5 +1,5 @@ #!/bin/sh -STENDHAL_VERSION="0.84.5" +STENDHAL_VERSION="0.85" LOCALCLASSPATH=.:data/script/:data/conf/:stendhal-server-$STENDHAL_VERSION.jar:marauroa.jar:mysql-connector.jar:log4j.jar:commons-lang.jar:h2.jar diff --git a/src/games/stendhal/client/actions/HelpAction.java b/src/games/stendhal/client/actions/HelpAction.java index 553ee53c0e..9d8a6dc316 100644 --- a/src/games/stendhal/client/actions/HelpAction.java +++ b/src/games/stendhal/client/actions/HelpAction.java @@ -34,6 +34,7 @@ class HelpAction implements SlashAction { "- /sentence \tWrites the sentence that appears on Website.", "* Items: ", "- /drop [quantity] \tDrop a certain number of an item", + "- /listproducers\tFind out what items are being produced for you", "* Buddies and Enemies: ", "- /add \tAdd to your buddy list", "- /remove \tRemove from your buddy list", diff --git a/src/games/stendhal/client/gui/wt/GroundContainer.java b/src/games/stendhal/client/gui/wt/GroundContainer.java index d80ae95dd5..e658f078aa 100644 --- a/src/games/stendhal/client/gui/wt/GroundContainer.java +++ b/src/games/stendhal/client/gui/wt/GroundContainer.java @@ -421,7 +421,7 @@ public class GroundContainer extends WtBaseframe implements WtDropTarget, Inspec * Turning with mouse wheel. Ignore all but the first to avoid flooding * the server with turn commands. */ - if (e.getClickCount() == 1) { + if (e.getClickCount() <= 1) { Direction current = User.get().getDirection(); if (e.getUnitsToScroll() > 0) { // Turn right diff --git a/src/games/stendhal/client/stendhal.java b/src/games/stendhal/client/stendhal.java index 0ec192f9d5..6e073d6af9 100644 --- a/src/games/stendhal/client/stendhal.java +++ b/src/games/stendhal/client/stendhal.java @@ -171,6 +171,8 @@ public class stendhal { logger.error("Failed to set Look and Feel", e); } + UIManager.getLookAndFeelDefaults().put("ClassLoader", stendhal.class.getClassLoader()); + Profile profile = Profile.createFromCommandline(args); if (profile.isValid()) { new LoginDialog(null, client).connect(profile); diff --git a/src/games/stendhal/client/update/Version.java b/src/games/stendhal/client/update/Version.java index a764893537..e341a5108c 100644 --- a/src/games/stendhal/client/update/Version.java +++ b/src/games/stendhal/client/update/Version.java @@ -10,7 +10,7 @@ package games.stendhal.client.update; public class Version { /** Version Number. */ - public static final String VERSION = "0.84.5"; + public static final String VERSION = "0.85"; /** * Extract the specified number of parts from a version-string. diff --git a/src/games/stendhal/common/Debug.java b/src/games/stendhal/common/Debug.java index ef80b65fd0..315b83bb39 100644 --- a/src/games/stendhal/common/Debug.java +++ b/src/games/stendhal/common/Debug.java @@ -25,7 +25,7 @@ public interface Debug { /** server version. */ // Note: This line is updated by build.xml using a regexp so be sure to adjust it in case you modify this line. - String VERSION = "0.84.5"; + String VERSION = "0.85"; /** diff --git a/src/games/stendhal/server/core/account/CharacterCreator.java b/src/games/stendhal/server/core/account/CharacterCreator.java index e880f492c4..9ffa9c7145 100644 --- a/src/games/stendhal/server/core/account/CharacterCreator.java +++ b/src/games/stendhal/server/core/account/CharacterCreator.java @@ -73,6 +73,7 @@ public class CharacterCreator { try { if (characterDAO.hasCharacter(trans, username, character)) { logger.warn("Character already exist: " + character); + transactionPool.commit(trans); return new CharacterResult(Result.FAILED_PLAYER_EXISTS, character, template); } diff --git a/src/games/stendhal/server/core/engine/GenerateINI.java b/src/games/stendhal/server/core/engine/GenerateINI.java index 7bc171ada5..6ea5b8db55 100644 --- a/src/games/stendhal/server/core/engine/GenerateINI.java +++ b/src/games/stendhal/server/core/engine/GenerateINI.java @@ -234,7 +234,7 @@ public class GenerateINI { out.println(); out.println("server_typeGame=" + gameName); out.println("server_name=" + gameName + " Marauroa server"); - out.println("server_version=0.84.5"); + out.println("server_version=0.85"); out.println("server_contact=https://sourceforge.net/tracker/?atid=514826&group_id=66537&func=browse"); out.println(); out.println("# Extensions configured on the server. Enable at will."); diff --git a/src/games/stendhal/server/core/engine/StendhalRPZone.java b/src/games/stendhal/server/core/engine/StendhalRPZone.java index cb4afa8a0b..202aeaebda 100644 --- a/src/games/stendhal/server/core/engine/StendhalRPZone.java +++ b/src/games/stendhal/server/core/engine/StendhalRPZone.java @@ -196,8 +196,11 @@ public class StendhalRPZone extends MarauroaRPZone { } public Portal getPortal(final Object reference) { + if (reference == null) { + return null; + } for (final Portal portal : portals) { - if (portal.getIdentifier().equals(reference)) { + if (reference.equals(portal.getIdentifier())) { return portal; } } @@ -703,12 +706,7 @@ public class StendhalRPZone extends MarauroaRPZone { } else if (object instanceof SpeakerNPC) { SingletonRepository.getNPCList().add((SpeakerNPC) object); } else if (object instanceof Portal) { - Portal portal = (Portal) object; - if (portal.getIdentifier() == null) { - logger.error("Portal without identifier: " + portal, new Throwable()); - } else { - portals.add(portal); - } + portals.add((Portal) object); } if (object instanceof NPC) { diff --git a/src/games/stendhal/server/entity/mapstuff/area/WalkBlocker.java b/src/games/stendhal/server/entity/mapstuff/area/WalkBlocker.java index ad2eb0693a..8d5e7c42b9 100644 --- a/src/games/stendhal/server/entity/mapstuff/area/WalkBlocker.java +++ b/src/games/stendhal/server/entity/mapstuff/area/WalkBlocker.java @@ -28,7 +28,7 @@ public class WalkBlocker extends AreaEntity { setRPClass("walkblocker"); put("type", "walkblocker"); - setResistance(40); + setResistance(100); } diff --git a/src/games/stendhal/server/maps/quests/Snowballs.java b/src/games/stendhal/server/maps/quests/Snowballs.java index 356683bc57..daade72d04 100644 --- a/src/games/stendhal/server/maps/quests/Snowballs.java +++ b/src/games/stendhal/server/maps/quests/Snowballs.java @@ -92,22 +92,19 @@ public class Snowballs extends AbstractQuest { return false; } else { final long timeRemaining = calculateRemainingTime(player); - - if (timeRemaining < 0) { - player.setQuest(QUEST_SLOT, "0"); - return true; - } else { - return false; - } + if (timeRemaining < 0) { + player.setQuest(QUEST_SLOT, "0"); + return true; + } else { + return false; + } } } private long calculateRemainingTime(final Player player) { final String lasttime = player.getQuest(QUEST_SLOT); - - final long delay = REQUIRED_MINUTES * MathHelper.MILLISECONDS_IN_ONE_MINUTE; - - final long timeRemaining = (Long.parseLong(lasttime) + delay) - System.currentTimeMillis(); + final long delay = REQUIRED_MINUTES * MathHelper.MILLISECONDS_IN_ONE_MINUTE; + final long timeRemaining = (MathHelper.parseLongDefault(lasttime, 0) + delay) - System.currentTimeMillis(); return timeRemaining; } diff --git a/src/games/stendhal/server/maps/semos/house/AdminHelpNPC.java b/src/games/stendhal/server/maps/semos/house/AdminHelpNPC.java index 21463b6ae1..6dba872f78 100644 --- a/src/games/stendhal/server/maps/semos/house/AdminHelpNPC.java +++ b/src/games/stendhal/server/maps/semos/house/AdminHelpNPC.java @@ -4,6 +4,7 @@ package games.stendhal.server.maps.semos.house; import games.stendhal.common.Direction; import games.stendhal.server.core.config.ZoneConfigurator; import games.stendhal.server.core.engine.StendhalRPZone; +import games.stendhal.server.core.pathfinder.FixedPath; import games.stendhal.server.core.pathfinder.Node; import games.stendhal.server.entity.npc.ConversationStates; import games.stendhal.server.entity.npc.SpeakerNPC; @@ -50,6 +51,7 @@ public class AdminHelpNPC implements ZoneConfigurator { List nodes = new LinkedList(); nodes.add(new Node(6, 11)); nodes.add(new Node(12,11)); + setPath(new FixedPath(nodes, true)); } }; diff --git a/stendhal.jnlp b/stendhal.jnlp index baa9757f35..63f543a6eb 100644 --- a/stendhal.jnlp +++ b/stendhal.jnlp @@ -22,7 +22,7 @@ Some of these people are NPC, they will give you tasks to accomplish and hints t - +