You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(103) |
Jun
(121) |
Jul
(16) |
Aug
(67) |
Sep
(126) |
Oct
(161) |
Nov
(164) |
Dec
(588) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(394) |
Feb
(181) |
Mar
(131) |
Apr
(180) |
May
(255) |
Jun
(11) |
Jul
(79) |
Aug
(70) |
Sep
(274) |
Oct
(138) |
Nov
(195) |
Dec
(8) |
2008 |
Jan
(3) |
Feb
(142) |
Mar
(162) |
Apr
(124) |
May
(148) |
Jun
(157) |
Jul
(425) |
Aug
(373) |
Sep
(264) |
Oct
(315) |
Nov
(225) |
Dec
(6) |
2009 |
Jan
(67) |
Feb
(78) |
Mar
(279) |
Apr
(294) |
May
(92) |
Jun
(65) |
Jul
(134) |
Aug
(41) |
Sep
(138) |
Oct
(125) |
Nov
(126) |
Dec
(122) |
2010 |
Jan
(15) |
Feb
(48) |
Mar
(9) |
Apr
(195) |
May
(373) |
Jun
(507) |
Jul
(42) |
Aug
(16) |
Sep
(38) |
Oct
(81) |
Nov
(64) |
Dec
(18) |
2011 |
Jan
(13) |
Feb
(12) |
Mar
(39) |
Apr
(1) |
May
(2) |
Jun
(27) |
Jul
(27) |
Aug
(31) |
Sep
(14) |
Oct
(102) |
Nov
(20) |
Dec
(37) |
2012 |
Jan
(22) |
Feb
(1) |
Mar
(1) |
Apr
(2) |
May
(2) |
Jun
(18) |
Jul
(6) |
Aug
(1) |
Sep
(1) |
Oct
|
Nov
|
Dec
|
2013 |
Jan
(1) |
Feb
(2) |
Mar
(1) |
Apr
(1) |
May
(47) |
Jun
(7) |
Jul
(107) |
Aug
|
Sep
|
Oct
(112) |
Nov
(31) |
Dec
(17) |
2014 |
Jan
(29) |
Feb
(111) |
Mar
(34) |
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(18) |
Dec
(10) |
From: <aki...@us...> - 2013-05-23 21:08:41
|
Revision: 9210 http://sourceforge.net/p/gridarta/code/9210 Author: akirschbaum Date: 2013-05-23 21:08:39 +0000 (Thu, 23 May 2013) Log Message: ----------- Fix incorrect source level in build file. Modified Paths: -------------- trunk/build.xml Modified: trunk/build.xml =================================================================== --- trunk/build.xml 2013-04-27 15:11:34 UTC (rev 9209) +++ trunk/build.xml 2013-05-23 21:08:39 UTC (rev 9210) @@ -27,7 +27,7 @@ <property file="developer.properties"/> <property file="project.properties"/> <property name="build.source.encoding" value="utf-8"/> - <property name="build.source.version" value="1.5"/> + <property name="build.source.version" value="1.6"/> <property name="build.target.version" value="${build.source.version}"/> <property name="debug" value="true"/> <property name="build.developer" value="unknown"/> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sm...@us...> - 2013-04-27 15:11:43
|
Revision: 9209 http://gridarta.svn.sourceforge.net/gridarta/?rev=9209&view=rev Author: smacky Date: 2013-04-27 15:11:34 +0000 (Sat, 27 Apr 2013) Log Message: ----------- Do not add intern tab to Artifact Chooser panel. Modified Paths: -------------- trunk/daimonin/ChangeLog trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/model/io/ArchetypeParser.java Modified: trunk/daimonin/ChangeLog =================================================================== --- trunk/daimonin/ChangeLog 2013-03-20 06:36:07 UTC (rev 9208) +++ trunk/daimonin/ChangeLog 2013-04-27 15:11:34 UTC (rev 9209) @@ -1,3 +1,7 @@ +2013-04-27 Smacky + + * Do not add intern tab to Archetype Chooser panel. + 2013-01-03 Andreas Kirschbaum * Do not disable map cursor in "enter xyz map". Modified: trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/model/io/ArchetypeParser.java =================================================================== --- trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/model/io/ArchetypeParser.java 2013-03-20 06:36:07 UTC (rev 9208) +++ trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/model/io/ArchetypeParser.java 2013-04-27 15:11:34 UTC (rev 9209) @@ -154,7 +154,10 @@ */ @Override protected boolean addToPanel(final boolean isInternPath, @NotNull final String editorFolder, @NotNull final Archetype archetype) { - return !isInternPath && !(editorFolder + "/").startsWith("/" + net.sf.gridarta.model.gameobject.GameObject.EDITOR_FOLDER_INTERN + "/"); + // isInternPath is bugged (always false) so lets ignore that and just match editorFolder. + // This was also bugged (no leading "/", we add the trailing one to mark the end [in case of an internfoo folder, etc).) + //return !isInternPath && !(editorFolder + "/").startsWith("/" + net.sf.gridarta.model.gameobject.GameObject.EDITOR_FOLDER_INTERN + "/"); + return !(editorFolder + "/").startsWith(net.sf.gridarta.model.gameobject.GameObject.EDITOR_FOLDER_INTERN + "/"); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2013-03-20 06:36:14
|
Revision: 9208 http://gridarta.svn.sourceforge.net/gridarta/?rev=9208&view=rev Author: akirschbaum Date: 2013-03-20 06:36:07 +0000 (Wed, 20 Mar 2013) Log Message: ----------- Access field only within synchronized context. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/dialog/findarchetypes/FindArchetypesDialogManager.java Modified: trunk/src/app/net/sf/gridarta/gui/dialog/findarchetypes/FindArchetypesDialogManager.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/dialog/findarchetypes/FindArchetypesDialogManager.java 2013-02-03 19:48:07 UTC (rev 9207) +++ trunk/src/app/net/sf/gridarta/gui/dialog/findarchetypes/FindArchetypesDialogManager.java 2013-03-20 06:36:07 UTC (rev 9208) @@ -96,12 +96,15 @@ */ @Override public void showDialog() { + FindArchetypesDialog<G, A, R> dialog; synchronized (sync) { - if (findArchetypesDialog == null) { - findArchetypesDialog = new FindArchetypesDialog<G, A, R>(parent, archetypeChooserControl, objectChooser, archetypeTypeSet); + dialog = findArchetypesDialog; + if (dialog == null) { + dialog = new FindArchetypesDialog<G, A, R>(parent, archetypeChooserControl, objectChooser, archetypeTypeSet); + findArchetypesDialog = dialog; } } - findArchetypesDialog.show(); + dialog.show(); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2013-02-03 19:48:14
|
Revision: 9207 http://gridarta.svn.sourceforge.net/gridarta/?rev=9207&view=rev Author: akirschbaum Date: 2013-02-03 19:48:07 +0000 (Sun, 03 Feb 2013) Log Message: ----------- Update possible event types for scripts. [Crossfire] Modified Paths: -------------- trunk/crossfire/ChangeLog trunk/crossfire/resource/resource/conf/types.xml Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2013-02-03 18:56:37 UTC (rev 9206) +++ trunk/crossfire/ChangeLog 2013-02-03 19:48:07 UTC (rev 9207) @@ -1,5 +1,7 @@ 2013-02-03 Andreas Kirschbaum + * Update possible event types for scripts. + * Collect resources. 2013-01-03 Andreas Kirschbaum Modified: trunk/crossfire/resource/resource/conf/types.xml =================================================================== --- trunk/crossfire/resource/resource/conf/types.xml 2013-02-03 18:56:37 UTC (rev 9206) +++ trunk/crossfire/resource/resource/conf/types.xml 2013-02-03 19:48:07 UTC (rev 9207) @@ -232,7 +232,7 @@ <list name="event"> <listentry value="1" name="apply"/> - <listentry value="2" name="attacked"/> + <listentry value="2" name="attack"/> <listentry value="3" name="death"/> <listentry value="4" name="drop"/> <listentry value="5" name="pickup"/> @@ -245,6 +245,7 @@ <listentry value="12" name="timer"/> <listentry value="13" name="destroy"/> <listentry value="31" name="user"/> + <listentry value="32" name="selling"/> <listentry value="33" name="attacks"/> </list> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2013-02-03 18:56:51
|
Revision: 9206 http://gridarta.svn.sourceforge.net/gridarta/?rev=9206&view=rev Author: akirschbaum Date: 2013-02-03 18:56:37 +0000 (Sun, 03 Feb 2013) Log Message: ----------- Collect resources. [Crossfire] Modified Paths: -------------- trunk/crossfire/ChangeLog trunk/crossfire/resource/resource/conf/animations trunk/crossfire/resource/resource/conf/animtree trunk/crossfire/resource/resource/conf/archetypes trunk/crossfire/resource/resource/conf/bmaps.paths trunk/crossfire/resource/resource/conf/crossfire.0 trunk/crossfire/resource/resource/conf/smooth Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2013-01-03 20:10:36 UTC (rev 9205) +++ trunk/crossfire/ChangeLog 2013-02-03 18:56:37 UTC (rev 9206) @@ -1,3 +1,7 @@ +2013-02-03 Andreas Kirschbaum + + * Collect resources. + 2013-01-03 Andreas Kirschbaum * Do not disable map cursor in "enter xyz map". Modified: trunk/crossfire/resource/resource/conf/animations =================================================================== --- trunk/crossfire/resource/resource/conf/animations 2013-01-03 20:10:36 UTC (rev 9205) +++ trunk/crossfire/resource/resource/conf/animations 2013-02-03 18:56:37 UTC (rev 9206) @@ -194,6 +194,12 @@ altar.111 altar.112 mina +anim altar_gorokh +altargoro.111 +altargoro.112 +altargoro.111 +altargoro.113 +mina anim altar_ruggilli altarrugg.111 altarrugg.112 @@ -214,10 +220,31 @@ altar.111 altar.112 mina +anim altar_valriel +altarvalr.111 +altarvalr.112 +altarvalr.111 +altarvalr.113 +mina +anim altar_valriel_intervention +altarvalr_intervention.111 +altarvalr_intervention.112 +altarvalr_intervention.113 +altarvalr_intervention.114 +altarvalr_intervention.115 +mina anim amethyst amethyst.111 amethyst.112 mina +anim amulet +amulet.111 +amulet_dark.111 +amulet_darkmagenta.111 +amulet_darkred.111 +amulet_magenta.111 +amulet_red.111 +mina anim angel facings 4 angel.111 @@ -268,6 +295,14 @@ archangel.x12 archangel.x13 mina +anim archblack +archblack.111 +archblack.112 +archblack.113 +archblack.114 +archblack.113 +archblack.112 +mina anim archon archon.111 archon.222 @@ -296,6 +331,83 @@ arrow.171 arrow.181 mina +anim arrow_fire +arrow_fire.101 +arrow_fire.111 +arrow_fire.121 +arrow_fire.131 +arrow_fire.141 +arrow_fire.151 +arrow_fire.161 +arrow_fire.171 +arrow_fire.181 +mina +anim arrow_frost +arrow_frost.101 +arrow_frost.111 +arrow_frost.121 +arrow_frost.131 +arrow_frost.141 +arrow_frost.151 +arrow_frost.161 +arrow_frost.171 +arrow_frost.181 +mina +anim arrow_lightning +arrow_lightning.101 +arrow_lightning.111 +arrow_lightning.121 +arrow_lightning.131 +arrow_lightning.141 +arrow_lightning.151 +arrow_lightning.161 +arrow_lightning.171 +arrow_lightning.181 +mina +anim arrow_magic +arrow_magic.101 +arrow_magic.111 +arrow_magic.121 +arrow_magic.131 +arrow_magic.141 +arrow_magic.151 +arrow_magic.161 +arrow_magic.171 +arrow_magic.181 +mina +anim arrow_paralysis +arrow_paralysis.101 +arrow_paralysis.111 +arrow_paralysis.121 +arrow_paralysis.131 +arrow_paralysis.141 +arrow_paralysis.151 +arrow_paralysis.161 +arrow_paralysis.171 +arrow_paralysis.181 +mina +anim arrow_poison +arrow_poison.101 +arrow_poison.111 +arrow_poison.121 +arrow_poison.131 +arrow_poison.141 +arrow_poison.151 +arrow_poison.161 +arrow_poison.171 +arrow_poison.181 +mina +anim arrow_slay_dragon +arrow_slay_dragon.101 +arrow_slay_dragon.111 +arrow_slay_dragon.121 +arrow_slay_dragon.131 +arrow_slay_dragon.141 +arrow_slay_dragon.151 +arrow_slay_dragon.161 +arrow_slay_dragon.171 +arrow_slay_dragon.181 +mina anim asteroid asteroid.112 asteroid.111 @@ -338,9 +450,9 @@ ball_lightning.444 mina anim banishment -turnundead.111 -turnundead.112 -turnundead.113 +banishment.111 +banishment.112 +banishment.113 mina anim banshee banshee.111 @@ -548,6 +660,14 @@ bpudding_s.113 bpudding_s.114 mina +anim bless_effect +bless_effect.111 +bless_effect.112 +bless_effect.113 +bless_effect.114 +bless_effect.115 +bless_effect.116 +mina anim blob blob.111 blob.112 @@ -609,6 +729,72 @@ bolt.171 bolt.181 mina +anim bolt_fire +bolt_fire.101 +bolt_fire.111 +bolt_fire.121 +bolt_fire.131 +bolt_fire.141 +bolt_fire.151 +bolt_fire.161 +bolt_fire.171 +bolt_fire.181 +mina +anim bolt_frost +bolt_frost.101 +bolt_frost.111 +bolt_frost.121 +bolt_frost.131 +bolt_frost.141 +bolt_frost.151 +bolt_frost.161 +bolt_frost.171 +bolt_frost.181 +mina +anim bolt_lightning +bolt_lightning.101 +bolt_lightning.111 +bolt_lightning.121 +bolt_lightning.131 +bolt_lightning.141 +bolt_lightning.151 +bolt_lightning.161 +bolt_lightning.171 +bolt_lightning.181 +mina +anim bolt_magic +bolt_magic.101 +bolt_magic.111 +bolt_magic.121 +bolt_magic.131 +bolt_magic.141 +bolt_magic.151 +bolt_magic.161 +bolt_magic.171 +bolt_magic.181 +mina +anim bolt_poison +bolt_poison.101 +bolt_poison.111 +bolt_poison.121 +bolt_poison.131 +bolt_poison.141 +bolt_poison.151 +bolt_poison.161 +bolt_poison.171 +bolt_poison.181 +mina +anim bolt_slay_dragon +bolt_slay_dragon.101 +bolt_slay_dragon.111 +bolt_slay_dragon.121 +bolt_slay_dragon.131 +bolt_slay_dragon.141 +bolt_slay_dragon.151 +bolt_slay_dragon.161 +bolt_slay_dragon.171 +bolt_slay_dragon.181 +mina anim bomb bomb.111 bomb.111 @@ -1188,6 +1374,14 @@ crawling_chaos.112 crawling_chaos.113 mina +anim curse_effect +curse_effect.111 +curse_effect.112 +curse_effect.113 +curse_effect.114 +curse_effect.115 +curse_effect.116 +mina anim cwall_closed_1 cwallsec.111 cwallsec.112 @@ -1284,9 +1478,13 @@ blocked.111 mina anim dave +facings 2 dave.111 dave.112 dave.113 +dave.151 +dave.152 +dave.153 mina anim deathshead deathshead.111 @@ -1774,6 +1972,21 @@ fenx.171 fenx.172 mina +anim fenx_player_bow +facings 4 +fenx_bow.111 +fenx_bow.112 +fenx_bow.113 +fenx_bow.131 +fenx_bow.132 +fenx_bow.133 +fenx_bow.151 +fenx_bow.152 +fenx_bow.153 +fenx_bow.171 +fenx_bow.172 +fenx_bow.173 +mina anim fenx_player_class_warrior facings 4 fenx_class_warrior.111 @@ -1785,6 +1998,36 @@ fenx_class_warrior.171 fenx_class_warrior.172 mina +anim fenx_player_double_sword +facings 4 +fenx_double_sword.111 +fenx_double_sword.112 +fenx_double_sword.111 +fenx_double_sword.131 +fenx_double_sword.132 +fenx_double_sword.131 +fenx_double_sword.151 +fenx_double_sword.152 +fenx_double_sword.151 +fenx_double_sword.171 +fenx_double_sword.172 +fenx_double_sword.171 +mina +anim fenx_player_karate +facings 4 +fenx_karate.110 +fenx_karate.111 +fenx_karate.110 +fenx_karate.130 +fenx_karate.131 +fenx_karate.130 +fenx_karate.150 +fenx_karate.151 +fenx_karate.150 +fenx_karate.170 +fenx_karate.171 +fenx_karate.170 +mina anim fenx_player_praying facings 4 fenx_praying.110 @@ -1800,6 +2043,36 @@ fenx_praying.171 fenx_praying.170 mina +anim fenx_player_punching +facings 4 +fenx_punching.110 +fenx_punching.111 +fenx_punching.112 +fenx_punching.130 +fenx_punching.131 +fenx_punching.132 +fenx_punching.150 +fenx_punching.151 +fenx_punching.152 +fenx_punching.170 +fenx_punching.171 +fenx_punching.172 +mina +anim fenx_player_read_scroll +facings 4 +fenx_read_scroll.111 +fenx_read_scroll.112 +fenx_read_scroll.113 +fenx_read_scroll.131 +fenx_read_scroll.132 +fenx_read_scroll.133 +fenx_read_scroll.151 +fenx_read_scroll.152 +fenx_read_scroll.153 +fenx_read_scroll.171 +fenx_read_scroll.172 +fenx_read_scroll.173 +mina anim fenx_player_singing facings 4 fenx_singing.110 @@ -1832,9 +2105,9 @@ mina anim fenx_player_sword facings 4 -fenx.111 -fenx.112 -fenx.111 +fenx_sword.111 +fenx_sword.112 +fenx_sword.111 fenx_sword.131 fenx_sword.132 fenx_sword.131 @@ -2080,6 +2353,13 @@ gargoyle.112 gargoyle.111 mina +anim gargoyle +gargoyle.111 +gargoyle.112 +gargoyle.111 +gargoyle.112 +gargoyle.111 +mina anim gateTrg1 gate_1.111 gate_1.112 @@ -2163,8 +2443,15 @@ ghast.113 mina anim ghost +facings 4 ghost.111 ghost.112 +ghost.131 +ghost.132 +ghost.151 +ghost.152 +ghost.171 +ghost.172 mina anim giant giant.x11 @@ -2270,20 +2557,27 @@ goblin_chief.111 mina anim goblin_leader_arc +facings 4 goblin_leader.111 -goblin_leader.111 +goblin_leader.112 +goblin_leader.131 +goblin_leader.132 +goblin_leader.151 +goblin_leader.152 +goblin_leader.171 +goblin_leader.172 mina anim god_finger god_finger.111 god_finger.112 mina anim god_power -manabolt.111 -manabolt.112 -manabolt.113 -manabolt.114 -manabolt.113 -manabolt.114 +god_power.111 +god_power.112 +god_power.113 +god_power.114 +god_power.113 +god_power.114 mina anim goldflagstone goldflagstone.111 @@ -2538,9 +2832,9 @@ holyave.11C mina anim holy_effect -turnundead.111 -turnundead.112 -turnundead.113 +holy_effect.111 +holy_effect.112 +holy_effect.113 mina anim holy_priest holy_priest.111 @@ -2551,14 +2845,14 @@ golem.112 mina anim holy_word -turnundead.111 -turnundead.112 -turnundead.113 +holy_word.111 +holy_word.112 +holy_word.113 mina anim holy_wrath -turnundead.111 -turnundead.112 -turnundead.113 +holy_wrath.111 +holy_wrath.112 +holy_wrath.113 mina anim horse facings 1 @@ -2805,9 +3099,13 @@ speedball.112 mina anim lich +facings 2 lich.111 lich.112 lich.113 +lich.151 +lich.152 +lich.153 mina anim light sunspear.111 @@ -2864,10 +3162,10 @@ lokanth.172 mina anim loose_magic -manabolt.111 -manabolt.112 -manabolt.113 -manabolt.114 +loose_magic.111 +loose_magic.112 +loose_magic.113 +loose_magic.114 mina anim lord_e lord_e.111 @@ -3046,33 +3344,38 @@ man2.171 mina anim manaball -manabolt.111 -manabolt.112 -manabolt.113 -manabolt.114 +manaball.111 +manaball.112 +manaball.113 +manaball.114 mina anim manablast -manabolt.111 -manabolt.112 -manabolt.113 -manabolt.114 +manablast.111 +manablast.112 +manablast.113 +manablast.114 mina anim manabolt +facings 8 manabolt.111 -manabolt.112 -manabolt.113 -manabolt.114 +manabolt.121 +manabolt.131 +manabolt.141 +manabolt.151 +manabolt.161 +manabolt.171 +manabolt.181 mina anim manabullet -snowball.111 -snowball.111 -snowball.121 -snowball.131 -snowball.141 -snowball.151 -snowball.161 -snowball.171 -snowball.181 +manabullet.111 +manabullet.111 +manabullet.121 +manabullet.131 +manabullet.141 +manabullet.151 +manabullet.161 +manabullet.171 +manabullet.181 mina anim manhole manhole.111 @@ -3139,10 +3442,10 @@ fix_mercury.112 mina anim mesangel -liteangel.111 -liteangel.112 -liteangel.113 -liteangel.114 +mesangel.111 +mesangel.112 +mesangel.113 +mesangel.114 mina anim meteor burnout.111 @@ -3333,6 +3636,30 @@ mushman1.171 mushman1.172 mina +anim mvsdoor_closed +mvsdoor.111 +mvsdoor.112 +mvsdoor.113 +mvsdoor.114 +mina +anim mvsdoor_open +mvsdoor.111 +mvsdoor.112 +mvsdoor.113 +mvsdoor.114 +mina +anim mvwdoor_closed +mvwdoor.111 +mvwdoor.112 +mvwdoor.113 +mvwdoor.114 +mina +anim mvwdoor_open +mvwdoor.111 +mvwdoor.112 +mvwdoor.113 +mvwdoor.114 +mina anim mystic_fist mystic_fist.111 mystic_fist.112 @@ -4144,6 +4471,30 @@ protection.116 protection.117 mina +anim protection_cold_effect +protection_cold_effect.111 +protection_cold_effect.112 +protection_cold_effect.113 +protection_cold_effect.114 +protection_cold_effect.115 +protection_cold_effect.116 +mina +anim protection_electricity_effect +protection_electricity_effect.111 +protection_electricity_effect.112 +protection_electricity_effect.113 +protection_electricity_effect.114 +protection_electricity_effect.115 +protection_electricity_effect.116 +mina +anim protection_fire_effect +protection_fire_effect.111 +protection_fire_effect.112 +protection_fire_effect.113 +protection_fire_effect.114 +protection_fire_effect.115 +protection_fire_effect.116 +mina anim pup facings 2 pup.131 @@ -4168,6 +4519,10 @@ pyromaniac.113 pyromaniac.114 mina +anim quaathu +quaathu.x11 +quaathu.x12 +mina anim quetzalcoatl_player facings 2 quetzalcoatl.131 @@ -4188,6 +4543,20 @@ raas.171 raas.131 mina +anim rage_effect +rage_effect.111 +rage_effect.112 +rage_effect.113 +rage_effect.114 +rage_effect.115 +rage_effect.116 +mina +anim rain +rain.111 +rain.112 +rain.113 +rain.114 +mina anim red_dragon1 facings 2 pl_dragon_r.151 @@ -4239,12 +4608,67 @@ ring.115 ring.116 mina +anim ring_acid +ring_acid.111 +ring_acid.112 +ring_acid.111 +mina +anim ring_ancient_magic +ring_ancient_magic.111 +ring_ancient_magic.112 +ring_ancient_magic.111 +mina +anim ring_doom +ring_doom.111 +ring_doom.112 +ring_doom.111 +mina +anim ring_fire +ring_fire.111 +ring_fire.112 +ring_fire.111 +mina +anim ring_high_magic +ring_high_magic.111 +ring_high_magic.112 +ring_high_magic.111 +mina +anim ring_ice +ring_ice.111 +ring_ice.112 +ring_ice.111 +mina +anim ring_magic +ring_magic.111 +ring_magic.112 +ring_magic.111 +mina anim ring_nodrain ring_drain.111 ring_drain.112 ring_drain.113 ring_drain.114 mina +anim ring_saint +ring_saint.111 +ring_saint.112 +ring_saint.111 +mina +anim ring_storm +ring_storm.111 +ring_storm.112 +ring_storm.111 +mina +anim ring_thieves +ring_thieves.111 +ring_thieves.112 +ring_thieves.111 +mina +anim ring_woe +ring_woe.111 +ring_woe.112 +ring_woe.111 +mina anim robe_midnight robe_midnight.111 robe_midnight.112 @@ -4313,7 +4737,7 @@ rune_heal.111 mina anim rune_icestorm -rune_frost.111 +rune_icestorm.111 icestorm.111 mina anim rune_large_fireball @@ -4321,7 +4745,7 @@ rune_fireball.111 mina anim rune_large_icestorm -rune_frost.111 +rune_icestorm.111 icestorm.111 mina anim rune_medium_fireball @@ -4416,6 +4840,15 @@ sage.151 sage.171 mina +anim sailing_big_galleon +facings 2 +biggalleon.x11 +biggalleon.x71 +mina +anim sailing_galleon +facings 1 +galleon.111 +mina anim sandy sandy.112 sandy.113 @@ -4739,6 +5172,12 @@ snake.111 snake.112 mina +anim snow_c +snow_c.111 +snow_c.112 +snow_c.113 +snow_c.114 +mina anim snowball snowball.111 snowball.111 @@ -5549,9 +5988,13 @@ anim warrior_blue facings 4 warrior_blue.111 +warrior_blue.112 warrior_blue.131 +warrior_blue.132 warrior_blue.151 +warrior_blue.152 warrior_blue.171 +warrior_blue.172 mina anim warrior_class facings 4 @@ -5567,30 +6010,46 @@ anim warrior_green facings 4 warrior_green.111 +warrior_green.112 warrior_green.131 +warrior_green.132 warrior_green.151 +warrior_green.152 warrior_green.171 +warrior_green.172 mina anim warrior_grey facings 4 warrior_grey.111 +warrior_grey.112 warrior_grey.131 +warrior_grey.132 warrior_grey.151 +warrior_grey.152 warrior_grey.171 +warrior_grey.172 mina anim warrior_lblue facings 4 warrior_lblue.111 +warrior_lblue.112 warrior_lblue.131 +warrior_lblue.132 warrior_lblue.151 +warrior_lblue.152 warrior_lblue.171 +warrior_lblue.172 mina anim warrior_red facings 4 warrior_red.111 +warrior_red.112 warrior_red.131 +warrior_red.132 warrior_red.151 +warrior_red.152 warrior_red.171 +warrior_red.172 mina anim water_elemental elem_water.111 @@ -5865,11 +6324,11 @@ worthless_dragon.x71 worthless_dragon.x72 worthless_dragon.x73 -worthless_dragon.x72 +worthless_dragon.x74 worthless_dragon.x31 worthless_dragon.x32 worthless_dragon.x33 -worthless_dragon.x32 +worthless_dragon.x34 mina anim wraith wraith.111 Modified: trunk/crossfire/resource/resource/conf/animtree =================================================================== --- trunk/crossfire/resource/resource/conf/animtree 2013-01-03 20:10:36 UTC (rev 9205) +++ trunk/crossfire/resource/resource/conf/animtree 2013-02-03 18:56:37 UTC (rev 9206) @@ -19,20 +19,32 @@ /shop/alchemy_pearl_converter /shop/alchemy_ruby_converter /connect/altar +/gods/altars/altar_gorokh /gods/altars/altar_ruggilli /gods/altars/altar_sorig /connect/altar_trigger +/gods/altars/altar_valriel +/gods/altars/altar_valriel_intervention /jewel/amethyst +/talisman/amulet /monster/angel/angel /monster/angel/angel_sword /monster/insect/ant/ant /monster/insect/ant/ant_larvae /monster/animal/ape /monster/angel/archangel +/exit/archblack /monster/chaos/archon /monster/humanoid/Human/armless_cook /monster/troll/armour_troll2 /weapon/bow/arrow +/weapon/bow/arrow_fire +/weapon/bow/arrow_frost +/weapon/bow/arrow_lightning +/weapon/bow/arrow_magic +/weapon/bow/arrow_paralysis +/weapon/bow/arrow_poison +/weapon/bow/arrow_slay_dragon /spell/Bullet/asteroid /spell/Golem/avatar /monster/dragon/baby_dragon @@ -67,6 +79,7 @@ /monster/acid/black_pudding /monster/acid/black_pudding_grow /monster/acid/black_pudding_split +/spell/BlessCurse/bless_effect /monster/misc/blob /wall/bwall/block_door_closed /wall/bwall/block_door_open @@ -75,6 +88,12 @@ /monster/humanoid/Dragon/blue_dragon2 /monster/acid/bluesphere /weapon/bow/bolt +/weapon/bow/bolt_fire +/weapon/bow/bolt_frost +/weapon/bow/bolt_lightning +/weapon/bow/bolt_magic +/weapon/bow/bolt_poison +/weapon/bow/bolt_slay_dragon /spell/Bomb/bomb /monster/dragon/bone_drake/bone_drake /monster/demon/bone_head @@ -157,6 +176,7 @@ /monster/humanoid/Class/conjurer /monster/humanoid/Class/conjurer2 /monster/misc/crawl/crawling_chaos +/spell/BlessCurse/curse_effect /connect/cwall_closed_1 /connect/cwall_open_1 /connect/cwallmural1_closed_1 @@ -238,8 +258,13 @@ /monster/humanoid/Human/farmer /spell/Cone/fear /player/race/fenx_player +/player/race/fenx_player_bow /player/race/fenx_player_class_warrior +/player/race/fenx_player_double_sword +/player/race/fenx_player_karate /player/race/fenx_player_praying +/player/race/fenx_player_punching +/player/race/fenx_player_read_scroll /player/race/fenx_player_singing /player/race/fenx_player_spellcasting /player/race/fenx_player_sword @@ -274,6 +299,7 @@ /monster/troll/Gaelotroll/gaelotroll /monster/humanoid/Gnome/gardengnome /monster/misc/gargolye +/monster/misc/gargoyle /connect/Gates/gateTrg1 /connect/Gates/gateTrg2 /connect/Gates/gate_closed_1 @@ -438,6 +464,10 @@ /connect/mover_turn /monster/misc/mudman /monster/animal/mushman1 +/connect/Doors/mvsdoor_closed +/connect/Doors/mvsdoor_open +/connect/Doors/mvwdoor_closed +/connect/Doors/mvwdoor_open /spell/Golem/mystic_fist /monster/undead/nazgul /monster/humanoid/necromancer @@ -533,19 +563,36 @@ /monster/humanoid/Human/princess /monster/humanoid/Human/prisoner /spell/Change_Ability/protection +/spell/Change_Ability/protection_cold_effect +/spell/Change_Ability/protection_electricity_effect +/spell/Change_Ability/protection_fire_effect /monster/animal/Dog/pup /monster/animal/giant_worm/purple_worm /monster/humanoid/pyromaniac +/monster/misc/quaathu/quaathu /player/race/quetzalcoatl_player /ground/quicksilver_sea /monster/demon/raas +/spell/Change_Ability/rage_effect +/ground/Weather/rain /monster/humanoid/Dragon/red_dragon1 /monster/humanoid/Dragon/red_dragon2 /wall/cwall-red/redweak_wall_3 /wall/cwall-red/redweak_wall_4 /armour/shield/reflector /talisman/ring +/talisman/ring_acid +/talisman/ring_ancient_magic +/talisman/ring_doom +/talisman/ring_fire +/talisman/ring_high_magic +/talisman/ring_ice +/talisman/ring_magic /talisman/ring_nodrain +/talisman/ring_saint +/talisman/ring_storm +/talisman/ring_thieves +/talisman/ring_woe /armour/mail/robe_midnight /spell/Wand/rod_heavy /spell/Wand/rod_light @@ -584,6 +631,8 @@ /monster/elemental/Shadow/s_mastif /monster/elemental/Shadow/s_wyvern /monster/humanoid/Human/sage +/transport/sailing_big_galleon +/transport/sailing_galleon /monster/misc/sandy /jewel/sapphire /monster/animal/scorpion @@ -631,6 +680,7 @@ /spell/MagicWall/smover/smover_turn /monster/animal/snake /spell/AnimateWeapon/snake_golem +/ground/Weather/snow_c /spell/Bullet/snowball /spell/Bullet/snowstorm /player/class/Wizardry/sorcerer_class Modified: trunk/crossfire/resource/resource/conf/archetypes =================================================================== --- trunk/crossfire/resource/resource/conf/archetypes 2013-01-03 20:10:36 UTC (rev 9205) +++ trunk/crossfire/resource/resource/conf/archetypes 2013-02-03 18:56:37 UTC (rev 9206) @@ -1164,7 +1164,7 @@ animation mithril_ar_ele anim_speed 3 client_anim_random 1 -ac 4 +ac 6 resist_physical 40 resist_electricity 30 Cha 1 @@ -1924,6 +1924,74 @@ dam 6 maxsp 1 end +Object mvsdoor_closed_1 +editor_folder connect/Doors +name stone door +type 91 +activate_on_push 1 +activate_on_release 1 +no_pick 1 +face mvsdoor.114 +animation mvsdoor_closed +is_animated 0 +move_block all +no_magic 1 +damned 1 +blocksview 1 +wc 3 +maxsp 0 +dam 6 +end +Object mvsdoor_open_1 +editor_folder connect/Doors +name stone door +type 91 +activate_on_push 1 +activate_on_release 1 +no_pick 1 +damned 1 +no_magic 1 +face mvsdoor.111 +animation mvsdoor_open +is_animated 0 +wc 0 +dam 6 +maxsp 1 +end +Object mvwdoor_closed_1 +editor_folder connect/Doors +name wood door +type 91 +activate_on_push 1 +activate_on_release 1 +no_pick 1 +face mvwdoor.114 +animation mvwdoor_closed +is_animated 0 +move_block all +no_magic 1 +damned 1 +blocksview 1 +wc 3 +maxsp 0 +dam 6 +end +Object mvwdoor_open_1 +editor_folder connect/Doors +name wood door +type 91 +activate_on_push 1 +activate_on_release 1 +no_pick 1 +damned 1 +no_magic 1 +face mvwdoor.111 +animation mvwdoor_open +is_animated 0 +wc 0 +dam 6 +maxsp 1 +end Object odoorm2_closed_1 editor_folder connect/Doors name wood door @@ -5464,6 +5532,776 @@ x 2 y 3 end +Object devourers_cathedral +editor_folder construct/temple +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object devourers_cathedral_2 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object devourers_cathedral_3 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object devourers_cathedral_4 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object devourers_cathedral_5 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object devourers_cathedral_6 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object devourers_cathedral_7 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object devourers_cathedral_8 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object devourers_cathedral_9 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object devourers_cathedral_10 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object devourers_cathedral_11 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object devourers_cathedral_12 +name Cathedral of Devourers +type 66 +face devourers_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object devourers_church +editor_folder construct/temple +name Church of Devourers +type 66 +face devourers_church.x11 +no_pick 1 +client_type 25012 +end +More +Object devourers_church_2 +name Church of Devourers +type 66 +face devourers_church.x11 +no_pick 1 +x 1 +end +More +Object devourers_church_3 +name Church of Devourers +type 66 +face devourers_church.x11 +no_pick 1 +y 1 +end +More +Object devourers_church_4 +name Church of Devourers +type 66 +face devourers_church.x11 +no_pick 1 +x 1 +y 1 +end +Object devourers_temple +editor_folder construct/temple +name Temple of Devourers +type 66 +blocksview 1 +face devourers_temple.111 +no_pick 1 +end +Object gaea_cathedral +editor_folder construct/temple +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object gaea_cathedral_2 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object gaea_cathedral_3 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object gaea_cathedral_4 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object gaea_cathedral_5 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object gaea_cathedral_6 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object gaea_cathedral_7 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object gaea_cathedral_8 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object gaea_cathedral_9 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object gaea_cathedral_10 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object gaea_cathedral_11 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object gaea_cathedral_12 +name Cathedral of Gaea +type 66 +face gaea_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object gaea_church +editor_folder construct/temple +name Church of Gaea +type 66 +face gaea_church.x11 +no_pick 1 +client_type 25012 +end +More +Object gaea_church_2 +name Church of Gaea +type 66 +face gaea_church.x11 +no_pick 1 +x 1 +end +More +Object gaea_church_3 +name Church of Gaea +type 66 +face gaea_church.x11 +no_pick 1 +y 1 +end +More +Object gaea_church_4 +name Church of Gaea +type 66 +face gaea_church.x11 +no_pick 1 +x 1 +y 1 +end +Object gaea_temple +editor_folder construct/temple +name Temple of Gaea +type 66 +blocksview 1 +face gaea_temple.111 +no_pick 1 +end +Object gnarg_cathedral +editor_folder construct/temple +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object gnarg_cathedral_2 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object gnarg_cathedral_3 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object gnarg_cathedral_4 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object gnarg_cathedral_5 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object gnarg_cathedral_6 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object gnarg_cathedral_7 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object gnarg_cathedral_8 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object gnarg_cathedral_9 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object gnarg_cathedral_10 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object gnarg_cathedral_11 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object gnarg_cathedral_12 +name Cathedral of Gnarg +type 66 +face gnarg_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object gnarg_church +editor_folder construct/temple +name Church of Gnarg +type 66 +face gnarg_church.x11 +no_pick 1 +client_type 25012 +end +More +Object gnarg_church_2 +name Church of Gnarg +type 66 +face gnarg_church.x11 +no_pick 1 +x 1 +end +More +Object gnarg_church_3 +name Church of Gnarg +type 66 +face gnarg_church.x11 +no_pick 1 +y 1 +end +More +Object gnarg_church_4 +name Church of Gnarg +type 66 +face gnarg_church.x11 +no_pick 1 +x 1 +y 1 +end +Object gnarg_temple +editor_folder construct/temple +name Temple of Gnarg +type 66 +blocksview 1 +face gnarg_temple.111 +no_pick 1 +end +Object gorokh_cathedral +editor_folder construct/temple +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object gorokh_cathedral_2 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object gorokh_cathedral_3 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object gorokh_cathedral_4 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object gorokh_cathedral_5 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object gorokh_cathedral_6 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object gorokh_cathedral_7 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object gorokh_cathedral_8 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object gorokh_cathedral_9 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object gorokh_cathedral_10 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object gorokh_cathedral_11 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object gorokh_cathedral_12 +name Cathedral of Gorokh +type 66 +face gorokh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object gorokh_church +editor_folder construct/temple +name Church of Gorokh +type 66 +face gorokh_church.x11 +no_pick 1 +client_type 25012 +end +More +Object gorokh_church_2 +name Church of Gorokh +type 66 +face gorokh_church.x11 +no_pick 1 +x 1 +end +More +Object gorokh_church_3 +name Church of Gorokh +type 66 +face gorokh_church.x11 +no_pick 1 +y 1 +end +More +Object gorokh_church_4 +name Church of Gorokh +type 66 +face gorokh_church.x11 +no_pick 1 +x 1 +y 1 +end +Object gorokh_temple +editor_folder construct/temple +name Temple of Gorokh +type 66 +blocksview 1 +face gorokh_temple.111 +no_pick 1 +end +Object ixalovh_cathedral +editor_folder construct/temple +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object ixalovh_cathedral_2 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object ixalovh_cathedral_3 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object ixalovh_cathedral_4 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object ixalovh_cathedral_5 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object ixalovh_cathedral_6 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object ixalovh_cathedral_7 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object ixalovh_cathedral_8 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object ixalovh_cathedral_9 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object ixalovh_cathedral_10 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object ixalovh_cathedral_11 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object ixalovh_cathedral_12 +name Cathedral of Ixalovh +type 66 +face ixalovh_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object ixalovh_church +editor_folder construct/temple +name Church of Ixalovh +type 66 +face ixalovh_church.x11 +no_pick 1 +client_type 25012 +end +More +Object ixalovh_church_2 +name Church of Ixalovh +type 66 +face ixalovh_church.x11 +no_pick 1 +x 1 +end +More +Object ixalovh_church_3 +name Church of Ixalovh +type 66 +face ixalovh_church.x11 +no_pick 1 +y 1 +end +More +Object ixalovh_church_4 +name Church of Ixalovh +type 66 +face ixalovh_church.x11 +no_pick 1 +x 1 +y 1 +end +Object ixalovh_temple +editor_folder construct/temple +name Temple of Ixalovh +type 66 +blocksview 1 +face ixalovh_temple.111 +no_pick 1 +end Object lyth_temple editor_folder construct/temple name Temple of Lythander @@ -5472,6 +6310,152 @@ face lyth_temple.111 no_pick 1 end +Object lythander_cathedral +editor_folder construct/temple +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object lythander_cathedral_2 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object lythander_cathedral_3 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object lythander_cathedral_4 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object lythander_cathedral_5 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object lythander_cathedral_6 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object lythander_cathedral_7 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object lythander_cathedral_8 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object lythander_cathedral_9 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object lythander_cathedral_10 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object lythander_cathedral_11 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object lythander_cathedral_12 +name Cathedral of Lythander +type 66 +face lythander_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object lythander_church +editor_folder construct/temple +name Church of Lythander +type 66 +face lythander_church.x11 +no_pick 1 +client_type 25012 +end +More +Object lythander_church_2 +name Church of Lythander +type 66 +face lythander_church.x11 +no_pick 1 +x 1 +end +More +Object lythander_church_3 +name Church of Lythander +type 66 +face lythander_church.x11 +no_pick 1 +y 1 +end +More +Object lythander_church_4 +name Church of Lythander +type 66 +face lythander_church.x11 +no_pick 1 +x 1 +y 1 +end Object mos_temple editor_folder construct/temple name Temple of Mostrai @@ -5480,6 +6464,306 @@ face mos_temple.111 no_pick 1 end +Object mostrai_cathedral +editor_folder construct/temple +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object mostrai_cathedral_2 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object mostrai_cathedral_3 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object mostrai_cathedral_4 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object mostrai_cathedral_5 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object mostrai_cathedral_6 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object mostrai_cathedral_7 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object mostrai_cathedral_8 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object mostrai_cathedral_9 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object mostrai_cathedral_10 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object mostrai_cathedral_11 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object mostrai_cathedral_12 +name Cathedral of Mostrai +type 66 +face mostrai_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object mostrai_church +editor_folder construct/temple +name Church of Mostrai +type 66 +face mostrai_church.x11 +no_pick 1 +client_type 25012 +end +More +Object mostrai_church_2 +name Church of Mostrai +type 66 +face mostrai_church.x11 +no_pick 1 +x 1 +end +More +Object mostrai_church_3 +name Church of Mostrai +type 66 +face mostrai_church.x11 +no_pick 1 +y 1 +end +More +Object mostrai_church_4 +name Church of Mostrai +type 66 +face mostrai_church.x11 +no_pick 1 +x 1 +y 1 +end +Object ruggilli_cathedral +editor_folder construct/temple +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object ruggilli_cathedral_2 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object ruggilli_cathedral_3 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object ruggilli_cathedral_4 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object ruggilli_cathedral_5 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object ruggilli_cathedral_6 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object ruggilli_cathedral_7 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object ruggilli_cathedral_8 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object ruggilli_cathedral_9 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object ruggilli_cathedral_10 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object ruggilli_cathedral_11 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object ruggilli_cathedral_12 +name Cathedral of Ruggilli +type 66 +face ruggilli_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object ruggilli_church +editor_folder construct/temple +name Church of Ruggilli +type 66 +face ruggilli_church.x11 +no_pick 1 +client_type 25012 +end +More +Object ruggilli_church_2 +name Church of Ruggilli +type 66 +face ruggilli_church.x11 +no_pick 1 +x 1 +end +More +Object ruggilli_church_3 +name Church of Ruggilli +type 66 +face ruggilli_church.x11 +no_pick 1 +y 1 +end +More +Object ruggilli_church_4 +name Church of Ruggilli +type 66 +face ruggilli_church.x11 +no_pick 1 +x 1 +y 1 +end +Object ruggilli_temple +editor_folder construct/temple +name Temple of Ruggilli +type 66 +blocksview 1 +face ruggilli_temple.111 +no_pick 1 +end Object shrine editor_folder construct/temple name shrine @@ -5520,6 +6804,160 @@ no_pick 1 y 1 end +Object sorig_cathedral +editor_folder construct/temple +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object sorig_cathedral_2 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object sorig_cathedral_3 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object sorig_cathedral_4 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object sorig_cathedral_5 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object sorig_cathedral_6 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object sorig_cathedral_7 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object sorig_cathedral_8 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object sorig_cathedral_9 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object sorig_cathedral_10 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object sorig_cathedral_11 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object sorig_cathedral_12 +name Cathedral of Sorig +type 66 +face sorig_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object sorig_church +editor_folder construct/temple +name Church of Sorig +type 66 +face sorig_church.x11 +no_pick 1 +client_type 25012 +end +More +Object sorig_church_2 +name Church of Sorig +type 66 +face sorig_church.x11 +no_pick 1 +x 1 +end +More +Object sorig_church_3 +name Church of Sorig +type 66 +face sorig_church.x11 +no_pick 1 +y 1 +end +More +Object sorig_church_4 +name Church of Sorig +type 66 +face sorig_church.x11 +no_pick 1 +x 1 +y 1 +end +Object sorig_temple +editor_folder construct/temple +name Temple of Sorig +type 66 +blocksview 1 +face sorig_temple.111 +no_pick 1 +end Object temple1 editor_folder construct/temple name temple @@ -5590,6 +7028,314 @@ x 1 y 1 end +Object valkyrie_cathedral +editor_folder construct/temple +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object valkyrie_cathedral_2 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object valkyrie_cathedral_3 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object valkyrie_cathedral_4 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object valkyrie_cathedral_5 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object valkyrie_cathedral_6 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object valkyrie_cathedral_7 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object valkyrie_cathedral_8 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object valkyrie_cathedral_9 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object valkyrie_cathedral_10 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object valkyrie_cathedral_11 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object valkyrie_cathedral_12 +name Cathedral of Valkyrie +type 66 +face valkyrie_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object valkyrie_church +editor_folder construct/temple +name Church of Valkyrie +type 66 +face valkyrie_church.x11 +no_pick 1 +client_type 25012 +end +More +Object valkyrie_church_2 +name Church of Valkyrie +type 66 +face valkyrie_church.x11 +no_pick 1 +x 1 +end +More +Object valkyrie_church_3 +name Church of Valkyrie +type 66 +face valkyrie_church.x11 +no_pick 1 +y 1 +end +More +Object valkyrie_church_4 +name Church of Valkyrie +type 66 +face valkyrie_church.x11 +no_pick 1 +x 1 +y 1 +end +Object valkyrie_temple +editor_folder construct/temple +name Temple of Valkyrie +type 66 +blocksview 1 +face valkyrie_temple.111 +no_pick 1 +end +Object valriel_cathedral +editor_folder construct/temple +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +client_type 25012 +end +More +Object valriel_cathedral_2 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 1 +end +More +Object valriel_cathedral_3 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 2 +end +More +Object valriel_cathedral_4 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +y 1 +end +More +Object valriel_cathedral_5 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 1 +end +More +Object valriel_cathedral_6 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 1 +end +More +Object valriel_cathedral_7 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +y 2 +end +More +Object valriel_cathedral_8 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 1 +y 2 +end +More +Object valriel_cathedral_9 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 2 +end +More +Object valriel_cathedral_10 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +y 3 +end +More +Object valriel_cathedral_11 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +x 1 +y 3 +end +More +Object valriel_cathedral_12 +name Cathedral of Valriel +type 66 +face valriel_cathedral.x11 +no_pick 1 +move_block all +x 2 +y 3 +end +Object valriel_church +editor_folder construct/temple +name Church of Valriel +type 66 +face valriel_church.x11 +no_pick 1 +client_type 25012 +end +More +Object valriel_church_2 +name Church of Valriel +type 66 +face valriel_church.x11 +no_pick 1 +x 1 +end +More +Object valriel_church_3 +name Church of Valriel +type 66 +face valriel_church.x11 +no_pick 1 +y 1 +end +More +Object valriel_church_4 +name Church of Valriel +type 66 +face valriel_church.x11 +no_pick 1 +x 1 +y 1 +end +Object valriel_temple +editor_folder construct/temple +name Temple of Valriel +type 66 +blocksview 1 +face valriel_temple.111 +no_pick 1 +end Object city_tower editor_folder construct/tower name tower @@ -6699,6 +8445,74 @@ x 1 y 1 end +Object Dragon Guild +editor_folder construct/town +face dragon_guild.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object dragon_guild_2 +name Dragon Guild +face dragon_guild.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object dragon_guild_3 +name Dragon Guild +face dragon_guild.x11 +type 66 +no_pick 1 +y 1 +end +More +Object dragon_guild_4 +name Dragon Guild +face dragon_guild.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object Dragon Guild 2 +editor_folder construct/town +face dragon_guild2.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object dragon_guild2_2 +name Dragon Guild 2 +face dragon_guild2.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object dragon_guild2_3 +name Dragon Guild 2 +face dragon_guild2.x11 +type 66 +no_pick 1 +y 1 +end +More +Object dragon_guild2_4 +name Dragon Guild 2 +face dragon_guild2.x11 +type 66 +no_pick 1 +x 1 +y 1 +end Object guild editor_folder construct/town face guild.x11 @@ -6733,6 +8547,277 @@ x 1 y 1 end +Object guild2 +editor_folder construct/town +face guild2.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2_2 +name guild2 +face guild2.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2_3 +name guild2 +face guild2.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2_4 +name guild2 +face guild2.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2_fant +editor_folder construct/town +face guild2_fant.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2_2_fant +name guild +face guild2_fant.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2_3_fant +name guild +face guild2_fant.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2_4_fant +name guild +face guild2_fant.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2_northwest +editor_folder construct/town +face guild2_northwest.x11 +type 66 +no_pick 1 +move_block all +end +More +Object guild2_2_northwest +name guild +face guild2_northwest.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2_3_northwest +name guild +face guild2_northwest.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2_4_northwest +name guild +face guild2_northwest.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2_west +editor_folder construct/town +face guild2_west.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2_west_2 +name guild2 +face guild2_west.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2_west_3 +name guild2 +face guild2_west.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2_west_4 +name guild2 +face guild2_west.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guildstorage +editor_folder construct/town +face guild2storage.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guildstorage_2 +name guild storage +face guild2storage.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guildstorage_3 +name guild storage +face guild2storage.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guildstorage_4 +name guild storage +face guild2storage.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2storage_fant +editor_folder construct/town +face guild2storage_fant.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2storage_fant_2 +name guild storage +face guild2storage_fant.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2storage_fant_3 +name guild storage +face guild2storage_fant.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guildstorage_fant_4 +name guild storage +face guild2storage_fant.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2storage_northwest +editor_folder construct/town +face guild2storage_northwest.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2storage_northwest_2 +name guild storage +face guild2storage_northwest.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2storage_northwest_3 +name guild storage +face guild2storage_northwest.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2storage_northwest_4 +name guild storage +face guild2storage_northwest.x11 +type 66 +no_pick 1 +x 1 +y 1 +end +Object guild2storage_west +editor_folder construct/town +face guild2storage_west.x11 +type 66 +no_pick 1 +move_block all +client_type 25012 +end +More +Object guild2storage_west_2 +name guild storage +face guild2storage_west.x11 +type 66 +no_pick 1 +move_block all +x 1 +end +More +Object guild2storage_west_3 +name guild storage +face guild2storage_west.x11 +type 66 +no_pick 1 +y 1 +end +More +Object guild2storage_west_4 +name guild storage +face guild2storage_west.x11 +type 66 +no_pick 1 +x 1 +y 1 +end Object guild_fant editor_folder construct/town face guild_fant.x11 @@ -9030,6 +11115,116 @@ no_pick 1 y 2 end +Object lockable_hdoor +editor_folder door/door +msg +This door is locked. +endmsg +name unlocked door +move_block 0 +face unlocked_hwooddoor.111 +randomitems lockable_door +hp 400 +exp 100 +ac 20 +type 20 +material 2 +no_pick 1 +level 1 +lockable 1 +other_arch lockable_hdoor_locked +end +Object lockable_hdoor_locked +editor_folder door/door +msg +This door is locked. +endmsg +name locked door +face locked_hwooddoor.111 +randomitems lockable_door +hp 400 +exp 100 +ac 20 +move_block all +alive 1 +type 20 +material 2 +no_pick 1 +level 1 +lockable 1 +other_arch lockable_hdoor +end +Object lockable_vdoor +editor_folder door/door +msg +This door is locked. +endmsg +name unlocked door +move_block 0 +face unlocked_vwooddoor.111 +randomitems lockable_door +hp 400 +exp 100 +ac 20 +type 20 +material 2 +no_pick 1 +level 1 +lockable 1 +other_arch lockable_vdoor_locked +end +Object lockable_vdoor_locked +editor_folder door/door +msg +This door is locked. +endmsg +name locked door +face locked_vwooddoor.111 +randomitems lockable_door +hp 400 +exp 100 +ac 20 +move_block all +alive 1 +type 20 +material 2 +no_pick 1 +level 1 +lockable 1 +other_arch lockable_vdoor +end +Object locking_key +editor_folder door/door +race keys +face key1.111 +material 2 +value 10 +weight 10 +name locking key +name_pl locking keys +client_type 801 +randomitems locking_key +end +Object locking_key_apply +editor_folder door/door +face event_apply.111 +type 116 +subtype 1 +invisible 1 +no_drop 1 +title Python +slaying /python/items/lockable_doors.py +end +Object lockable_door_trigger +editor_folder door/door +face event_trigger.111 +type 116 +subtype 10 +invisible 1 +no_drop 1 +title Python +slaying /python/items/lockable_doors.py +end Object door_1 editor_folder door/door name door @@ -9739,6 +11934,25 @@ no_pick 1 client_type 25012 end +Object archway_black +editor_folder exit/exit +name dark archway +face archblack.111 +animation archblack +type 66 +no_pick 1 +client_type 25012 +anim_speed 3 +client_anim_random 1 +end +Object bloodwell +editor_folder exit/exit +type 66 +face bloodwell.111 +no_pick 1 +editable 2 +client_type 25012 +end Object chole_1 editor_folder exit/exit name hole in the ground @@ -11703,6 +13917,14 @@ is_floor 1 smoothlevel 30 end +Object woodfloorvert +editor_folder floor/floor +name wood floor vertical +face woodfloorvert.111 +no_pick 1 +is_floor 1 +smoothlevel 30 +end Object woodlarge editor_folder floor/floor name wood floor @@ -11712,6 +13934,15 @@ smoothlevel 30 move_block boat swim end +Object woodlgvertical +editor_folder floor/floor +name wood floor vertical +face woodlargevertical.111 +no_pick 1 +is_floor 1 +smoothlevel 30 +move_block boat swim +end Object apple editor_folder food/food face apple.111 @@ -11771,6 +14002,7 @@ editor_folder food/food name bag of popcorn face bag_popcorn.111 +on_use_yield bag_empty food 50 nrof 1 type 6 @@ -12596,6 +14828,9 @@ face altargoro.111 no_pick 1 level 100 +anim_speed 0.5 +animation altar_gorokh +speed 0.5 end Object altar_ixalovh editor_folder gods/altars @@ -12682,6 +14917,10 @@ face altarvalr.111 no_pick 1 resist_physical 100 +anim_speed 0.5 +animation altar_valriel +anim_suffix intervention +speed 0.5 end Object Gnarg editor_folder gods/demihumans @@ -13673,7 +15912,7 @@ animation mithril_ar_ele anim_speed 3 client_anim_random 1 -ac 4 +ac 6 resist_physical 40 resist_electricity 40 startequip 1 @@ -14873,6 +17112,18 @@ no_pick 1 is_water 1 end +Object rain +editor_folder ground/Weather +name rain +face rain.111 +animation rain +material 512 +no_pick 1 +is_water 1 +map_layer fly +anim_speed 1 +client_anim_random 1 +end Object rain1 editor_folder ground/Weather name puddle @@ -14882,10 +17133,15 @@ end Object rain2 editor_folder ground/Weather -name puddle -face rain2.111 +name rain +face rain.111 +animation rain +material 512 no_pick 1 is_water 1 +map_layer fly +anim_speed 1 +client_anim_random 1 end Object rain3 editor_folder ground/Weather @@ -14903,11 +17159,23 @@ end Object rain5 editor_folder ground/Weather -name big puddle -face rain5.111 +name puddle +face rain2.111 no_pick 1 is_water 1 end +Object snow_c +editor_folder ground/Weather +name snow +face snow_c.111 +animation snow_c +materialname ice +no_pick 1 +is_water 1 +map_layer fly +anim_speed 3 +client_anim_random 1 +end Object cforest1 editor_folder ground/Winter face cforest1.111 @@ -16563,7 +18831,6 @@ move_slow walk move_slow_penalty 15 is_hilly 1 -speed -0.02 move_block boat swim x 1 end @@ -16591,17 +18858,11 @@ editor_folder indoor/indoor name bed face bed_1.111 -type 15 -dam 12 -last_sp 19 weight 200000 value 35 material 16 -nrof 1 name_pl beds client_type 8002 -body_arm -2 -skill two handed weapons end Object bed_save editor_folder indoor/indoor @@ -16619,448 +18880,286 @@ editor_folder indoor/indoor face chair.111 weight 40000 -last_sp 16 value 20 -type 15 material 16 -dam 4 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_1.1 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_1.101 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_1.2 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_1.111 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_1.3 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_1.121 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_1.4 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_1.131 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_2.1 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_2.101 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_2.2 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_2.111 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_2.3 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_2.121 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_2.4 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_2.131 value 25 -type 15 material 16 -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_3.1 editor_folder indoor/indoor name chair weight 60000 -last_sp 19 face chair_3.101 value 25 -type 15 material 16 -dam 6 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_3.2 editor_folder indoor/indoor name chair weight 60000 -last_sp 19 face chair_3.111 value 25 -type 15 material 16 -dam 6 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_bc_2.1 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_bc_2.101 value 1600 -type 15 material 16 materialname satin covered wood -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_bc_2.2 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_bc_2.111 value 1600 -type 15 material 16 materialname satin covered wood -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_bc_2.3 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_bc_2.121 value 1600 -type 15 material 16 materialname satin covered wood -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_bc_2.4 editor_folder indoor/indoor name chair weight 50000 -last_sp 18 face chair_bc_2.131 value 1600 -type 15 material 16 materialname satin covered wood -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_cw_1.1 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_cw_1.101 value 150 -type 15 material 16 materialname cherry -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_cw_1.2 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_cw_1.111 value 150 -type 15 material 16 materialname cherry -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_cw_1.3 editor_folder indoor/indoor name chair weight 45000 -last_sp 17 face chair_cw_1.121 value 150 -type 15 material 16 materialname cherry -dam 5 -nrof 1 name_pl chairs client_type 8002 -skill two handed weapons -body_arm -2 end Object chair_cw_1.4 editor_folder indoor/indoor name chair weight 45... [truncated message content] |
From: <aki...@us...> - 2013-01-03 20:10:44
|
Revision: 9205 http://gridarta.svn.sourceforge.net/gridarta/?rev=9205&view=rev Author: akirschbaum Date: 2013-01-03 20:10:36 +0000 (Thu, 03 Jan 2013) Log Message: ----------- Do not disable map cursor in "enter xyz map". Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/crossfire/ChangeLog trunk/daimonin/ChangeLog trunk/src/app/net/sf/gridarta/gui/map/mapactions/EnterMap.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) +++ trunk/atrinik/ChangeLog 2013-01-03 20:10:36 UTC (rev 9205) @@ -1,3 +1,7 @@ +2013-01-03 Andreas Kirschbaum + + * Do not disable map cursor in "enter xyz map". + 2012-09-08 Andreas Kirschbaum * Fix ClassCastException when iconifying map views. Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) +++ trunk/crossfire/ChangeLog 2013-01-03 20:10:36 UTC (rev 9205) @@ -1,3 +1,7 @@ +2013-01-03 Andreas Kirschbaum + + * Do not disable map cursor in "enter xyz map". + 2012-09-08 Andreas Kirschbaum * Fix ClassCastException when iconifying map views. Modified: trunk/daimonin/ChangeLog =================================================================== --- trunk/daimonin/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) +++ trunk/daimonin/ChangeLog 2013-01-03 20:10:36 UTC (rev 9205) @@ -1,3 +1,7 @@ +2013-01-03 Andreas Kirschbaum + + * Do not disable map cursor in "enter xyz map". + 2012-09-08 Andreas Kirschbaum * Fix ClassCastException when iconifying map views. Modified: trunk/src/app/net/sf/gridarta/gui/map/mapactions/EnterMap.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/mapactions/EnterMap.java 2012-09-08 14:46:36 UTC (rev 9204) +++ trunk/src/app/net/sf/gridarta/gui/map/mapactions/EnterMap.java 2013-01-03 20:10:36 UTC (rev 9205) @@ -41,6 +41,7 @@ import net.sf.gridarta.model.mappathnormalizer.MapPathNormalizer; import net.sf.gridarta.model.mappathnormalizer.RelativePathOnUnsavedMapException; import net.sf.gridarta.model.mappathnormalizer.SameMapException; +import net.sf.gridarta.utils.Size2D; import net.sf.japi.swing.action.ActionBuilder; import net.sf.japi.swing.action.ActionBuilderFactory; import org.jetbrains.annotations.NotNull; @@ -110,7 +111,7 @@ * @param path path to map that should be loaded * @param direction the direction to go * @param destinationPoint the desired destination point on the map (pass - * 0|0 if unknown, and note that the point gets modified) + * <code>null</code> if unknown, and note that the point gets modified) * @return whether the destination map has been entered */ public boolean enterMap(@NotNull final MapView<G, A, R> mapView, @NotNull final String path, @NotNull final Direction direction, @Nullable final Point destinationPoint) { @@ -159,6 +160,10 @@ showLocation(newMapView, destinationPoint); } else if (mapView != null) { newMapView.getScrollPane().getViewport().setViewPosition(calculateNewViewPosition(mapView.getScrollPane(), newMapView.getScrollPane(), direction)); + final Point newCursorLocation = calculateNewCursorLocation(mapView, newMapView, direction); + if (newCursorLocation != null) { + newMapView.getMapCursor().setLocation(newCursorLocation); + } } if (mapView != null && ACTION_BUILDER.showOnetimeConfirmDialog(parent, JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE, "enterExitClose") == JOptionPane.YES_OPTION) { @@ -269,4 +274,53 @@ return scrollTo.getLocation(); } + /** + * Calculate the map cursor location for the new viewport. + * @param oldMapView the old map view + * @param newMapView the new map view + * @param direction the direction to scroll + * @return the new map cursor location + * @noinspection TypeMayBeWeakened + */ + @Nullable + private Point calculateNewCursorLocation(@Nullable final MapView<G, A, R> oldMapView, @NotNull final MapView<G, A, R> newMapView, @NotNull final Direction direction) { + if (oldMapView == null) { + return null; + } + final Point oldCursorLocation = oldMapView.getMapCursor().getLocation(); + if (oldCursorLocation == null) { + return null; + } + + final Size2D mapSize = newMapView.getMapControl().getMapModel().getMapArchObject().getMapSize(); + switch (direction) { + case SOUTH: + return new Point(oldCursorLocation.x, 0); + + case NORTH: + return new Point(oldCursorLocation.x, mapSize.getHeight() - 1); + + case EAST: + return new Point(0, oldCursorLocation.y); + + case WEST: + return new Point(mapSize.getWidth() - 1, oldCursorLocation.y); + + case NORTH_EAST: + return new Point(0, mapSize.getHeight() - 1); + + case SOUTH_EAST: + return new Point(0, 0); + + case SOUTH_WEST: + return new Point(mapSize.getWidth() - 1, 0); + + case NORTH_WEST: + return new Point(mapSize.getWidth() - 1, mapSize.getHeight() - 1); + + default: + throw new AssertionError(); + } + } + } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-09-08 14:46:43
|
Revision: 9204 http://gridarta.svn.sourceforge.net/gridarta/?rev=9204&view=rev Author: akirschbaum Date: 2012-09-08 14:46:36 +0000 (Sat, 08 Sep 2012) Log Message: ----------- Fix ClassCastException when iconifying map views. Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/crossfire/ChangeLog trunk/daimonin/ChangeLog trunk/src/app/net/sf/gridarta/gui/mapdesktop/MapDesktop.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-08-02 18:16:11 UTC (rev 9203) +++ trunk/atrinik/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) @@ -1,3 +1,7 @@ +2012-09-08 Andreas Kirschbaum + + * Fix ClassCastException when iconifying map views. + 2012-07-19 Andreas Kirschbaum * Fix "Open In Client" on Windows machines. Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2012-08-02 18:16:11 UTC (rev 9203) +++ trunk/crossfire/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) @@ -1,3 +1,7 @@ +2012-09-08 Andreas Kirschbaum + + * Fix ClassCastException when iconifying map views. + 2012-06-17 Andreas Kirschbaum * Do not crash when shrinking a map if the map cursor is within Modified: trunk/daimonin/ChangeLog =================================================================== --- trunk/daimonin/ChangeLog 2012-08-02 18:16:11 UTC (rev 9203) +++ trunk/daimonin/ChangeLog 2012-09-08 14:46:36 UTC (rev 9204) @@ -1,3 +1,7 @@ +2012-09-08 Andreas Kirschbaum + + * Fix ClassCastException when iconifying map views. + 2012-06-17 Andreas Kirschbaum * Do not crash when shrinking a map if the map cursor is within Modified: trunk/src/app/net/sf/gridarta/gui/mapdesktop/MapDesktop.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapdesktop/MapDesktop.java 2012-08-02 18:16:11 UTC (rev 9203) +++ trunk/src/app/net/sf/gridarta/gui/mapdesktop/MapDesktop.java 2012-09-08 14:46:36 UTC (rev 9204) @@ -471,9 +471,6 @@ @Override public void internalFrameIconified(@NotNull final InternalFrameEvent e) { - //InternalFrameEvent does not use type parameters - @SuppressWarnings("unchecked") - final MapView<G, A, R> mapView = (MapView<G, A, R>) e.getSource(); mapViewFocusLostNotify(mapView); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <sm...@us...> - 2012-08-02 18:16:18
|
Revision: 9203 http://gridarta.svn.sourceforge.net/gridarta/?rev=9203&view=rev Author: smacky Date: 2012-08-02 18:16:11 +0000 (Thu, 02 Aug 2012) Log Message: ----------- Update help. Modified Paths: -------------- trunk/daimonin/resource/resource/HelpFiles/tut_mapattr.html Modified: trunk/daimonin/resource/resource/HelpFiles/tut_mapattr.html =================================================================== --- trunk/daimonin/resource/resource/HelpFiles/tut_mapattr.html 2012-07-19 21:34:53 UTC (rev 9202) +++ trunk/daimonin/resource/resource/HelpFiles/tut_mapattr.html 2012-08-02 18:16:11 UTC (rev 9203) @@ -59,19 +59,25 @@ set. These coordinates are also used to re-insert players after map reset when "Fixed Login" is enabled.</P> +<P><B>Swap Time</B>: This is how many seconds must elapse after the map has + not been used before it gets swapped out (saved to disk with certain + dynamic objects -- eg, spell effects, spawned mobs -- removed). A swapped + out map will get loaded back into memory if someone re-visits it before it + is reset (see below).For instance, if set to 300, the map will be swapped + out after 5 minutes. The server has a min and max time which will override + the map time if the map time is lower or higher, respecrively. If set to 0, + a server default value is applied (recommended).<BR />Don't modify this + value unless you know exactly what you're doing.</P> + <P><B>Reset Timeout</B>: Stores the number of seconds that need to elapse before - this map will be reset. For instance, if set to 1800, the map expires after - 30 minutes. If set to zero, a default value is applied.</P> + this map will be reset (it is deleted from memory and will be reloaded from + the original in the maps directory next time it is needed). For instance, + if set to 1800, the map expires after 30 minutes. The server has a max time + which will override the map time if the map time is higher. If set to 0, a + server default value is applied (recommended). And if set to -1, the map + will <I>never</I> reset.<BR />Don't modify this value unless you know + exactly what you're doing.</P> -<P><B>Swap Time</B>: This controls how many ticks must elapse after the map has - not been used before it gets swapped out. swapping out is different than - reset, as a swapped out map will get loaded back into memory if someone - re-visits it before it is reset. Zero means the server takes a certain - default value. - <br> - Don't modify this value unless you know exactly what you're doing. -</P> - <P><B>Difficulty</B>: This value stores the map difficulty. If set to zero, the server code will try to come up with a reasonable difficulty value.</P> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-19 21:35:00
|
Revision: 9202 http://gridarta.svn.sourceforge.net/gridarta/?rev=9202&view=rev Author: akirschbaum Date: 2012-07-19 21:34:53 +0000 (Thu, 19 Jul 2012) Log Message: ----------- Show proper map paths in map window titles. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/map/mapview/DefaultMapView.java Modified: trunk/src/app/net/sf/gridarta/gui/map/mapview/DefaultMapView.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/mapview/DefaultMapView.java 2012-07-19 21:28:47 UTC (rev 9201) +++ trunk/src/app/net/sf/gridarta/gui/map/mapview/DefaultMapView.java 2012-07-19 21:34:53 UTC (rev 9202) @@ -289,7 +289,14 @@ @NotNull private static String getWindowTitle(@NotNull final MapControl<?, ?, ?> mapControl, final int number, @NotNull final PathManager pathManager) { final File mapFile = mapControl.getMapModel().getMapFile(); - return (mapFile == null ? "<unsaved>" : pathManager.getMapPath(mapFile)) + " [ " + mapControl.getMapModel().getMapArchObject().getMapName() + " ] (" + number + ")" + (mapControl.getMapModel().isModified() ? " *" : ""); + final String mapPath; + if (mapFile == null) { + mapPath = "<unsaved>"; + } else { + final String tmp = pathManager.getMapPath2(mapFile); + mapPath = tmp == null ? mapFile.getPath() : tmp; + } + return mapPath + " [ " + mapControl.getMapModel().getMapArchObject().getMapName() + " ] (" + number + ")" + (mapControl.getMapModel().isModified() ? " *" : ""); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-19 21:28:54
|
Revision: 9201 http://gridarta.svn.sourceforge.net/gridarta/?rev=9201&view=rev Author: akirschbaum Date: 2012-07-19 21:28:47 +0000 (Thu, 19 Jul 2012) Log Message: ----------- Fix "Open In Client" on Windows machines. Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-07-19 21:27:24 UTC (rev 9200) +++ trunk/atrinik/ChangeLog 2012-07-19 21:28:47 UTC (rev 9201) @@ -1,3 +1,7 @@ +2012-07-19 Andreas Kirschbaum + + * Fix "Open In Client" on Windows machines. + 2012-07-17 Andreas Kirschbaum * Implement "Map|Open In Client". Teleports a character on the Modified: trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java =================================================================== --- trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java 2012-07-19 21:27:24 UTC (rev 9200) +++ trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java 2012-07-19 21:28:47 UTC (rev 9201) @@ -137,7 +137,8 @@ if (!canonicalFile.startsWith(canonicalMaps)) { return null; } - return getMapPath(file); + final String mapPath = canonicalFile.substring(canonicalMaps.length()); + return mapPath.replace('\\', '/'); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-19 21:27:31
|
Revision: 9200 http://gridarta.svn.sourceforge.net/gridarta/?rev=9200&view=rev Author: akirschbaum Date: 2012-07-19 21:27:24 +0000 (Thu, 19 Jul 2012) Log Message: ----------- Make regression tests locale independent. Modified Paths: -------------- trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java Modified: trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java =================================================================== --- trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java 2012-07-17 20:52:16 UTC (rev 9199) +++ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java 2012-07-19 21:27:24 UTC (rev 9200) @@ -20,6 +20,7 @@ package net.sf.gridarta.var.atrinik.gui.map.renderer; import java.awt.Graphics2D; +import java.util.Locale; import javax.swing.Icon; import net.sf.gridarta.gui.filter.FilterControl; import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; @@ -99,7 +100,7 @@ * @param value the double value */ private void appendDouble(final double value) { - sb.append(String.format("%.03g", value)); + sb.append(String.format((Locale) null, "%.03g", value)); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-17 20:52:24
|
Revision: 9199 http://gridarta.svn.sourceforge.net/gridarta/?rev=9199&view=rev Author: akirschbaum Date: 2012-07-17 20:52:16 +0000 (Tue, 17 Jul 2012) Log Message: ----------- Implement "Map|Open In Client". [Atrinik] Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/action.properties trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/maincontrol/DefaultEditorFactory.java trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/maincontrol/DefaultEditorFactory.java trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/maincontrol/DefaultEditorFactory.java trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java trunk/model/src/app/net/sf/gridarta/model/mapmanager/FileControl.java trunk/model/src/test/net/sf/gridarta/model/mapmanager/TestFileControl.java trunk/src/app/net/sf/gridarta/gui/misc/DefaultFileControl.java trunk/src/app/net/sf/gridarta/maincontrol/EditorFactory.java trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java trunk/src/app/net/sf/gridarta/messages.properties trunk/src/app/net/sf/gridarta/messages_de.properties trunk/src/app/net/sf/gridarta/messages_fr.properties trunk/src/app/net/sf/gridarta/messages_sv.properties Added Paths: ----------- trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/ trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/AtrinikServerActions.java trunk/src/app/net/sf/gridarta/actions/AbstractServerActions.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/atrinik/ChangeLog 2012-07-17 20:52:16 UTC (rev 9199) @@ -1,3 +1,8 @@ +2012-07-17 Andreas Kirschbaum + + * Implement "Map|Open In Client". Teleports a character on the + local server (running on 127.0.0.1) to the current map. + 2012-06-17 Andreas Kirschbaum * Do not crash when shrinking a map if the map cursor is within Modified: trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/action.properties =================================================================== --- trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/action.properties 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/action.properties 2012-07-17 20:52:16 UTC (rev 9199) @@ -42,7 +42,7 @@ mapwindowFile.menu=saveMap saveMapAs createImage - reloadMap - closeMap mapwindowEdit.menu=undo redo - clear cut copy paste pasteTiled - shift - find findNext findPrev replace fillAuto fillAbove fillBelow randFillAuto randFillAbove randFillBelow floodFill - selectAll invertSelection expandEmptySelection growSelection shrinkSelection -mapwindowMap.menu=gridVisible lightVisible - goExit enterExit nextExit prevExit enterNorthMap enterEastMap enterSouthMap enterWestMap enterNorthEastMap enterSouthEastMap enterSouthWestMap enterNorthWestMap - mapCreateView mapProperties shrinkMapSize deleteUnknownObjects +mapwindowMap.menu=gridVisible lightVisible - goExit enterExit nextExit prevExit enterNorthMap enterEastMap enterSouthMap enterWestMap enterNorthEastMap enterSouthEastMap enterSouthWestMap enterNorthWestMap - mapCreateView mapProperties shrinkMapSize deleteUnknownObjects openInClient mapwindowCursor.menu=moveCursor - exitConnector - selectSquare startStopDrag addToSelection subFromSelection releaseDrag - insertArch deleteArch - selectArchAbove selectArchBelow - archAttributes ########## Added: trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/AtrinikServerActions.java =================================================================== --- trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/AtrinikServerActions.java (rev 0) +++ trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/AtrinikServerActions.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -0,0 +1,110 @@ +/* + * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. + * Copyright (C) 2000-2011 The Gridarta Developers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +package net.sf.gridarta.var.atrinik.actions; + +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.OutputStream; +import java.net.Socket; +import net.sf.gridarta.actions.AbstractServerActions; +import net.sf.gridarta.gui.map.mapview.MapViewManager; +import net.sf.gridarta.model.io.PathManager; +import net.sf.gridarta.model.mapmanager.FileControl; +import net.sf.gridarta.var.atrinik.model.archetype.Archetype; +import net.sf.gridarta.var.atrinik.model.gameobject.GameObject; +import net.sf.gridarta.var.atrinik.model.maparchobject.MapArchObject; +import org.jetbrains.annotations.NotNull; + +/** + * The {@link AbstractServerActions} implementation for connecting to an Atrinik + * server. + * @author Andreas Kirschbaum + */ +public class AtrinikServerActions extends AbstractServerActions<GameObject, MapArchObject, Archetype> { + + /** + * Command type. + */ + private static final int SERVER_CMD_CONTROL = 0; + + /** + * The name of the application requesting control. + */ + @NotNull + private static final String APPLICATION_NAME_IDENTIFIER = "gridarta"; + + /** + * The charset name for encoding strings in the protocol. + */ + @NotNull + private static final String CHARSET_NAME = "US-ASCII"; + + /** + * Command sub-type: teleport character to map. + */ + private static final int CMD_CONTROL_UPDATE_MAP = 1; + + /** + * Creates a new instance. + * @param mapViewManager the map view manager for tracking the current map + * view + * @param fileControl the file control for saving maps + * @param pathManager the path manager for converting path names + */ + public AtrinikServerActions(@NotNull final MapViewManager<GameObject, MapArchObject, Archetype> mapViewManager, @NotNull final FileControl<GameObject, MapArchObject, Archetype> fileControl, @NotNull final PathManager pathManager) { + super(mapViewManager, fileControl, pathManager); + } + + /** + * {@inheritDoc} + */ + @Override + protected void teleportCharacterToMap(@NotNull final String mapPath, final int mapX, final int mapY) throws IOException { + final ByteArrayOutputStream tmp = new ByteArrayOutputStream(); + tmp.write(0); + tmp.write(0); + tmp.write(SERVER_CMD_CONTROL); + tmp.write(APPLICATION_NAME_IDENTIFIER.getBytes(CHARSET_NAME)); + tmp.write(0); // termination of application name identifier + tmp.write(CMD_CONTROL_UPDATE_MAP); + tmp.write(mapPath.getBytes(CHARSET_NAME)); + tmp.write(0); + tmp.write(mapX >> 8); + tmp.write(mapX); + tmp.write(mapY >> 8); + tmp.write(mapY); + final byte[] packet = tmp.toByteArray(); + packet[0] = (byte) ((packet.length - 2) >> 8); + packet[1] = (byte) (packet.length - 2); + try { + final Socket socket = new Socket("127.0.0.1", 13327); + try { + final OutputStream outputStream = socket.getOutputStream(); + outputStream.write(packet); + socket.shutdownOutput(); + } finally { + socket.close(); + } + } catch (final IOException ex) { + throw new IOException("127.0.0.1:13327: " + ex.getMessage(), ex); + } + } + +} Property changes on: trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/actions/AtrinikServerActions.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + LF Modified: trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/maincontrol/DefaultEditorFactory.java =================================================================== --- trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/maincontrol/DefaultEditorFactory.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/atrinik/src/app/net/sf/gridarta/var/atrinik/maincontrol/DefaultEditorFactory.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -36,6 +36,7 @@ import net.sf.gridarta.gui.filter.FilterControl; import net.sf.gridarta.gui.map.mapview.DefaultMapViewFactory; import net.sf.gridarta.gui.map.mapview.MapViewFactory; +import net.sf.gridarta.gui.map.mapview.MapViewManager; import net.sf.gridarta.gui.map.mapview.MapViewsManager; import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; import net.sf.gridarta.gui.map.renderer.RendererFactory; @@ -74,6 +75,7 @@ import net.sf.gridarta.model.maparchobject.MapArchObjectFactory; import net.sf.gridarta.model.mapcontrol.MapControlFactory; import net.sf.gridarta.model.mapmanager.AbstractMapManager; +import net.sf.gridarta.model.mapmanager.FileControl; import net.sf.gridarta.model.mapmanager.MapManager; import net.sf.gridarta.model.mapmodel.InsertionMode; import net.sf.gridarta.model.mapmodel.MapModelFactory; @@ -103,6 +105,7 @@ import net.sf.gridarta.utils.IOUtils; import net.sf.gridarta.utils.SystemIcons; import net.sf.gridarta.var.atrinik.IGUIConstants; +import net.sf.gridarta.var.atrinik.actions.AtrinikServerActions; import net.sf.gridarta.var.atrinik.gui.map.renderer.DefaultRendererFactory; import net.sf.gridarta.var.atrinik.gui.mappropertiesdialog.DefaultMapPropertiesDialogFactory; import net.sf.gridarta.var.atrinik.gui.scripts.DefaultScriptArchUtils; @@ -480,4 +483,12 @@ return new DefaultResources(gameObjectParser, archetypeSet, archetypeParser, mapViewSettings, faceObjects, animationObjects, archFaceProvider, faceObjectProviders); } + /** + * {@inheritDoc} + */ + @Override + public void newServerActions(@NotNull final MapViewManager<GameObject, MapArchObject, Archetype> mapViewManager, @NotNull final FileControl<GameObject, MapArchObject, Archetype> fileControl, @NotNull final PathManager pathManager) { + new AtrinikServerActions(mapViewManager, fileControl, pathManager); + } + } Modified: trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/maincontrol/DefaultEditorFactory.java =================================================================== --- trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/maincontrol/DefaultEditorFactory.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/maincontrol/DefaultEditorFactory.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -34,6 +34,7 @@ import net.sf.gridarta.gui.filter.FilterControl; import net.sf.gridarta.gui.map.mapview.DefaultMapViewFactory; import net.sf.gridarta.gui.map.mapview.MapViewFactory; +import net.sf.gridarta.gui.map.mapview.MapViewManager; import net.sf.gridarta.gui.map.mapview.MapViewsManager; import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; import net.sf.gridarta.gui.map.renderer.RendererFactory; @@ -69,6 +70,7 @@ import net.sf.gridarta.model.maparchobject.MapArchObjectFactory; import net.sf.gridarta.model.mapcontrol.MapControlFactory; import net.sf.gridarta.model.mapmanager.AbstractMapManager; +import net.sf.gridarta.model.mapmanager.FileControl; import net.sf.gridarta.model.mapmanager.MapManager; import net.sf.gridarta.model.mapmodel.InsertionMode; import net.sf.gridarta.model.mapmodel.MapModelFactory; @@ -393,4 +395,12 @@ return new DefaultResources(gameObjectParser, archetypeSet, archetypeParser, mapViewSettings, faceObjects, animationObjects, smoothFaces, archFaceProvider, faceObjectProviders); } + /** + * {@inheritDoc} + */ + @Override + public void newServerActions(@NotNull final MapViewManager<GameObject, MapArchObject, Archetype> mapViewManager, @NotNull final FileControl<GameObject, MapArchObject, Archetype> fileControl, @NotNull final PathManager pathManager) { + // do nothing: action not supported + } + } Modified: trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/maincontrol/DefaultEditorFactory.java =================================================================== --- trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/maincontrol/DefaultEditorFactory.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/daimonin/src/app/net/sf/gridarta/var/daimonin/maincontrol/DefaultEditorFactory.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -36,6 +36,7 @@ import net.sf.gridarta.gui.filter.FilterControl; import net.sf.gridarta.gui.map.mapview.DefaultMapViewFactory; import net.sf.gridarta.gui.map.mapview.MapViewFactory; +import net.sf.gridarta.gui.map.mapview.MapViewManager; import net.sf.gridarta.gui.map.mapview.MapViewsManager; import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; import net.sf.gridarta.gui.map.renderer.RendererFactory; @@ -74,6 +75,7 @@ import net.sf.gridarta.model.maparchobject.MapArchObjectFactory; import net.sf.gridarta.model.mapcontrol.MapControlFactory; import net.sf.gridarta.model.mapmanager.AbstractMapManager; +import net.sf.gridarta.model.mapmanager.FileControl; import net.sf.gridarta.model.mapmanager.MapManager; import net.sf.gridarta.model.mapmodel.InsertionMode; import net.sf.gridarta.model.mapmodel.MapModelFactory; @@ -480,4 +482,12 @@ return new DefaultResources(gameObjectParser, archetypeSet, archetypeParser, mapViewSettings, faceObjects, animationObjects, archFaceProvider, faceObjectProviders); } + /** + * {@inheritDoc} + */ + @Override + public void newServerActions(@NotNull final MapViewManager<GameObject, MapArchObject, Archetype> mapViewManager, @NotNull final FileControl<GameObject, MapArchObject, Archetype> fileControl, @NotNull final PathManager pathManager) { + // do nothing: action not supported + } + } Modified: trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java =================================================================== --- trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/model/src/app/net/sf/gridarta/model/io/PathManager.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -25,6 +25,7 @@ import net.sf.gridarta.model.settings.GlobalSettings; import net.sf.gridarta.utils.StringUtils; import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; /** * This class contains methods for converting relative map paths to absolute map @@ -118,6 +119,28 @@ } /** + * Returns a map path for a {@link File}. + * @param file the file + * @return the map path or <code>null</code> if the file is not within the + * maps directory + */ + @Nullable + public String getMapPath2(@NotNull final File file) { + final String canonicalFile; + final String canonicalMaps; + try { + canonicalFile = file.getCanonicalPath(); + canonicalMaps = globalSettings.getMapsDirectory().getCanonicalPath(); + } catch (final IOException ignored) { + return null; + } + if (!canonicalFile.startsWith(canonicalMaps)) { + return null; + } + return getMapPath(file); + } + + /** * Check whether a path is absolute. Paths starting with "/" are absolute, * paths starting with other characters are relative. Empty paths are * relative. Modified: trunk/model/src/app/net/sf/gridarta/model/mapmanager/FileControl.java =================================================================== --- trunk/model/src/app/net/sf/gridarta/model/mapmanager/FileControl.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/model/src/app/net/sf/gridarta/model/mapmanager/FileControl.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -94,4 +94,11 @@ void reportOutOfMemory(@NotNull File file); + /** + * Reports an error while teleporting a character to the current map. + * @param mapPath the map path to teleport to + * @param message the error message + */ + void reportTeleportCharacterError(@NotNull String mapPath, @NotNull String message); + } Modified: trunk/model/src/test/net/sf/gridarta/model/mapmanager/TestFileControl.java =================================================================== --- trunk/model/src/test/net/sf/gridarta/model/mapmanager/TestFileControl.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/model/src/test/net/sf/gridarta/model/mapmanager/TestFileControl.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -143,6 +143,14 @@ * {@inheritDoc} */ @Override + public void reportTeleportCharacterError(@NotNull final String mapPath, @NotNull final String message) { + throw new AssertionError(); + } + + /** + * {@inheritDoc} + */ + @Override public String toString() { return sb.toString(); } Added: trunk/src/app/net/sf/gridarta/actions/AbstractServerActions.java =================================================================== --- trunk/src/app/net/sf/gridarta/actions/AbstractServerActions.java (rev 0) +++ trunk/src/app/net/sf/gridarta/actions/AbstractServerActions.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -0,0 +1,195 @@ +/* + * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. + * Copyright (C) 2000-2011 The Gridarta Developers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +package net.sf.gridarta.actions; + +import java.awt.Point; +import java.io.File; +import java.io.IOException; +import javax.swing.Action; +import net.sf.gridarta.gui.map.mapview.MapView; +import net.sf.gridarta.gui.map.mapview.MapViewManager; +import net.sf.gridarta.gui.map.mapview.MapViewManagerListener; +import net.sf.gridarta.model.archetype.Archetype; +import net.sf.gridarta.model.gameobject.GameObject; +import net.sf.gridarta.model.io.PathManager; +import net.sf.gridarta.model.maparchobject.MapArchObject; +import net.sf.gridarta.model.mapcontrol.MapControl; +import net.sf.gridarta.model.mapmanager.FileControl; +import net.sf.gridarta.model.mapmodel.MapModel; +import net.sf.gridarta.utils.ActionUtils; +import net.sf.japi.swing.action.ActionBuilder; +import net.sf.japi.swing.action.ActionBuilderFactory; +import net.sf.japi.swing.action.ActionMethod; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Actions that require a connection to a game server. + * @author Andreas Kirschbaum + * @noinspection AbstractClassWithOnlyOneDirectInheritor + */ +public abstract class AbstractServerActions<G extends GameObject<G, A, R>, A extends MapArchObject<A>, R extends Archetype<G, A, R>> { + + /** + * Action Builder to create Actions. + */ + @NotNull + private static final ActionBuilder ACTION_BUILDER = ActionBuilderFactory.getInstance().getActionBuilder("net.sf.gridarta"); + + /** + * The currently active map or <code>null</code> if no map is active. + */ + @Nullable + private MapView<G, A, R> currentMapView; + + /** + * The file control for saving maps. + */ + @NotNull + private final FileControl<G, A, R> fileControl; + + /** + * The {@link PathManager} for converting path names. + */ + @NotNull + private final PathManager pathManager; + + /** + * The action for "open in client". + * @noinspection ThisEscapedInObjectConstruction + */ + @NotNull + private final Action aOpenInClient = ActionUtils.newAction(ACTION_BUILDER, "Map", this, "openInClient"); + + /** + * The map manager listener which is attached to the current map if the + * current map is tracked. Otherwise it is unused. + * @noinspection FieldCanBeLocal + */ + @NotNull + private final MapViewManagerListener<G, A, R> mapViewManagerListener = new MapViewManagerListener<G, A, R>() { + + @Override + public void activeMapViewChanged(@Nullable final MapView<G, A, R> mapView) { + currentMapView = mapView; + updateActions(); + } + + @Override + public void mapViewCreated(@NotNull final MapView<G, A, R> mapView) { + // ignore + } + + @Override + public void mapViewClosing(@NotNull final MapView<G, A, R> mapView) { + // ignore + } + + }; + + /** + * Creates a new instance. + * @param mapViewManager the map view manager for tracking the current map + * view + * @param fileControl the file control for saving maps + * @param pathManager the path manager for converting path names + */ + protected AbstractServerActions(@NotNull final MapViewManager<G, A, R> mapViewManager, @NotNull final FileControl<G, A, R> fileControl, @NotNull final PathManager pathManager) { + this.fileControl = fileControl; + this.pathManager = pathManager; + mapViewManager.addMapViewManagerListener(mapViewManagerListener); + currentMapView = mapViewManager.getActiveMapView(); + updateActions(); + } + + /** + * Action method for "open in client". + */ + @ActionMethod + public void openInClient() { + doOpenInClient(true); + } + + /** + * Update the enabled/disabled state of all actions. + */ + private void updateActions() { + aOpenInClient.setEnabled(doOpenInClient(false)); + } + + /** + * Executes the "open in client" action. + * @param performAction whether the action should be performed + * @return whether the action was or can be performed + */ + private boolean doOpenInClient(final boolean performAction) { + final MapView<G, A, R> mapView = currentMapView; + if (mapView == null) { + return false; + } + + final MapControl<G, A, R> mapControl = mapView.getMapControl(); + final MapModel<G, A, R> mapModel = mapControl.getMapModel(); + final File mapFile = mapModel.getMapFile(); + if (mapFile == null) { + return false; + } + + final String mapPath = pathManager.getMapPath2(mapFile); + if (mapPath == null) { + return false; + } + + if (performAction) { + if (mapModel.isModified() && !fileControl.save(mapControl)) { + return false; + } + + final Point cursor = mapView.getMapCursor().getLocation(); + final int mapX; + final int mapY; + if (cursor == null) { + final A mapArchObject = mapModel.getMapArchObject(); + mapX = mapArchObject.getEnterX(); + mapY = mapArchObject.getEnterY(); + } else { + mapX = cursor.x; + mapY = cursor.y; + } + try { + teleportCharacterToMap(mapPath, mapX, mapY); + } catch (final IOException ex) { + fileControl.reportTeleportCharacterError(mapPath, ex.getMessage()); + } + } + + return true; + } + + /** + * Teleports the character to the given map path. + * @param mapPath the map path to teleport to + * @param mapX the x coordinate to teleport to + * @param mapY the y coordinate to teleport to + * @throws IOException if teleportation fails + */ + protected abstract void teleportCharacterToMap(@NotNull final String mapPath, final int mapX, final int mapY) throws IOException; + +} Property changes on: trunk/src/app/net/sf/gridarta/actions/AbstractServerActions.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + LF Modified: trunk/src/app/net/sf/gridarta/gui/misc/DefaultFileControl.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/misc/DefaultFileControl.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/gui/misc/DefaultFileControl.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -408,4 +408,12 @@ ACTION_BUILDER.showMessageDialog(parent, "mapOutOfMemory", file); } + /** + * {@inheritDoc} + */ + @Override + public void reportTeleportCharacterError(@NotNull final String mapPath, @NotNull final String message) { + ACTION_BUILDER.showMessageDialog(parent, "teleportCharacterError", mapPath, message); + } + } Modified: trunk/src/app/net/sf/gridarta/maincontrol/EditorFactory.java =================================================================== --- trunk/src/app/net/sf/gridarta/maincontrol/EditorFactory.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/maincontrol/EditorFactory.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -25,6 +25,7 @@ import net.sf.gridarta.gui.dialog.prefs.AppPreferencesModel; import net.sf.gridarta.gui.filter.FilterControl; import net.sf.gridarta.gui.map.mapview.MapViewFactory; +import net.sf.gridarta.gui.map.mapview.MapViewManager; import net.sf.gridarta.gui.map.mapview.MapViewsManager; import net.sf.gridarta.gui.map.renderer.RendererFactory; import net.sf.gridarta.gui.scripts.ScriptArchDataUtils; @@ -57,6 +58,7 @@ import net.sf.gridarta.model.maparchobject.MapArchObjectFactory; import net.sf.gridarta.model.mapcontrol.MapControlFactory; import net.sf.gridarta.model.mapmanager.AbstractMapManager; +import net.sf.gridarta.model.mapmanager.FileControl; import net.sf.gridarta.model.mapmanager.MapManager; import net.sf.gridarta.model.mapmodel.InsertionMode; import net.sf.gridarta.model.mapmodel.MapModelFactory; @@ -386,4 +388,14 @@ @NotNull AbstractResources<G, A, R> newResources(@NotNull final GameObjectParser<G, A, R> gameObjectParser, @NotNull final ArchetypeSet<G, A, R> archetypeSet, @NotNull final AbstractArchetypeParser<G, A, R, ?> archetypeParser, @NotNull final MapViewSettings mapViewSettings, @NotNull final FaceObjects faceObjects, @NotNull final AnimationObjects animationObjects, @NotNull final ArchFaceProvider archFaceProvider, @NotNull final FaceObjectProviders faceObjectProviders); + /** + * Creates the "open in client" action. Does nothing if this editor does not + * support this action. + * @param mapViewManager the map view manager for tracking the current map + * view + * @param fileControl the file control for saving maps + * @param pathManager the path manager for converting path names + */ + void newServerActions(@NotNull final MapViewManager<G, A, R> mapViewManager, @NotNull final FileControl<G, A, R> fileControl, @NotNull final PathManager pathManager); + } Modified: trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java =================================================================== --- trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-07-17 20:52:16 UTC (rev 9199) @@ -500,7 +500,7 @@ final DelayedMapModelListenerManager<G, A, R> delayedMapModelListenerManager = new DelayedMapModelListenerManager<G, A, R>(mapManager, exiter); final Control<?, G, A, R> lockedItemsControl = new LockedItemsControl<G, A, R>(mapViewManager, delayedMapModelListenerManager, lockedItemsTypeNumbers); final EnterMap<G, A, R> enterMap = new EnterMap<G, A, R>(mainViewFrame, directionMap, mapPathNormalizer, fileControl, mapViewsManager); - final MapActions<G, A, R> mapActions = new MapActions<G, A, R>(mainViewFrame, mapManager, mapViewManager, exitMatcher, GuiFileFilters.mapFileFilter, selectedSquareModel, allowRandomMapParameters, mapPropertiesDialogFactory, mapViewSettings, mapViewsManager, enterMap); + new MapActions<G, A, R>(mainViewFrame, mapManager, mapViewManager, exitMatcher, GuiFileFilters.mapFileFilter, selectedSquareModel, allowRandomMapParameters, mapPropertiesDialogFactory, mapViewSettings, mapViewsManager, enterMap); final GameObjectAttributesModel<G, A, R> gameObjectAttributesModel = new GameObjectAttributesModel<G, A, R>(); final GameObjectAttributesControl<G, A, R> gameObjectAttributesControl = new GameObjectAttributesControl<G, A, R>(gameObjectAttributesModel, gameObjectAttributesDialogFactory, objectChooser, mapManager, selectedSquareModel, selectedSquareView, gameObjectFactory); final PluginParameterViewFactory<G, A, R> pluginParameterViewFactory = new PluginParameterViewFactory<G, A, R>(archetypeSet, gameObjectAttributesModel, objectChooser, mapManager, faceObjectProviders); @@ -545,6 +545,7 @@ @Nullable final MapMenuManager<G, A, R> bookmarksMapMenuManager = new MapMenuManager<G, A, R>(mapMenu, mapViewsManager, fileControl, mapImageCache); //noinspection ResultOfObjectAllocationIgnored new BookmarkActions<G, A, R>(bookmarksMapMenuPreferences, mapMenu, mapViewManager, mainViewFrame, mapImageCache); + editorFactory.newServerActions(mapViewManager, fileControl, pathManager); pickmapChooserControl.setPopupMenu(ACTION_BUILDER.createPopupMenu(true, "pickmaps")); final JMenuBar menuBar = ACTION_BUILDER.createMenuBar(true, "main"); Modified: trunk/src/app/net/sf/gridarta/messages.properties =================================================================== --- trunk/src/app/net/sf/gridarta/messages.properties 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/messages.properties 2012-07-17 20:52:16 UTC (rev 9199) @@ -164,6 +164,9 @@ shrinkMapSize.text=Shrink Map Size... shrinkMapSize.shortdescription=Removes empty squares from the right or bottom map borders. +openInClient.text=Open In Client +openInClient.shortdescription=Save map and teleport character in client to map. + autoJoin.text=Autojoin autoJoin.mnemonic=J autoJoin.shortdescription=Toggles autojoining of wall game objects. @@ -368,6 +371,9 @@ openFileOutOfMapBoundsDeleted.title=Loading map file {0} openFileOutOfMapBoundsDeleted.message=While loading map file {0}:\nDeleted {1} game objects outside map bounds:{2} +teleportCharacterError.title=Cannot teleport character +teleportCharacterError.message=Cannot teleport the character to {0}:\n{1} + overwriteOtherFile.title=Overwrite file? overwriteOtherFile.message=A file named "{0}" already exists.\n\nReally overwrite it? Modified: trunk/src/app/net/sf/gridarta/messages_de.properties =================================================================== --- trunk/src/app/net/sf/gridarta/messages_de.properties 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/messages_de.properties 2012-07-17 20:52:16 UTC (rev 9199) @@ -145,6 +145,9 @@ shrinkMapSize.text=Kartengr\u00f6\u00dfe reduzieren... shrinkMapSize.shortdescription=Entfernt freie Felder am rechten bzw. unteren Kartenrand. +openInClient.text=In Client \u00f6ffnen +openInClient.shortdescription=Karte speichern und Character dorthin telelportieren. + autoJoin.text=Automatisch verbinden autoJoin.mnemonic=V autoJoin.shortdescription=Aktiviert bzw. deaktiviert automatisches Verbinden von W\u00e4nden. @@ -343,6 +346,9 @@ openFileOutOfMapBoundsDeleted.title=Karte {0} laden openFileOutOfMapBoundsDeleted.message=Beim Laden von {0}\nwurden {1} Objekte wurden gel\u00f6scht, da sie nicht innerhalb der Katenfl\u00e4che liegen:{2} +teleportCharacterError.title=Kann Charakter nicht teleportieren +teleportCharacterError.message=Teleportieren des Charakters nach {0} schlug fehl:\n{1} + overwriteOtherFile.title=Datei \u00fcberschreiben? overwriteOtherFile.message=Eine Datei mit Namen "{0}" existiert bereits.\n\nWirklich \u00fcberschreiben? Modified: trunk/src/app/net/sf/gridarta/messages_fr.properties =================================================================== --- trunk/src/app/net/sf/gridarta/messages_fr.properties 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/messages_fr.properties 2012-07-17 20:52:16 UTC (rev 9199) @@ -149,6 +149,9 @@ shrinkMapSize.text=R\u00e9duire la carte shrinkMapSize.shortdescription=Supprime les espaces inutiles \u00e0 droite et en bas. +#openInClient.text= +#openInClient.shortdescription= + autoJoin.text=Auto-connection des murs autoJoin.mnemonic=C autoJoin.shortdescription=Active ou d\u00e9sactive la connexion automatique des murs. @@ -343,6 +346,9 @@ #openFileOutOfMapBoundsDeleted.title= #openFileOutOfMapBoundsDeleted.message= +#teleportCharacterError.title= +#teleportCharacterError.message= + #overwriteOtherFile.title= overwriteOtherFile.message=Un fichier nomm\u00e9 "{0}" existe d\u00e9j\u00e0.\n\nVoulez vous vraiment le remplacer? Modified: trunk/src/app/net/sf/gridarta/messages_sv.properties =================================================================== --- trunk/src/app/net/sf/gridarta/messages_sv.properties 2012-07-17 20:44:27 UTC (rev 9198) +++ trunk/src/app/net/sf/gridarta/messages_sv.properties 2012-07-17 20:52:16 UTC (rev 9199) @@ -143,6 +143,9 @@ #shrinkMapSize.text= #shrinkMapSize.shortdescription= +#openInClient.text= +#openInClient.shortdescription= + #autoJoin.text= #autoJoin.mnemonic= #autoJoin.shortdescription= @@ -340,6 +343,9 @@ openFileOutOfMapBoundsDeleted.title=Laddar kartfil {0} #openFileOutOfMapBoundsDeleted.message= +#teleportCharacterError.title= +#teleportCharacterError.message= + overwriteOtherFile.title=Skriv \u00f6ver existerande fil? overwriteOtherFile.message=En fil med namnet "{0}" existerar redan.\n\nVill du verkligen skriva \u00f6ver den? This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-17 20:44:35
|
Revision: 9198 http://gridarta.svn.sourceforge.net/gridarta/?rev=9198&view=rev Author: akirschbaum Date: 2012-07-17 20:44:27 +0000 (Tue, 17 Jul 2012) Log Message: ----------- Add nullable annotations. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java Modified: trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java =================================================================== --- trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-07-17 20:18:38 UTC (rev 9197) +++ trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-07-17 20:44:27 UTC (rev 9198) @@ -325,12 +325,14 @@ * The {@link ProcessRunner} instance that controls the client. Set to * <code>null</code> if not yet created. */ + @Nullable private ProcessRunner controlClient = null; /** * The {@link ProcessRunner} instance that controls the server. Set to * <code>null</code> if not yet created. */ + @Nullable private ProcessRunner controlServer = null; /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-07-17 20:18:44
|
Revision: 9197 http://gridarta.svn.sourceforge.net/gridarta/?rev=9197&view=rev Author: akirschbaum Date: 2012-07-17 20:18:38 +0000 (Tue, 17 Jul 2012) Log Message: ----------- Fix regression tests. Modified Paths: -------------- trunk/build.xml Modified: trunk/build.xml =================================================================== --- trunk/build.xml 2012-06-23 12:36:17 UTC (rev 9196) +++ trunk/build.xml 2012-07-17 20:18:38 UTC (rev 9197) @@ -60,6 +60,7 @@ <path id="path.class.atrinik.app"> <pathelement location="${build.dir}/atrinik/app"/> + <pathelement location="atrinik/resource"/> </path> <path id="path.class.atrinik.test"> <path refid="path.class.atrinik.app"/> @@ -68,6 +69,7 @@ <path id="path.class.crossfire.app"> <pathelement location="${build.dir}/crossfire/app"/> + <pathelement location="crossfire/resource"/> </path> <path id="path.class.crossfire.test"> <path refid="path.class.crossfire.app"/> @@ -76,6 +78,7 @@ <path id="path.class.daimonin.app"> <pathelement location="${build.dir}/daimonin/app"/> + <pathelement location="daimonin/resource"/> </path> <path id="path.class.daimonin.test"> <path refid="path.class.daimonin.app"/> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-23 12:36:24
|
Revision: 9196 http://gridarta.svn.sourceforge.net/gridarta/?rev=9196&view=rev Author: akirschbaum Date: 2012-06-23 12:36:17 +0000 (Sat, 23 Jun 2012) Log Message: ----------- Add regression tests to check that IsoMapRenderer interprets align, rotate, z, and zoom. [Atrinik] Modified Paths: -------------- trunk/model/src/test/net/sf/gridarta/model/gameobject/TestGameObject.java trunk/model/src/test/net/sf/gridarta/model/mapmodel/TestMapModelCreator.java trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java Added Paths: ----------- trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/MapRendererTest.java trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java Added: trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/MapRendererTest.java =================================================================== --- trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/MapRendererTest.java (rev 0) +++ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/MapRendererTest.java 2012-06-23 12:36:17 UTC (rev 9196) @@ -0,0 +1,280 @@ +/* + * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. + * Copyright (C) 2000-2011 The Gridarta Developers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +package net.sf.gridarta.var.atrinik.gui.map.renderer; + +import java.awt.Point; +import java.util.Collections; +import net.sf.gridarta.gui.filter.DefaultFilterControl; +import net.sf.gridarta.gui.filter.FilterControl; +import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; +import net.sf.gridarta.model.archetype.TestArchetype; +import net.sf.gridarta.model.filter.NamedFilter; +import net.sf.gridarta.model.gameobject.DefaultIsoGameObject; +import net.sf.gridarta.model.gameobject.IsoMapSquareInfo; +import net.sf.gridarta.model.gameobject.MultiPositionData; +import net.sf.gridarta.model.gameobject.TestGameObject; +import net.sf.gridarta.model.io.GameObjectParser; +import net.sf.gridarta.model.maparchobject.TestMapArchObject; +import net.sf.gridarta.model.mapgrid.MapGrid; +import net.sf.gridarta.model.mapmodel.MapModel; +import net.sf.gridarta.model.mapmodel.TestMapModelCreator; +import net.sf.gridarta.model.mapviewsettings.MapViewSettings; +import net.sf.gridarta.model.match.NamedGameObjectMatcher; +import net.sf.gridarta.utils.SystemIcons; +import org.jetbrains.annotations.NotNull; +import org.junit.Assert; +import org.junit.Test; + +/** + * Regression tests that {@link net.sf.gridarta.gui.map.renderer.IsoMapRenderer} + * correctly interprets {@link DefaultIsoGameObject#ALIGN}, {@link + * DefaultIsoGameObject#ROTATE}, and {@link DefaultIsoGameObject#ZOOM}. + * @author Andreas Kirschbaum + */ +public class MapRendererTest { + + /** + * The {@link TestMapModelCreator} for creating {@link MapModel} instances. + */ + @NotNull + private final TestMapModelCreator mapModelCreator = new TestMapModelCreator(true); + + /** + * Checks rendering no game objects. + */ + @Test + public void testPaintEmpty() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("", renderer.getPaintingOperations()); + } + + /** + * Checks rendering game objects without attributes that affect rendering. + */ + @Test + public void testPaintNormal() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + mapModelCreator.addGameObjectToMap(mapModel, "arch", "name", 0, 0, mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 0.00 0.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#ALIGN} shifts the x coordinate. + */ + @Test + public void testPaintAlign1() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ALIGN, 5); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 5.00 0.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#ALIGN} shifts the x coordinate. + */ + @Test + public void testPaintAlign2() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ALIGN, -5); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 -5.00 0.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#Z} shifts the y coordinate. + */ + @Test + public void testPaintZ1() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.Z, 5); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 0.00 -5.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#Z} shifts the y coordinate. + */ + @Test + public void testPaintZ2() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.Z, -5); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 0.00 5.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#ZOOM} scales. + */ + @Test + public void testPaintZoom1() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ZOOM, 50); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("0.500 0.00 0.00 0.500 0.00 0.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#ZOOM} scales. + */ + @Test + public void testPaintZoom2() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ZOOM, 100); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.00 0.00 0.00 1.00 0.00 0.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that {@link DefaultIsoGameObject#ZOOM} scales. + */ + @Test + public void testPaintZoom3() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ZOOM, 110); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("1.10 0.00 0.00 1.10 0.00 0.00\n", renderer.getPaintingOperations()); // XXX: why not shift y = -0.1? + } + + /** + * Checks that {@link DefaultIsoGameObject#ZOOM} scales. + */ + @Test + public void testPaintZoom4() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ZOOM, 200); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("2.00 0.00 0.00 2.00 0.00 -1.00\n", renderer.getPaintingOperations()); + } + + /** + * Checks that a combination of attributes works as expected. + */ + @Test + public void testPaintCombined1() { + final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel = mapModelCreator.newMapModel(1, 1); + mapModel.beginTransaction("TEST"); + try { + final TestGameObject gameObject = mapModelCreator.newGameObject("arch", "name"); + gameObject.setAttributeInt(DefaultIsoGameObject.ALIGN, 5); + gameObject.setAttributeInt(DefaultIsoGameObject.ROTATE, 20); + gameObject.setAttributeInt(DefaultIsoGameObject.Z, 15); + gameObject.setAttributeInt(DefaultIsoGameObject.ZOOM, 75); + mapModel.addGameObjectToMap(gameObject, new Point(0, 0), mapModelCreator.getTopmostInsertionMode()); + } finally { + mapModel.endTransaction(); + } + final TestMapRenderer renderer = newRenderer(mapModel); + renderer.getFullImage(); + Assert.assertEquals("0.705 -0.257 0.257 0.705 5.00 -15.0\n", renderer.getPaintingOperations()); + } + + /** + * Creates a new {@link TestMapRenderer} instance for a {@link MapModel}. + * @param mapModel the map model for the renderer + * @return the renderer instance + */ + @NotNull + private TestMapRenderer newRenderer(@NotNull final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel) { + final MapViewSettings mapViewSettings = mapModelCreator.getMapViewSettings(); + final NamedFilter defaultNamedFilterList = new NamedFilter(Collections.<NamedGameObjectMatcher>emptyList()); + final FilterControl<TestGameObject, TestMapArchObject, TestArchetype> filterControl = new DefaultFilterControl<TestGameObject, TestMapArchObject, TestArchetype>(defaultNamedFilterList); + final MapGrid mapGrid = new MapGrid(mapModel.getMapArchObject().getMapSize()); + final IsoMapSquareInfo isoMapSquareInfo = new IsoMapSquareInfo(1, 1, 1, 1); + final MultiPositionData multiPositionData = new MultiPositionData(isoMapSquareInfo); + final SystemIcons systemIcons = mapModelCreator.getSystemIcons(); + final GridMapSquarePainter gridMapSquarePainter = new GridMapSquarePainter(systemIcons); + final GameObjectParser<TestGameObject, TestMapArchObject, TestArchetype> gameObjectParser = mapModelCreator.newGameObjectParser(); + return new TestMapRenderer(mapViewSettings, filterControl, mapModel, mapGrid, multiPositionData, isoMapSquareInfo, gridMapSquarePainter, gameObjectParser, systemIcons); + } + +} Property changes on: trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/MapRendererTest.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + LF Added: trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java =================================================================== --- trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java (rev 0) +++ trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java 2012-06-23 12:36:17 UTC (rev 9196) @@ -0,0 +1,116 @@ +/* + * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. + * Copyright (C) 2000-2011 The Gridarta Developers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +package net.sf.gridarta.var.atrinik.gui.map.renderer; + +import java.awt.Graphics2D; +import javax.swing.Icon; +import net.sf.gridarta.gui.filter.FilterControl; +import net.sf.gridarta.gui.map.renderer.GridMapSquarePainter; +import net.sf.gridarta.gui.map.renderer.IsoMapRenderer; +import net.sf.gridarta.model.archetype.TestArchetype; +import net.sf.gridarta.model.gameobject.IsoMapSquareInfo; +import net.sf.gridarta.model.gameobject.MultiPositionData; +import net.sf.gridarta.model.gameobject.TestGameObject; +import net.sf.gridarta.model.io.GameObjectParser; +import net.sf.gridarta.model.maparchobject.TestMapArchObject; +import net.sf.gridarta.model.mapgrid.MapGrid; +import net.sf.gridarta.model.mapmodel.MapModel; +import net.sf.gridarta.model.mapviewsettings.MapViewSettings; +import net.sf.gridarta.utils.SystemIcons; +import org.jetbrains.annotations.NotNull; + +/** + * An {@link IsoMapRenderer} for regression tests. It records all painting + * operations. + * @author Andreas Kirschbaum + */ +public class TestMapRenderer extends IsoMapRenderer<TestGameObject, TestMapArchObject, TestArchetype> { + + /** + * The serial version UID. + */ + private static final long serialVersionUID = 1L; + + /** + * The string builder that collects all paint operations. + */ + @NotNull + private final StringBuilder sb = new StringBuilder(); + + /** + * Creates a new instance. + * @param mapViewSettings the map view settings instance to use + * @param filterControl the filter to use + * @param mapModel the map model to render + * @param mapGrid the grid to render + * @param multiPositionData the multi position data to query for multi-part + * objects + * @param isoMapSquareInfo the iso square info to use + * @param gridMapSquarePainter the grid square painter to use + * @param gameObjectParser the game object parser for creating tooltip + * information + * @param systemIcons the system icons for creating icons + */ + public TestMapRenderer(@NotNull final MapViewSettings mapViewSettings, @NotNull final FilterControl<TestGameObject, TestMapArchObject, TestArchetype> filterControl, @NotNull final MapModel<TestGameObject, TestMapArchObject, TestArchetype> mapModel, @NotNull final MapGrid mapGrid, @NotNull final MultiPositionData multiPositionData, @NotNull final IsoMapSquareInfo isoMapSquareInfo, @NotNull final GridMapSquarePainter gridMapSquarePainter, @NotNull final GameObjectParser<TestGameObject, TestMapArchObject, TestArchetype> gameObjectParser, @NotNull final SystemIcons systemIcons) { + super(100, mapViewSettings, filterControl, mapModel, mapGrid, multiPositionData, isoMapSquareInfo, gridMapSquarePainter, gameObjectParser, systemIcons); + } + + /** + * {@inheritDoc} + * @noinspection RefusedBequest + */ + @Override + protected void paintIcon(@NotNull final Graphics2D g, @NotNull final Icon icon) { + final double[] matrix = new double[6]; + g.getTransform().getMatrix(matrix); + appendDouble(matrix[0]); + sb.append(' '); + appendDouble(matrix[1]); + sb.append(' '); + appendDouble(matrix[2]); + sb.append(' '); + appendDouble(matrix[3]); + sb.append(' '); + appendDouble(matrix[4]); + sb.append(' '); + appendDouble(matrix[5]); + sb.append('\n'); + } + + /** + * Appends a <code>double></code> value to {@link #sb}. + * @param value the double value + */ + private void appendDouble(final double value) { + sb.append(String.format("%.03g", value)); + } + + /** + * Returns and clears the accumulated painting operations. + * @return the painting operations + */ + @NotNull + public String getPaintingOperations() { + final String result = sb.toString(); + sb.setLength(0); + return result; + } + +} Property changes on: trunk/atrinik/src/test/net/sf/gridarta/var/atrinik/gui/map/renderer/TestMapRenderer.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + LF Modified: trunk/model/src/test/net/sf/gridarta/model/gameobject/TestGameObject.java =================================================================== --- trunk/model/src/test/net/sf/gridarta/model/gameobject/TestGameObject.java 2012-06-17 18:58:33 UTC (rev 9195) +++ trunk/model/src/test/net/sf/gridarta/model/gameobject/TestGameObject.java 2012-06-23 12:36:17 UTC (rev 9196) @@ -39,7 +39,6 @@ */ private static final long serialVersionUID = 1L; - /** * Creates a new instance. * @param archetype the base archetype @@ -65,7 +64,7 @@ @NotNull @Override public ImageIcon getImage(@NotNull final MapViewSettings mapViewSettings) { - throw new AssertionError(); + return getNormalImage(); } /** Modified: trunk/model/src/test/net/sf/gridarta/model/mapmodel/TestMapModelCreator.java =================================================================== --- trunk/model/src/test/net/sf/gridarta/model/mapmodel/TestMapModelCreator.java 2012-06-17 18:58:33 UTC (rev 9195) +++ trunk/model/src/test/net/sf/gridarta/model/mapmodel/TestMapModelCreator.java 2012-06-23 12:36:17 UTC (rev 9196) @@ -35,8 +35,10 @@ import net.sf.gridarta.model.archetypeset.DefaultArchetypeSet; import net.sf.gridarta.model.autojoin.AutojoinLists; import net.sf.gridarta.model.baseobject.BaseObject; +import net.sf.gridarta.model.face.EmptyFaceProvider; import net.sf.gridarta.model.face.FaceObjectProviders; import net.sf.gridarta.model.face.FaceObjects; +import net.sf.gridarta.model.face.FaceProvider; import net.sf.gridarta.model.face.TestFaceObjects; import net.sf.gridarta.model.gameobject.GameObject; import net.sf.gridarta.model.gameobject.GameObjectFactory; @@ -80,6 +82,12 @@ private final MapViewSettings mapViewSettings = new TestMapViewSettings(); /** + * The {@link SystemIcons} instance. + */ + @NotNull + private final SystemIcons systemIcons; + + /** * The {@link FaceObjectProviders} instance. */ @NotNull @@ -140,9 +148,11 @@ guiUtils.addToCache(iconName, imageIcon); } } - final SystemIcons systemIcons = new SystemIcons(guiUtils); + systemIcons = new SystemIcons(guiUtils); final FaceObjects faceObjects = new TestFaceObjects(); faceObjectProviders = new FaceObjectProviders(0, faceObjects, systemIcons); + final FaceProvider faceProvider = new EmptyFaceProvider(); + faceObjectProviders.setNormal(faceProvider); final ArchetypeFactory<TestGameObject, TestMapArchObject, TestArchetype> archetypeFactory = new TestArchetypeFactory(faceObjectProviders, animationObjects); archetypeSet = new DefaultArchetypeSet<TestGameObject, TestMapArchObject, TestArchetype>(archetypeFactory, null); gameObjectFactory = new TestGameObjectFactory(faceObjectProviders, animationObjects); @@ -335,4 +345,13 @@ return faceObjectProviders; } + /** + * Returns the {@link SystemIcons} instance. + * @return the system icons instance + */ + @NotNull + public SystemIcons getSystemIcons() { + return systemIcons; + } + } Modified: trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java 2012-06-17 18:58:33 UTC (rev 9195) +++ trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java 2012-06-23 12:36:17 UTC (rev 9196) @@ -631,14 +631,19 @@ */ private void paintRotatedIcon(@NotNull final Graphics2D g, @NotNull final Icon icon, final int x, final int y, final double rotate, final int oldIconWidth, final int oldIconHeight, final int newIconWidth, final int newIconHeight) { if (rotate < 0.001) { - icon.paintIcon(this, g, x, y); + g.translate(x, y); + try { + paintIcon(g, icon); + } finally { + g.translate(-x, -y); + } } else { final AffineTransform savedTransform = g.getTransform(); try { g.translate(x + newIconWidth / 2, y + newIconHeight / 2); g.rotate(rotate); g.translate(-oldIconWidth / 2, -oldIconHeight / 2); - icon.paintIcon(this, g, 0, 0); + paintIcon(g, icon); } finally { g.setTransform(savedTransform); } @@ -646,6 +651,15 @@ } /** + * Paints an icon. + * @param g the graphics to paint into + * @param icon the icon to paint + */ + protected void paintIcon(@NotNull final Graphics2D g, @NotNull final Icon icon) { + icon.paintIcon(this, g, 0, 0); + } + + /** * Returns whether the given {@link BaseObject} is a spawn point. * @param gameObject the game object * @return whether it is a spawn point This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 18:58:39
|
Revision: 9195 http://gridarta.svn.sourceforge.net/gridarta/?rev=9195&view=rev Author: akirschbaum Date: 2012-06-17 18:58:33 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Do not crash when shrinking a map if the map cursor is within the cut off area. Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/crossfire/ChangeLog trunk/daimonin/ChangeLog trunk/model/src/app/net/sf/gridarta/model/mapgrid/MapGrid.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-06-17 14:40:43 UTC (rev 9194) +++ trunk/atrinik/ChangeLog 2012-06-17 18:58:33 UTC (rev 9195) @@ -1,3 +1,8 @@ +2012-06-17 Andreas Kirschbaum + + * Do not crash when shrinking a map if the map cursor is within + the cut off area. + 2012-06-15 Andreas Kirschbaum * Temporarily invert the setting for "Map|Show Light" when Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2012-06-17 14:40:43 UTC (rev 9194) +++ trunk/crossfire/ChangeLog 2012-06-17 18:58:33 UTC (rev 9195) @@ -1,3 +1,8 @@ +2012-06-17 Andreas Kirschbaum + + * Do not crash when shrinking a map if the map cursor is within + the cut off area. + 2012-06-15 Andreas Kirschbaum * Temporarily invert the setting for "Map|Show Light" when Modified: trunk/daimonin/ChangeLog =================================================================== --- trunk/daimonin/ChangeLog 2012-06-17 14:40:43 UTC (rev 9194) +++ trunk/daimonin/ChangeLog 2012-06-17 18:58:33 UTC (rev 9195) @@ -1,3 +1,8 @@ +2012-06-17 Andreas Kirschbaum + + * Do not crash when shrinking a map if the map cursor is within + the cut off area. + 2012-06-15 Andreas Kirschbaum * Temporarily invert the setting for "Map|Show Light" when Modified: trunk/model/src/app/net/sf/gridarta/model/mapgrid/MapGrid.java =================================================================== --- trunk/model/src/app/net/sf/gridarta/model/mapgrid/MapGrid.java 2012-06-17 14:40:43 UTC (rev 9194) +++ trunk/model/src/app/net/sf/gridarta/model/mapgrid/MapGrid.java 2012-06-17 18:58:33 UTC (rev 9195) @@ -277,7 +277,11 @@ public void unSetCursor(@NotNull final Point pos) { beginTransaction(); try { - unsetFlags(pos.x, pos.y, pos.x, pos.y, GRID_FLAG_CURSOR); + try { + unsetFlags(pos.x, pos.y, pos.x, pos.y, GRID_FLAG_CURSOR); + } catch (final ArrayIndexOutOfBoundsException ignored) { + // happens after map resizes if the map cursor was within the cut off area + } } finally { endTransaction(); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 14:40:49
|
Revision: 9194 http://gridarta.svn.sourceforge.net/gridarta/?rev=9194&view=rev Author: akirschbaum Date: 2012-06-17 14:40:43 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Add Jenkins build script. Added Paths: ----------- trunk/build-jenkins.sh Added: trunk/build-jenkins.sh =================================================================== --- trunk/build-jenkins.sh (rev 0) +++ trunk/build-jenkins.sh 2012-06-17 14:40:43 UTC (rev 9194) @@ -0,0 +1,7 @@ +#! /bin/sh + +set -e +unset DISPLAY +cd trunk +debuild -uc -us +ant clean jar test checkstyle javadoc Property changes on: trunk/build-jenkins.sh ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 14:32:27
|
Revision: 9193 http://gridarta.svn.sourceforge.net/gridarta/?rev=9193&view=rev Author: akirschbaum Date: 2012-06-17 14:32:20 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Fix Javadoc issues. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/panel/connectionview/package.html trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/SelectedSquareModel.java trunk/src/app/overview.html Modified: trunk/src/app/net/sf/gridarta/gui/panel/connectionview/package.html =================================================================== --- trunk/src/app/net/sf/gridarta/gui/panel/connectionview/package.html 2012-06-17 14:25:26 UTC (rev 9192) +++ trunk/src/app/net/sf/gridarta/gui/panel/connectionview/package.html 2012-06-17 14:32:20 UTC (rev 9193) @@ -22,9 +22,9 @@ <body> Implements views of links between {@link net.sf.gridarta.model.gameobject.GameObject GameObjects} or groups or <code>GameObject</code>s -on a map. A {@link net.sf.gridarta.gui.connectionview.Connection Connection} is -a link between one or more <code>GameObjects</code> related to some key value. -Examples for key values are connection values to activate teleporters or gates, -or key code strings used by lockable keys and doors. +on a map. A {@link net.sf.gridarta.gui.panel.connectionview.Connection +Connection} is a link between one or more <code>GameObjects</code> related to +some key value. Examples for key values are connection values to activate +teleporters or gates, or key code strings used by lockable keys and doors. </body> </html> Modified: trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/SelectedSquareModel.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/SelectedSquareModel.java 2012-06-17 14:25:26 UTC (rev 9192) +++ trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/SelectedSquareModel.java 2012-06-17 14:32:20 UTC (rev 9193) @@ -46,7 +46,7 @@ private MapSquare<G, A, R> selectedMapSquare; /** - * The currently selected {@link GameObject)}. + * The currently selected {@link GameObject}. */ @Nullable private G selectedGameObject; Modified: trunk/src/app/overview.html =================================================================== --- trunk/src/app/overview.html 2012-06-17 14:25:26 UTC (rev 9192) +++ trunk/src/app/overview.html 2012-06-17 14:32:20 UTC (rev 9193) @@ -35,11 +35,11 @@ actions.</p> <p> - Map visualization is done by {@link - net.sf.gridarta.gui.map.mapview.MapViewBasic MapViewBasic}, which renders - the map, and {@link net.sf.gridarta.gui.map.mapview.MapView MapView}, which - is a {@link javax.swing.JInternalFrame JInternalFrame} wrapping <code>MapViewBasic</code>. -</p> + Map visualization is done by {@link net.sf.gridarta.gui.map.mapview.MapView + MapView}, which renders the map, and {@link + net.sf.gridarta.gui.map.mapview.MapView MapView}, which is a {@link + javax.swing.JInternalFrame JInternalFrame} wrapping + <code>MapViewBasic</code>. </p> <h3>Data Model</h3> @@ -99,9 +99,10 @@ The class that implements Archetypes is {@link net.sf.gridarta.model.archetype.Archetype Archetype}. The class that parses text for modifying ArchObjects is {@link - net.sf.gridarta.model.archetype.ArchetypeParser ArchetypeParser}. The - class that holds all default Archetypes, including those for default - Artifacts, is {@link net.sf.gridarta.model.archetype.ArchetypeSet}. + net.sf.gridarta.model.io.ArchetypeParser ArchetypeParser}. The class + that holds all default Archetypes, including those for default + Artifacts, is {@link net.sf.gridarta.model.archetypeset.ArchetypeSet + ArchetypeSet}. <p/> </dd> <dt id="Artifact">Artifact</dt> @@ -115,7 +116,7 @@ The Face is the appearance of an Archetype. A Face is defined by a String that uniquely defines the appearance and is used to reference a corresponding graphic image, usually a PNG file. The {@link - net.sf.gridarta.model.archetype.ArchetypeSet ArchetypeSet} contains a + net.sf.gridarta.model.archetypeset.ArchetypeSet ArchetypeSet} contains a collection of all available faces. <p/> Animations override Faces. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 14:25:32
|
Revision: 9192 http://gridarta.svn.sourceforge.net/gridarta/?rev=9192&view=rev Author: akirschbaum Date: 2012-06-17 14:25:26 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Remove unused code. Removed Paths: ------------- trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/MapSquareSelectionListener.java Deleted: trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/MapSquareSelectionListener.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/MapSquareSelectionListener.java 2012-06-17 14:21:24 UTC (rev 9191) +++ trunk/src/app/net/sf/gridarta/gui/panel/selectedsquare/MapSquareSelectionListener.java 2012-06-17 14:25:26 UTC (rev 9192) @@ -1,44 +0,0 @@ -/* - * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. - * Copyright (C) 2000-2011 The Gridarta Developers. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - */ - -package net.sf.gridarta.gui.panel.selectedsquare; - -import java.util.EventListener; -import net.sf.gridarta.model.archetype.Archetype; -import net.sf.gridarta.model.gameobject.GameObject; -import net.sf.gridarta.model.maparchobject.MapArchObject; -import net.sf.gridarta.model.mapmodel.MapSquare; -import org.jetbrains.annotations.Nullable; - -/** - * Interface for listeners interested in {@link MapSquareSelection} related - * events. - * @author Andreas Kirschbaum - */ -public interface MapSquareSelectionListener<G extends GameObject<G, A, R>, A extends MapArchObject<A>, R extends Archetype<G, A, R>> extends EventListener { - - /** - * Called when the current selection has changed. - * @param mapSquare the selected map square - * @param gameObject the selected game object - * @param index the selected index - */ - void selectionChanged(@Nullable MapSquare<G, A, R> mapSquare, @Nullable G gameObject, int index); - -} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 14:21:32
|
Revision: 9191 http://gridarta.svn.sourceforge.net/gridarta/?rev=9191&view=rev Author: akirschbaum Date: 2012-06-17 14:21:24 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Remove unused import statements. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java Modified: trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java 2012-06-17 14:20:17 UTC (rev 9190) +++ trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java 2012-06-17 14:21:24 UTC (rev 9191) @@ -26,7 +26,6 @@ import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; -import net.sf.gridarta.model.mapviewsettings.MapViewSettings; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -97,7 +96,7 @@ void scrollRectToVisible(@NotNull Rectangle aRect); /** - * If set, inverts the setting of {@link MapViewSettings#isLightVisible()}. + * If set, inverts the setting of {@link net.sf.gridarta.model.mapviewsettings.MapViewSettings#isLightVisible()}. * @param lightVisible whether lighted map squares are inverted */ void setLightVisible(final boolean lightVisible); Modified: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java 2012-06-17 14:20:17 UTC (rev 9190) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java 2012-06-17 14:21:24 UTC (rev 9191) @@ -19,7 +19,6 @@ package net.sf.gridarta.gui.mapuserlistener; -import java.awt.Component; import java.awt.event.InputEvent; import java.awt.event.KeyEvent; import java.awt.event.KeyListener; @@ -44,7 +43,7 @@ public class MapKeyListener<G extends GameObject<G, A, R>, A extends MapArchObject<A>, R extends Archetype<G, A, R>> { /** - * The {@link Component} being tracked for key actions. + * The {@link MapView} being tracked for key actions. */ @Nullable private MapView<G, A, R> mapView; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-17 14:20:23
|
Revision: 9190 http://gridarta.svn.sourceforge.net/gridarta/?rev=9190&view=rev Author: akirschbaum Date: 2012-06-17 14:20:17 +0000 (Sun, 17 Jun 2012) Log Message: ----------- Update config files. Modified Paths: -------------- trunk/test-mapvalidator/atrinik/regtest.conf trunk/test-mapvalidator/crossfire/regtest.conf trunk/test-mapvalidator/daimonin/regtest.conf Modified: trunk/test-mapvalidator/atrinik/regtest.conf =================================================================== --- trunk/test-mapvalidator/atrinik/regtest.conf 2012-06-16 16:10:38 UTC (rev 9189) +++ trunk/test-mapvalidator/atrinik/regtest.conf 2012-06-17 14:20:17 UTC (rev 9190) @@ -4,54 +4,54 @@ # Whether the map validator is enabled. Validator.All=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.AttributeRange=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.BlockedMobOrSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.BlockedSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedInsideContainer=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedPickable=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Connection=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.DoubleLayer=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.EmptySpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Environment=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Exit=true Validator.MapCheckerScript=false -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.MapDifficulty=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.MobOutsideSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.TilePaths=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedArchetype=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedFace=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UnsetSlaying=true # Main windows''s state (maximized, iconized, etc.) @@ -88,6 +88,9 @@ # Whether the map grid is visible. mapViewSettings.gridVisible=false +# Whether lighted map squares are highlighted. +mapViewSettings.lightVisible=false + # Whether smoothing is active. mapViewSettings.smoothing=false Modified: trunk/test-mapvalidator/crossfire/regtest.conf =================================================================== --- trunk/test-mapvalidator/crossfire/regtest.conf 2012-06-16 16:10:38 UTC (rev 9189) +++ trunk/test-mapvalidator/crossfire/regtest.conf 2012-06-17 14:20:17 UTC (rev 9190) @@ -4,49 +4,49 @@ # Whether the map validator is enabled. Validator.All=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.AttributeRange=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedInsideContainer=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedPickable=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Connection=true # Whether this map validator check is enabled. Validator.CustomType=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Environment=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Exit=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.MapDifficulty=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.NonAbsoluteExitPath=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.PaidItemShopSquare=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ShopSquare=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.TilePaths=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedArchetype=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedFace=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UnsetSlaying=true # Archetype directory. @@ -77,6 +77,9 @@ # Whether the map grid is visible. mapViewSettings.gridVisible=false +# Whether lighted map squares are highlighted. +mapViewSettings.lightVisible=false + # Whether smoothing is active. mapViewSettings.smoothing=false Modified: trunk/test-mapvalidator/daimonin/regtest.conf =================================================================== --- trunk/test-mapvalidator/daimonin/regtest.conf 2012-06-16 16:10:38 UTC (rev 9189) +++ trunk/test-mapvalidator/daimonin/regtest.conf 2012-06-17 14:20:17 UTC (rev 9190) @@ -4,70 +4,70 @@ # Whether the map validator is enabled. Validator.All=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.AttributeRange=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.BlockedMobOrSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.BlockedSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.BlockedSquare=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedInsideContainer=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.ConnectedPickable=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Connection=true # Whether this map validator check is enabled. Validator.CustomType=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.DoubleLayer=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.DoubleType=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.EmptySpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Environment=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Exit=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.MapDifficulty=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.MobOutsideSpawnPoint=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.Slaying=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.SquareWithoutFloor=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.SysObjectNotOnLayerZero=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.TilePaths=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedArchetype=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UndefinedFace=true -# Whether this map validator check is is enabled. +# Whether this map validator check is enabled. Validator.UnsetSlaying=true # Archetype directory. @@ -98,6 +98,9 @@ # Whether the map grid is visible. mapViewSettings.gridVisible=false +# Whether lighted map squares are highlighted. +mapViewSettings.lightVisible=false + # Whether smoothing is active. mapViewSettings.smoothing=false This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-16 16:10:46
|
Revision: 9189 http://gridarta.svn.sourceforge.net/gridarta/?rev=9189&view=rev Author: akirschbaum Date: 2012-06-16 16:10:38 +0000 (Sat, 16 Jun 2012) Log Message: ----------- Make CTRL-SHIFT hotkey work more reliably. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java Modified: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java 2012-06-16 09:41:33 UTC (rev 9188) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java 2012-06-16 16:10:38 UTC (rev 9189) @@ -25,10 +25,15 @@ import java.awt.event.KeyListener; import java.awt.event.MouseEvent; import java.awt.event.MouseListener; -import net.sf.gridarta.gui.map.renderer.MapRenderer; +import net.sf.gridarta.gui.map.mapview.MapView; +import net.sf.gridarta.gui.map.mapview.MapViewManager; +import net.sf.gridarta.gui.map.mapview.MapViewManagerListener; import net.sf.gridarta.model.archetype.Archetype; import net.sf.gridarta.model.gameobject.GameObject; import net.sf.gridarta.model.maparchobject.MapArchObject; +import net.sf.gridarta.model.mapcontrol.MapControl; +import net.sf.gridarta.model.mapmanager.MapManager; +import net.sf.gridarta.model.mapmanager.MapManagerListener; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -41,22 +46,21 @@ /** * The {@link Component} being tracked for key actions. */ - @NotNull - private final Component component; + @Nullable + private MapView<G, A, R> mapView; /** - * The {@link MapRenderer} being tracked for mouse actions. + * Whether the mouse is inside the window. */ - @NotNull - private final MapRenderer renderer; + private boolean inside; /** - * Whether the mouse is inside the window. + * Whether the CTRL+SHIFT modifiers are pressed. */ - private boolean inside = true; + private boolean lightVisible; /** - * The {@link KeyListener} attached to {@link #component}. + * The {@link KeyListener} attached to {@link #mapView}. */ @NotNull private final KeyListener keyListener = new KeyListener() { @@ -68,18 +72,18 @@ @Override public void keyPressed(@NotNull final KeyEvent e) { - checkModifiers(e); + setModifiers(e.getModifiers()); } @Override public void keyReleased(@NotNull final KeyEvent e) { - checkModifiers(e); + setModifiers(e.getModifiers()); } }; /** - * The {@link MouseListener} attached to {@link #renderer}. Checks the key + * The {@link MouseListener} attached to {@link #mapView}. Checks the key * modifiers whenever the mouse enters or leaves the window. */ @NotNull @@ -102,45 +106,139 @@ @Override public void mouseEntered(@NotNull final MouseEvent e) { - inside = true; - checkModifiers(e); + setInside(true); + setModifiers(e.getModifiers()); } @Override public void mouseExited(@NotNull final MouseEvent e) { - inside = false; - checkModifiers(null); + setInside(false); } }; /** + * The listener used to detect map view changes. + * @noinspection FieldCanBeLocal + */ + @NotNull + private final MapViewManagerListener<G, A, R> mapViewManagerListener = new MapViewManagerListener<G, A, R>() { + + @Override + public void mapViewCreated(@NotNull final MapView<G, A, R> mapView) { + // ignore + } + + @Override + public void mapViewClosing(@NotNull final MapView<G, A, R> mapView) { + // ignore + } + + @Override + public void activeMapViewChanged(@Nullable final MapView<G, A, R> mapView) { + setMapView(mapView); + } + + }; + + /** + * The {@link MapManagerListener} for tracking {@link MapControl} + * instances. + * @noinspection FieldCanBeLocal + */ + @NotNull + private final MapManagerListener<G, A, R> mapManagerListener = new MapManagerListener<G, A, R>() { + + @Override + public void currentMapChanged(@Nullable final MapControl<G, A, R> mapControl) { + if (mapView != null) { + // Hack: mapViewManagerListener.activeMapViewChanged() has been called too early + setInside(mapView.getInternalFrame().getMousePosition() != null); + } + } + + @Override + public void mapCreated(@NotNull final MapControl<G, A, R> mapControl, final boolean interactive) { + // ignore + } + + @Override + public void mapClosing(@NotNull final MapControl<G, A, R> mapControl) { + // ignore + } + + @Override + public void mapClosed(@NotNull final MapControl<G, A, R> mapControl) { + // ignore + } + + }; + + /** * Creates a new instance. - * @param component the component to track - * @param renderer the renderer to track + * @param mapViewManager the map view manager to track for map views + * @param mapManager the map manager to track */ - public MapKeyListener(@NotNull final Component component, @NotNull final MapRenderer renderer) { - this.component = component; - this.renderer = renderer; - component.addKeyListener(keyListener); - renderer.addMouseListener(mouseListener); + public MapKeyListener(@NotNull final MapViewManager<G, A, R> mapViewManager, @NotNull final MapManager<G, A, R> mapManager) { + mapViewManager.addMapViewManagerListener(mapViewManagerListener); + mapManager.addMapManagerListener(mapManagerListener); + setMapView(mapViewManager.getActiveMapView()); } /** - * Must be called when this object is freed. Unregisters all listeners. + * Sets the {@link #mapView current map view}. + * @param mapView the new map view to set */ - public void closeNotify() { - renderer.removeMouseListener(mouseListener); - component.removeKeyListener(keyListener); + private void setMapView(@Nullable final MapView<G, A, R> mapView) { + final MapView<G, A, R> prevMapView = this.mapView; + if (prevMapView != null) { + prevMapView.getInternalFrame().removeKeyListener(keyListener); + prevMapView.getRenderer().removeMouseListener(mouseListener); + prevMapView.getRenderer().setLightVisible(false); + } + this.mapView = mapView; + if (mapView != null) { + mapView.getInternalFrame().addKeyListener(keyListener); + mapView.getRenderer().addMouseListener(mouseListener); + setModifiers(0); + setInside(mapView.getInternalFrame().getMousePosition() != null); + } else { + setModifiers(0); + setInside(false); + } } /** - * Checks a {@link KeyEvent} for CTRL+ALT. - * @param e the event to check or <code>null</code> to disable highlighting + * Updates the active modifiers for the current map view. + * @param modifiers the new modifiers */ - private void checkModifiers(@Nullable final InputEvent e) { - final boolean lightVisible = e != null && inside && (e.getModifiers() & (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK)) == (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK); - renderer.setLightVisible(lightVisible); + private void setModifiers(final int modifiers) { + final boolean lightVisible = (modifiers & (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK)) == (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK); + if (this.lightVisible != lightVisible) { + this.lightVisible = lightVisible; + updateRenderer(); + } } + /** + * Updates the "mouse is inside the window" flag for the current map view. + * @param inside whether the mouse is inside the map view + */ + private void setInside(final boolean inside) { + if (this.inside != inside) { + this.inside = inside; + updateRenderer(); + } + } + + /** + * Updates the current map view's renderer settings. Does nothing if no map + * view is active. + */ + private void updateRenderer() { + if (mapView != null) { + mapView.getRenderer().setLightVisible(inside && lightVisible); + } + } + } Modified: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-16 09:41:33 UTC (rev 9188) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-16 16:10:38 UTC (rev 9189) @@ -53,12 +53,6 @@ private final MapViewsManager<G, A, R> mapViewsManager; /** - * Maps {@link MapView} instance to attached {@link MapKeyListener}. - */ - @NotNull - private final Map<MapView<G, A, R>, MapKeyListener<G, A, R>> mapKeyListeners = new IdentityHashMap<MapView<G, A, R>, MapKeyListener<G, A, R>>(); - - /** * Maps {@link MapView} instance to attached {@link MapMouseListener}. */ @NotNull @@ -104,17 +98,10 @@ public void mapViewCreated(@NotNull final MapView<G, A, R> mapView) { final MapMouseListener<G, A, R> mapMouseListener = new MapMouseListener<G, A, R>(mapView.getRenderer(), toolPalette, mapView); mapUserListeners.put(mapView, mapMouseListener); - - final MapKeyListener<G, A, R> mapKeyListener = new MapKeyListener<G, A, R>(mapView.getInternalFrame(), mapView.getRenderer()); - mapKeyListeners.put(mapView, mapKeyListener); } @Override public void mapViewClosing(@NotNull final MapView<G, A, R> mapView) { - final MapKeyListener<G, A, R> mapKeyListener = mapKeyListeners.remove(mapView); - assert mapKeyListener != null; - mapKeyListener.closeNotify(); - final MapMouseListener<G, A, R> mapMouseListener = mapUserListeners.remove(mapView); assert mapMouseListener != null; mapMouseListener.closeNotify(); Modified: trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java =================================================================== --- trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-06-16 09:41:33 UTC (rev 9188) +++ trunk/src/app/net/sf/gridarta/maincontrol/GUIMainControl.java 2012-06-16 16:10:38 UTC (rev 9189) @@ -79,6 +79,7 @@ import net.sf.gridarta.gui.mapmenu.MapMenuManager; import net.sf.gridarta.gui.mapmenu.MapMenuPreferences; import net.sf.gridarta.gui.mapmenu.RecentMapMenuPreferences; +import net.sf.gridarta.gui.mapuserlistener.MapKeyListener; import net.sf.gridarta.gui.mapuserlistener.MapUserListenerManager; import net.sf.gridarta.gui.misc.About; import net.sf.gridarta.gui.misc.DefaultFileControl; @@ -631,6 +632,8 @@ mapUserListenerManager.addMapManager(mapManager); mapUserListenerManager.addMapManager(pickmapManager); + new MapKeyListener<G, A, R>(mapViewManager, mapManager); + new Loader<G, A, R>(errorView, mapFolderTree, mapReaderFactory, pickmapManager, mapViewsManager).load(); if (!pickmapChooserModel.isEmpty()) { objectChooser.movePickmapChooserToFront(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-16 09:41:39
|
Revision: 9188 http://gridarta.svn.sourceforge.net/gridarta/?rev=9188&view=rev Author: akirschbaum Date: 2012-06-16 09:41:33 +0000 (Sat, 16 Jun 2012) Log Message: ----------- Add nullable annotation. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/mapdesktop/WindowMenuManager.java Modified: trunk/src/app/net/sf/gridarta/gui/mapdesktop/WindowMenuManager.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapdesktop/WindowMenuManager.java 2012-06-16 09:38:24 UTC (rev 9187) +++ trunk/src/app/net/sf/gridarta/gui/mapdesktop/WindowMenuManager.java 2012-06-16 09:41:33 UTC (rev 9188) @@ -64,6 +64,7 @@ /** * The listener used to detect map view changes. */ + @NotNull private final MapViewManagerListener<G, A, R> mapViewManagerListener = new MapViewManagerListener<G, A, R>() { @Override This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-16 09:38:31
|
Revision: 9187 http://gridarta.svn.sourceforge.net/gridarta/?rev=9187&view=rev Author: akirschbaum Date: 2012-06-16 09:38:24 +0000 (Sat, 16 Jun 2012) Log Message: ----------- Add nullable annotations. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java Modified: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-15 21:06:44 UTC (rev 9186) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-16 09:38:24 UTC (rev 9187) @@ -68,6 +68,7 @@ * The {@link MapManagerListener} for tracking {@link MapControl} * instances. */ + @NotNull private final MapManagerListener<G, A, R> mapManagerListener = new MapManagerListener<G, A, R>() { @Override @@ -96,6 +97,7 @@ * The {@link MapViewsListener} attached to all {@link MapControl} * instances. */ + @NotNull private final MapViewsListener<G, A, R> mapViewsListener = new MapViewsListener<G, A, R>() { @Override This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2012-06-15 21:06:53
|
Revision: 9186 http://gridarta.svn.sourceforge.net/gridarta/?rev=9186&view=rev Author: akirschbaum Date: 2012-06-15 21:06:44 +0000 (Fri, 15 Jun 2012) Log Message: ----------- Temporarily invert the setting for "Map|Show Light" when CTRL+SHIFT is pressed. Modified Paths: -------------- trunk/atrinik/ChangeLog trunk/crossfire/ChangeLog trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/gui/map/renderer/AbstractFlatMapRenderer.java trunk/daimonin/ChangeLog trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractMapRenderer.java trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java Added Paths: ----------- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java Modified: trunk/atrinik/ChangeLog =================================================================== --- trunk/atrinik/ChangeLog 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/atrinik/ChangeLog 2012-06-15 21:06:44 UTC (rev 9186) @@ -1,5 +1,8 @@ 2012-06-15 Andreas Kirschbaum + * Temporarily invert the setting for "Map|Show Light" when + CTRL+SHIFT is pressed. + * Implement Map|Show Light to toggle highlighting of lighted map squares. Modified: trunk/crossfire/ChangeLog =================================================================== --- trunk/crossfire/ChangeLog 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/crossfire/ChangeLog 2012-06-15 21:06:44 UTC (rev 9186) @@ -1,5 +1,8 @@ 2012-06-15 Andreas Kirschbaum + * Temporarily invert the setting for "Map|Show Light" when + CTRL+SHIFT is pressed. + * Implement Map|Show Light to toggle highlighting of lighted map squares. Modified: trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/gui/map/renderer/AbstractFlatMapRenderer.java =================================================================== --- trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/gui/map/renderer/AbstractFlatMapRenderer.java 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/crossfire/src/app/net/sf/gridarta/var/crossfire/gui/map/renderer/AbstractFlatMapRenderer.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -423,7 +423,7 @@ */ protected void paintSquareSelection(@NotNull final Graphics graphics, @NotNull final Point point) { final int gridFlags = mapGrid.getFlags(point.x, point.y); - final boolean light = mapViewSettings.isLightVisible() && mapModel.getMapSquare(point).isLight(); + final boolean light = (isLightVisible() ^ mapViewSettings.isLightVisible()) && mapModel.getMapSquare(point).isLight(); gridMapSquarePainter.paint(graphics, gridFlags, light, borderOffset.x + point.x * IGUIConstants.SQUARE_WIDTH, borderOffset.y + point.y * IGUIConstants.SQUARE_HEIGHT, this); } Modified: trunk/daimonin/ChangeLog =================================================================== --- trunk/daimonin/ChangeLog 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/daimonin/ChangeLog 2012-06-15 21:06:44 UTC (rev 9186) @@ -1,5 +1,8 @@ 2012-06-15 Andreas Kirschbaum + * Temporarily invert the setting for "Map|Show Light" when + CTRL+SHIFT is pressed. + * Implement Map|Show Light to toggle highlighting of lighted map squares. Modified: trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractIsoMapRenderer.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -661,7 +661,7 @@ * @param g the graphics for painting */ private void paintMapSelection(@NotNull final Graphics g) { - final boolean lightVisible = mapViewSettings.isLightVisible(); + final boolean lightVisible = isLightVisible() ^ mapViewSettings.isLightVisible(); final Point point = new Point(); for (int y = 0; y < mapSize.getHeight(); y++) { int xStart = origin.x - (y + 1) * isoMapSquareInfo.getXLen2(); Modified: trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractMapRenderer.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractMapRenderer.java 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/src/app/net/sf/gridarta/gui/map/renderer/AbstractMapRenderer.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -75,6 +75,11 @@ private final GameObjectParser<G, A, R> gameObjectParser; /** + * Whether the setting for lighted map squares is inverted. + */ + private boolean lightVisible; + + /** * Creates a new instance. * @param mapModel the rendered map model * @param gameObjectParser the game object parser for generating tooltip @@ -133,4 +138,25 @@ return toolTipAppender.finish(); } + /** + * {@inheritDoc} + */ + @Override + public void setLightVisible(final boolean lightVisible) { + if (this.lightVisible == lightVisible) { + return; + } + + this.lightVisible = lightVisible; + forceRepaint(); + } + + /** + * Returns whether the setting for lighted map squares should be inverted. + * @return whether the setting should be inverted + */ + protected boolean isLightVisible() { + return lightVisible; + } + } Modified: trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/src/app/net/sf/gridarta/gui/map/renderer/MapRenderer.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -26,6 +26,7 @@ import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; +import net.sf.gridarta.model.mapviewsettings.MapViewSettings; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; @@ -95,4 +96,10 @@ */ void scrollRectToVisible(@NotNull Rectangle aRect); + /** + * If set, inverts the setting of {@link MapViewSettings#isLightVisible()}. + * @param lightVisible whether lighted map squares are inverted + */ + void setLightVisible(final boolean lightVisible); + } Added: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java (rev 0) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -0,0 +1,146 @@ +/* + * Gridarta MMORPG map editor for Crossfire, Daimonin and similar games. + * Copyright (C) 2000-2011 The Gridarta Developers. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +package net.sf.gridarta.gui.mapuserlistener; + +import java.awt.Component; +import java.awt.event.InputEvent; +import java.awt.event.KeyEvent; +import java.awt.event.KeyListener; +import java.awt.event.MouseEvent; +import java.awt.event.MouseListener; +import net.sf.gridarta.gui.map.renderer.MapRenderer; +import net.sf.gridarta.model.archetype.Archetype; +import net.sf.gridarta.model.gameobject.GameObject; +import net.sf.gridarta.model.maparchobject.MapArchObject; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Tracks key presses and maps them to actions. + * @author Andreas Kirschbaum + */ +public class MapKeyListener<G extends GameObject<G, A, R>, A extends MapArchObject<A>, R extends Archetype<G, A, R>> { + + /** + * The {@link Component} being tracked for key actions. + */ + @NotNull + private final Component component; + + /** + * The {@link MapRenderer} being tracked for mouse actions. + */ + @NotNull + private final MapRenderer renderer; + + /** + * Whether the mouse is inside the window. + */ + private boolean inside = true; + + /** + * The {@link KeyListener} attached to {@link #component}. + */ + @NotNull + private final KeyListener keyListener = new KeyListener() { + + @Override + public void keyTyped(@NotNull final KeyEvent e) { + // ignore + } + + @Override + public void keyPressed(@NotNull final KeyEvent e) { + checkModifiers(e); + } + + @Override + public void keyReleased(@NotNull final KeyEvent e) { + checkModifiers(e); + } + + }; + + /** + * The {@link MouseListener} attached to {@link #renderer}. Checks the key + * modifiers whenever the mouse enters or leaves the window. + */ + @NotNull + private final MouseListener mouseListener = new MouseListener() { + + @Override + public void mouseClicked(@NotNull final MouseEvent e) { + // ignore + } + + @Override + public void mousePressed(@NotNull final MouseEvent e) { + // ignore + } + + @Override + public void mouseReleased(@NotNull final MouseEvent e) { + // ignore + } + + @Override + public void mouseEntered(@NotNull final MouseEvent e) { + inside = true; + checkModifiers(e); + } + + @Override + public void mouseExited(@NotNull final MouseEvent e) { + inside = false; + checkModifiers(null); + } + + }; + + /** + * Creates a new instance. + * @param component the component to track + * @param renderer the renderer to track + */ + public MapKeyListener(@NotNull final Component component, @NotNull final MapRenderer renderer) { + this.component = component; + this.renderer = renderer; + component.addKeyListener(keyListener); + renderer.addMouseListener(mouseListener); + } + + /** + * Must be called when this object is freed. Unregisters all listeners. + */ + public void closeNotify() { + renderer.removeMouseListener(mouseListener); + component.removeKeyListener(keyListener); + } + + /** + * Checks a {@link KeyEvent} for CTRL+ALT. + * @param e the event to check or <code>null</code> to disable highlighting + */ + private void checkModifiers(@Nullable final InputEvent e) { + final boolean lightVisible = e != null && inside && (e.getModifiers() & (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK)) == (InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK); + renderer.setLightVisible(lightVisible); + } + +} Property changes on: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapKeyListener.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:eol-style + LF Modified: trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java =================================================================== --- trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-15 19:57:18 UTC (rev 9185) +++ trunk/src/app/net/sf/gridarta/gui/mapuserlistener/MapUserListenerManager.java 2012-06-15 21:06:44 UTC (rev 9186) @@ -53,6 +53,12 @@ private final MapViewsManager<G, A, R> mapViewsManager; /** + * Maps {@link MapView} instance to attached {@link MapKeyListener}. + */ + @NotNull + private final Map<MapView<G, A, R>, MapKeyListener<G, A, R>> mapKeyListeners = new IdentityHashMap<MapView<G, A, R>, MapKeyListener<G, A, R>>(); + + /** * Maps {@link MapView} instance to attached {@link MapMouseListener}. */ @NotNull @@ -96,10 +102,17 @@ public void mapViewCreated(@NotNull final MapView<G, A, R> mapView) { final MapMouseListener<G, A, R> mapMouseListener = new MapMouseListener<G, A, R>(mapView.getRenderer(), toolPalette, mapView); mapUserListeners.put(mapView, mapMouseListener); + + final MapKeyListener<G, A, R> mapKeyListener = new MapKeyListener<G, A, R>(mapView.getInternalFrame(), mapView.getRenderer()); + mapKeyListeners.put(mapView, mapKeyListener); } @Override public void mapViewClosing(@NotNull final MapView<G, A, R> mapView) { + final MapKeyListener<G, A, R> mapKeyListener = mapKeyListeners.remove(mapView); + assert mapKeyListener != null; + mapKeyListener.closeNotify(); + final MapMouseListener<G, A, R> mapMouseListener = mapUserListeners.remove(mapView); assert mapMouseListener != null; mapMouseListener.closeNotify(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |