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...> - 2006-11-27 22:01:26
|
Revision: 734 http://svn.sourceforge.net/gridarta/?rev=734&view=rev Author: akirschbaum Date: 2006-11-27 14:01:27 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Rename variable names. Modified Paths: -------------- trunk/daimonin/src/daieditor/CAttribDialog.java Modified: trunk/daimonin/src/daieditor/CAttribDialog.java =================================================================== --- trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:57:49 UTC (rev 733) +++ trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 22:01:27 UTC (rev 734) @@ -1610,20 +1610,20 @@ private final JTextArea text; // textfield containing the error-text to keep - private final GameObject arch; // the according gameObject + private final GameObject gameObject; // the according gameObject private final String allErrors; // list of all errors /** * Constructor. - * @param dialog the popu dialog - * @param archNew the gameObject which has the error to be added - * @param errors list of all errors (= initial content of the textarea) - * @param keepB button "keep what is in the textfield" - * @param textNew textfield containing the error-text to keep + * @param dialog the popu dialog + * @param gameObject the gameObject which has the error to be added + * @param errors list of all errors (= initial content of the textarea) + * @param keepB button "keep what is in the textfield" + * @param textNew textfield containing the error-text to keep */ - ConfirmErrorsAL(final JDialog dialog, final GameObject archNew, final String errors, final JButton keepB, final JTextArea textNew) { - arch = archNew; + ConfirmErrorsAL(final JDialog dialog, final GameObject gameObject, final String errors, final JButton keepB, final JTextArea textNew) { + this.gameObject = gameObject; keepButton = keepB; text = textNew; this.dialog = dialog; @@ -1636,7 +1636,7 @@ // the user pressed "keep", so we append the contents // of the textfield to the archtext if (text.getText() != null && text.getText().trim().length() > 0) { - arch.addObjectText(text.getText().trim()); + gameObject.addObjectText(text.getText().trim()); } } @@ -1647,7 +1647,7 @@ /** {@inheritDoc} */ @Override public void windowClosing(final WindowEvent e) { - arch.addObjectText(allErrors.trim()); + gameObject.addObjectText(allErrors.trim()); // nuke the popup dialog dialog.dispose(); @@ -1670,12 +1670,12 @@ /** * Constructor. - * @param frameNew the attribute-dialog mainframe - * @param archNew the gameObject which has the error to be added + * @param frameNew the attribute-dialog mainframe + * @param gameObject the gameObject which has the error to be added */ - TypesBoxAL(final CAttribDialog frameNew, final GameObject archNew) { + TypesBoxAL(final CAttribDialog frameNew, final GameObject gameObject) { frame = frameNew; - gameObject = archNew; + this.gameObject = gameObject; ignoreEvent = false; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-27 21:57:48
|
Revision: 733 http://svn.sourceforge.net/gridarta/?rev=733&view=rev Author: akirschbaum Date: 2006-11-27 13:57:49 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Whitespace changes. Modified Paths: -------------- trunk/daimonin/src/daieditor/CAttribDialog.java Modified: trunk/daimonin/src/daieditor/CAttribDialog.java =================================================================== --- trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:54:21 UTC (rev 732) +++ trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:57:49 UTC (rev 733) @@ -1262,16 +1262,14 @@ if (inline != null) { final boolean isNone = inline.equals(CFTreasureListTree.NONE_SYM) || inline.length() == 0; - if (!isNone && !CFTreasureListTree.containsTreasureList(inline) - && !inline.equalsIgnoreCase(archetype.getAttributeString(attr.ref.getNameOld()))) { + if (!isNone && !CFTreasureListTree.containsTreasureList(inline) && !inline.equalsIgnoreCase(archetype.getAttributeString(attr.ref.getNameOld()))) { // The user has specified a WRONG treasurelist name, and it does not come // from the default gameObject. -> Error and out. showMessageDialog(this, "In attribute '" + attr.ref.getNameNew() + "':\n" + '\'' + inline + "' is not a known treasurelist name!", "Input Error", ERROR_MESSAGE); return false; } - if (!inline.equalsIgnoreCase(archetype.getAttributeString(attr.ref.getNameOld())) - && !(isNone && archetype.getAttributeString(attr.ref.getNameOld()).length() == 0)) { + if (!inline.equalsIgnoreCase(archetype.getAttributeString(attr.ref.getNameOld())) && !(isNone && archetype.getAttributeString(attr.ref.getNameOld()).length() == 0)) { if (isNone) { newArchText = newArchText + attr.ref.getNameOld() + " none\n"; } else { @@ -1289,8 +1287,7 @@ // ### TODO: for changed types, copy fixed attributes over default arches ### if (type.getAttr()[i].getDataType() == FIXED) { final String defaultValue = archetype.getAttributeString(type.getAttr()[i].getNameOld()); - if (defaultValue.length() == 0 || gameObject.getArchTypNr() != archetype.getArchTypNr() && !defaultValue.equalsIgnoreCase(type.getAttr()[i].getNameNew())) - { + if (defaultValue.length() == 0 || gameObject.getArchTypNr() != archetype.getArchTypNr() && !defaultValue.equalsIgnoreCase(type.getAttr()[i].getNameNew())) { // usually, fixed attributes are only applied when *not* defined in the archetype. // the reason behind this is: if the default gameObject violates our fixed attribute, // we assume the default gameObject is "right" and we are "wrong". The typedefs aren't that trustworthy. @@ -1702,8 +1699,7 @@ if (deselected == null) { deselected = frame.type.getTypeName(); } - if (showConfirmDialog(frame, "Do you really want to change the type of this\nobject from \"" + deselected + "\" to \"" + newType.getTypeName() + "\"?", "Confirm", YES_NO_OPTION, INFORMATION_MESSAGE) == YES_OPTION) - { + if (showConfirmDialog(frame, "Do you really want to change the type of this\nobject from \"" + deselected + "\" to \"" + newType.getTypeName() + "\"?", "Confirm", YES_NO_OPTION, INFORMATION_MESSAGE) == YES_OPTION) { // change is confirmed, now get it on... frame.type = newType; // set new type structure This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-27 21:54:20
|
Revision: 732 http://svn.sourceforge.net/gridarta/?rev=732&view=rev Author: akirschbaum Date: 2006-11-27 13:54:21 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Use correct window title in attribute dialog. Modified Paths: -------------- trunk/daimonin/src/daieditor/CAttribDialog.java trunk/daimonin/src/daieditor/messages.properties trunk/daimonin/src/daieditor/messages_de.properties Modified: trunk/daimonin/src/daieditor/CAttribDialog.java =================================================================== --- trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:50:24 UTC (rev 731) +++ trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:54:21 UTC (rev 732) @@ -186,7 +186,7 @@ dialogs.get(gameObject).toFront(); } else { final CAttribDialog pane = new CAttribDialog(atList, gameObject, mainControl); - final JDialog dialog = pane.createDialog(mainControl.getMainView(), "Dummy gameObject attributes"); + final JDialog dialog = pane.createDialog(mainControl.getMainView(), ACTION_FACTORY.getString("attribTitle")); dialog.getRootPane().setDefaultButton(pane.okButton); dialog.setResizable(true); dialog.setModal(false); Modified: trunk/daimonin/src/daieditor/messages.properties =================================================================== --- trunk/daimonin/src/daieditor/messages.properties 2006-11-27 21:50:24 UTC (rev 731) +++ trunk/daimonin/src/daieditor/messages.properties 2006-11-27 21:54:21 UTC (rev 732) @@ -321,6 +321,7 @@ oldLibsFound.title=Delete old libraries? #attribute dialog +attribTitle=Object Attributes attribHelp.text=Help attribSummary.text=Summary attribEdit.text=Edit Modified: trunk/daimonin/src/daieditor/messages_de.properties =================================================================== --- trunk/daimonin/src/daieditor/messages_de.properties 2006-11-27 21:50:24 UTC (rev 731) +++ trunk/daimonin/src/daieditor/messages_de.properties 2006-11-27 21:54:21 UTC (rev 732) @@ -136,6 +136,7 @@ arcDoc.htmlText=<html><head><meta name="CFJavaEditor" content="tmp"><title>{0}</title></head><body><h1 style="text-align:center;colour:navy;">Type: {0}</h1><h3 style="colour:navy;">Funktionalit\xE4t von {0}</h3><p>{1}</p><h3 style="colour:navy;">Nutzungshinweise:</h3><p>{2}</p></body></html> #attribute dialog +attribTitle=Objektattribute attribHelp.text=Hilfe attribSummary.text=Zusammenfassung attribEdit.text=Bearbeiten This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-27 21:50:25
|
Revision: 731 http://svn.sourceforge.net/gridarta/?rev=731&view=rev Author: akirschbaum Date: 2006-11-27 13:50:24 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Fix typo in comment. Modified Paths: -------------- trunk/daimonin/src/daieditor/messages.properties trunk/daimonin/src/daieditor/messages_sv.properties Modified: trunk/daimonin/src/daieditor/messages.properties =================================================================== --- trunk/daimonin/src/daieditor/messages.properties 2006-11-27 21:48:25 UTC (rev 730) +++ trunk/daimonin/src/daieditor/messages.properties 2006-11-27 21:50:24 UTC (rev 731) @@ -320,7 +320,7 @@ oldLibsFound.message=Old libraries found.\nLocation: {0}\nThey aren''t used anymore.\nDelete them? oldLibsFound.title=Delete old libraries? -# Attribues +#attribute dialog attribHelp.text=Help attribSummary.text=Summary attribEdit.text=Edit Modified: trunk/daimonin/src/daieditor/messages_sv.properties =================================================================== --- trunk/daimonin/src/daieditor/messages_sv.properties 2006-11-27 21:48:25 UTC (rev 730) +++ trunk/daimonin/src/daieditor/messages_sv.properties 2006-11-27 21:50:24 UTC (rev 731) @@ -311,7 +311,7 @@ oldLibsFound=Hittade gamla bibliotek.\nS\xF6kv\xE4g: {0}\nDe anv\xE4nds inte l\xE4ngre. Skall jag ta bort dem? oldLibsFound.title=Ta bort gamla bibliotek? -# Attribues +#attribute dialog attribHelp.text=Hj\xE4lp attribSummary.text=Sammanfattning attribEdit.text=Redigera This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-27 21:48:25
|
Revision: 730 http://svn.sourceforge.net/gridarta/?rev=730&view=rev Author: akirschbaum Date: 2006-11-27 13:48:25 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Add German translation for attribute dialog. Modified Paths: -------------- trunk/daimonin/src/daieditor/messages_de.properties Modified: trunk/daimonin/src/daieditor/messages_de.properties =================================================================== --- trunk/daimonin/src/daieditor/messages_de.properties 2006-11-27 21:19:48 UTC (rev 729) +++ trunk/daimonin/src/daieditor/messages_de.properties 2006-11-27 21:48:25 UTC (rev 730) @@ -135,6 +135,14 @@ arcDoc.htmlText=<html><head><meta name="CFJavaEditor" content="tmp"><title>{0}</title></head><body><h1 style="text-align:center;colour:navy;">Type: {0}</h1><h3 style="colour:navy;">Funktionalit\xE4t von {0}</h3><p>{1}</p><h3 style="colour:navy;">Nutzungshinweise:</h3><p>{2}</p></body></html> +#attribute dialog +attribHelp.text=Hilfe +attribSummary.text=Zusammenfassung +attribEdit.text=Bearbeiten +attribOk.text=Ok +attribApply.text=Anwenden +attribCancel.text=Abbrechen + ################## # Status Messages This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-27 21:19:47
|
Revision: 729 http://svn.sourceforge.net/gridarta/?rev=729&view=rev Author: akirschbaum Date: 2006-11-27 13:19:48 -0800 (Mon, 27 Nov 2006) Log Message: ----------- Whitespace changes. Modified Paths: -------------- trunk/daimonin/src/daieditor/CAttribDialog.java trunk/daimonin/src/daieditor/CopyBuffer.java trunk/daimonin/src/daieditor/gui/map/DefaultLevelRenderer.java Modified: trunk/daimonin/src/daieditor/CAttribDialog.java =================================================================== --- trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-26 21:35:19 UTC (rev 728) +++ trunk/daimonin/src/daieditor/CAttribDialog.java 2006-11-27 21:19:48 UTC (rev 729) @@ -900,7 +900,7 @@ * @return Object[] with dialog options */ private Object[] buildOptions() { - return new Object[]{ + return new Object[] { new JButton(ACTION_FACTORY.createAction(false, "attribHelp", this)), summaryEditButton = new JButton(summaryAction), Box.createHorizontalStrut(32), Modified: trunk/daimonin/src/daieditor/CopyBuffer.java =================================================================== --- trunk/daimonin/src/daieditor/CopyBuffer.java 2006-11-26 21:35:19 UTC (rev 728) +++ trunk/daimonin/src/daieditor/CopyBuffer.java 2006-11-27 21:19:48 UTC (rev 729) @@ -448,7 +448,7 @@ } /** - * Returns mapControl for{@link #copyMap}. + * Returns mapControl for {@link #copyMap}. * @return mapControl for */ @Nullable public MapControl getCopyMapCtrl() { Modified: trunk/daimonin/src/daieditor/gui/map/DefaultLevelRenderer.java =================================================================== --- trunk/daimonin/src/daieditor/gui/map/DefaultLevelRenderer.java 2006-11-26 21:35:19 UTC (rev 728) +++ trunk/daimonin/src/daieditor/gui/map/DefaultLevelRenderer.java 2006-11-27 21:19:48 UTC (rev 729) @@ -164,7 +164,7 @@ if (mapLocation == null) { return null; } - if (mapGrid.hasError(mapLocation)){ + if (mapGrid.hasError(mapLocation)) { final MapSquare<GameObject> mapSquare = mapModel.getMapSquare(mapLocation); if (erraneousMapSquares.containsKey(mapSquare)) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 21:35:20
|
Revision: 728 http://svn.sourceforge.net/gridarta/?rev=728&view=rev Author: akirschbaum Date: 2006-11-26 13:35:19 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify @Deprecated annotation. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 20:58:10 UTC (rev 727) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 21:35:19 UTC (rev 728) @@ -57,14 +57,14 @@ * The CMainControl used for various operations. * @deprecated it's not a good idea to require the MapModel implementation to know such a heavy-weight strongly UI-related glue class like {@link CMainControl}. */ - private final CMainControl mainControl; + @Deprecated private final CMainControl mainControl; /** * The MapControl that controls this MapModel. * @deprecated it's not a good idea to require the MapModel implementation to know such a heavy-weight strongly UI-related glue class like {@link MapControl}. * @todo care about Serialization if this field remains */ - private final MapControl mapControl; + @Deprecated private final MapControl mapControl; /** * Constructs a level model. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 20:58:09
|
Revision: 727 http://svn.sourceforge.net/gridarta/?rev=727&view=rev Author: akirschbaum Date: 2006-11-26 12:58:10 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Add log4j configuration to DaimoninEditor.jar. Modified Paths: -------------- trunk/daimonin/build.xml Added Paths: ----------- trunk/daimonin/resource/log4j.properties Modified: trunk/daimonin/build.xml =================================================================== --- trunk/daimonin/build.xml 2006-11-26 20:54:19 UTC (rev 726) +++ trunk/daimonin/build.xml 2006-11-26 20:58:10 UTC (rev 727) @@ -99,6 +99,7 @@ <include name="icons/**/*.*"/> <include name="toolbarButtonGraphics/**/*.*"/> <include name="system/**/*.*"/> + <include name="log4j.properties"/> <exclude name="**/.xvpics/**"/> </fileset> </copy> Added: trunk/daimonin/resource/log4j.properties =================================================================== --- trunk/daimonin/resource/log4j.properties (rev 0) +++ trunk/daimonin/resource/log4j.properties 2006-11-26 20:58:10 UTC (rev 727) @@ -0,0 +1,9 @@ +# Set root logger level to INFO and its only appender to A1. +log4j.rootLogger=INFO, A1 + +# A1 is set to be a ConsoleAppender. +log4j.appender.A1=org.apache.log4j.ConsoleAppender + +# A1 uses PatternLayout. +log4j.appender.A1.layout=org.apache.log4j.PatternLayout +log4j.appender.A1.layout.ConversionPattern=%-5p(%t) %-30c %x - %m%n Property changes on: trunk/daimonin/resource/log4j.properties ___________________________________________________________________ Name: svn:mime-type + text/plain Name: svn:eol-style + LF This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 20:54:18
|
Revision: 726 http://svn.sourceforge.net/gridarta/?rev=726&view=rev Author: akirschbaum Date: 2006-11-26 12:54:19 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Remove unused logging specifications. Modified Paths: -------------- trunk/crossfire/resource/log4j.properties Modified: trunk/crossfire/resource/log4j.properties =================================================================== --- trunk/crossfire/resource/log4j.properties 2006-11-26 20:22:24 UTC (rev 725) +++ trunk/crossfire/resource/log4j.properties 2006-11-26 20:54:19 UTC (rev 726) @@ -7,7 +7,3 @@ # A1 uses PatternLayout. log4j.appender.A1.layout=org.apache.log4j.PatternLayout log4j.appender.A1.layout.ConversionPattern=%-5p(%t) %-30c %x - %m%n - -# don't show debug & info logs from NamedFilter (slows interface like hell) -log4j.logger.cfeditor.filter.NamedFilterConfig=WARN -log4j.logger.cfeditor.filter.NamedFilterList=WARN This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 20:22:24
|
Revision: 725 http://svn.sourceforge.net/gridarta/?rev=725&view=rev Author: akirschbaum Date: 2006-11-26 12:22:24 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Prevent spurious warning messages for inventory objects. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java Modified: trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java =================================================================== --- trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java 2006-11-26 20:19:39 UTC (rev 724) +++ trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java 2006-11-26 20:22:24 UTC (rev 725) @@ -72,18 +72,18 @@ /** {@inheritDoc} */ public void expandMulti(final G gameObject, final List<G> objects) { - if (gameObject.isInContainer()) { - log.warn("Multipart expansion for a GameObject inside a container requested."); - return; - } - final G archetype = gameObject.getArchetype(); - // is it a multi head? + // is it a multi head (without any tail parts)? if (archetype == null || !archetype.isMulti() || gameObject.getMultiRefCount() > 1) { return; } + if (gameObject.isInContainer()) { + log.warn("Multipart expansion for a GameObject inside a container requested."); + return; + } + // we have a multi head and need to insert his tail now // do insertion for all non-head parts of the multi This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 20:19:45
|
Revision: 724 http://svn.sourceforge.net/gridarta/?rev=724&view=rev Author: akirschbaum Date: 2006-11-26 12:19:39 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Replace if statement by guard. Modified Paths: -------------- trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java Modified: trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java =================================================================== --- trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java 2006-11-26 20:06:01 UTC (rev 723) +++ trunk/src/app/net/sf/gridarta/gameobject/AbstractArchetypeParser.java 2006-11-26 20:19:39 UTC (rev 724) @@ -80,24 +80,26 @@ final G archetype = gameObject.getArchetype(); // is it a multi head? - if (archetype != null && archetype.isMulti() && gameObject.getMultiRefCount() <= 1) { - // we have a multi head and need to insert his tail now + if (archetype == null || !archetype.isMulti() || gameObject.getMultiRefCount() > 1) { + return; + } - // do insertion for all non-head parts of the multi - for (G oldPart = archetype.getMultiNext(); oldPart != null; oldPart = oldPart.getMultiNext()) { - final G newarch = oldPart.createArch(); + // we have a multi head and need to insert his tail now - gameObject.addTailPart(newarch); - objects.add(newarch); + // do insertion for all non-head parts of the multi + for (G oldPart = archetype.getMultiNext(); oldPart != null; oldPart = oldPart.getMultiNext()) { + final G newarch = oldPart.createArch(); - // set map position (x, y) - newarch.setMapX(gameObject.getMapX() + newarch.getMultiX()); - newarch.setMapY(gameObject.getMapY() + newarch.getMultiY()); + gameObject.addTailPart(newarch); + objects.add(newarch); - // now attach the default arch and stuff - // (don't need edit type as we copy from head) - postParseGameObject(newarch, 0); - } + // set map position (x, y) + newarch.setMapX(gameObject.getMapX() + newarch.getMultiX()); + newarch.setMapY(gameObject.getMapY() + newarch.getMultiY()); + + // now attach the default arch and stuff + // (don't need edit type as we copy from head) + postParseGameObject(newarch, 0); } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 20:06:01
|
Revision: 723 http://svn.sourceforge.net/gridarta/?rev=723&view=rev Author: akirschbaum Date: 2006-11-26 12:06:01 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify checking for duplicate archetypes when adding game objects to maps. Modified Paths: -------------- trunk/crossfire/src/cfeditor/CMainControl.java trunk/crossfire/src/cfeditor/CMapViewBasic.java trunk/crossfire/src/cfeditor/CopyBuffer.java trunk/crossfire/src/cfeditor/ReplaceDialog.java trunk/crossfire/src/cfeditor/map/DefaultMapModel.java trunk/crossfire/src/cfeditor/map/MapControl.java trunk/crossfire/src/cfeditor/map/MapModel.java Modified: trunk/crossfire/src/cfeditor/CMainControl.java =================================================================== --- trunk/crossfire/src/cfeditor/CMainControl.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/CMainControl.java 2006-11-26 20:06:01 UTC (rev 723) @@ -509,8 +509,8 @@ return JFontChooser.msgToHtml(msg, null); } - boolean addArchToMap(final String archname, final Point pos, final int intern, final boolean join) { - return currentMap.addArchToMap(archname, pos, intern, join); + boolean addArchToMap(final String archname, final Point pos, final boolean allowDouble, final boolean join) { + return currentMap.addArchToMap(archname, pos, allowDouble, join); } boolean insertArchToMap(final GameObject newarch, final String archname, final GameObject next, final Point pos, final boolean join) { Modified: trunk/crossfire/src/cfeditor/CMapViewBasic.java =================================================================== --- trunk/crossfire/src/cfeditor/CMapViewBasic.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/CMapViewBasic.java 2006-11-26 20:06:01 UTC (rev 723) @@ -113,9 +113,6 @@ private final boolean[] needMpanelUpdate; // indicates that the mapArchPanel needs - // to be updated when mousebutton is released - private int drawInternCount; - // interface for the mapview frame private final MapView frame; @@ -139,7 +136,6 @@ needMpanelUpdate[0] = false; needMpanelUpdate[1] = false; needMpanelUpdate[2] = false; - drawInternCount = 0; mapMousePos.x = -1; mapMousePos.y = -1; mapMouseRightPos.x = -1; @@ -1350,7 +1346,7 @@ if (!mainControl.getMainView().isPickmapActive() || mapControl.isPickmap() || (newarch != null && newarch.isArchetype())) { // insert default arch from archlist: - if (!mapControl.addArchToMap(mainControl.getPanelArch(), pos, allowMany ? -1 : drawInternCount, MapModel.JOIN_ENABLE)) { + if (!mapControl.addArchToMap(mainControl.getPanelArch(), pos, allowMany, MapModel.JOIN_ENABLE)) { // mainControl.getMainView().mapPanel.setMapArchList(null); // Toolkit.getDefaultToolkit().beep(); } else { @@ -1385,7 +1381,7 @@ // insert multi tile from pickmap: newarch = newarch.getHead(); // first insert default arch from archlist - if (!mapControl.addArchToMap(newarch.getArchetypeName(), pos, allowMany ? -1 : drawInternCount, MapModel.JOIN_DISABLE)) { + if (!mapControl.addArchToMap(newarch.getArchetypeName(), pos, allowMany, MapModel.JOIN_DISABLE)) { // do nothing } else { // insertion successful, now get redraw info @@ -1451,7 +1447,7 @@ } // first insert default arch from archlist - if (!allSpacesFree || !mapControl.addArchToMap(newarch.getArchetypeName(), pos, -1, MapModel.JOIN_DISABLE)) { + if (!allSpacesFree || !mapControl.addArchToMap(newarch.getArchetypeName(), pos, true, MapModel.JOIN_DISABLE)) { // do nothing } else { // insertion successful, now get redraw info Modified: trunk/crossfire/src/cfeditor/CopyBuffer.java =================================================================== --- trunk/crossfire/src/cfeditor/CopyBuffer.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/CopyBuffer.java 2006-11-26 20:06:01 UTC (rev 723) @@ -264,7 +264,7 @@ sourcePos.y = pos.y - startp.y; for (final GameObject gameObject : copyMapCtrl.getMapModel().getMapSquare(sourcePos)) { if (gameObject.isMulti()) { - addArchToMap(mapControl, gameObject, pos, -1, false); + addArchToMap(mapControl, gameObject, pos, true, false); } } } @@ -328,7 +328,7 @@ continue; } // Insert the new arch into the map - addArchToMap(mapControl, arch, pos, 0, fillBelow); + addArchToMap(mapControl, arch, pos, false, fillBelow); } } } @@ -349,7 +349,7 @@ * @param arch GameObject to fill with */ private void floodfill(final MapControl mapControl, final int startX, final int startY, final GameObject arch) { - addArchToMap(mapControl, arch, new Point(startX, startY), 0, false); + addArchToMap(mapControl, arch, new Point(startX, startY), false, false); // now go recursive into all four directions if (mapControl.isPointValid(startX - 1, startY) && !mapControl.containsArchObject(startX - 1, startY)) { @@ -370,10 +370,10 @@ * Add an archetype to the destination map. Inserts a new object instance * for default archetypes, and a clone for non-default archetypes. */ - private void addArchToMap(final MapControl mapControl, final GameObject gameObject, final Point pos, final int intern, final boolean fillBelow) { + private void addArchToMap(final MapControl mapControl, final GameObject gameObject, final Point pos, final boolean allowDouble, final boolean fillBelow) { final GameObject newHead; if (gameObject.isArchetype()) { - mapControl.addArchToMap(gameObject.getArchetypeName(), pos, intern, false, fillBelow); + mapControl.addArchToMap(gameObject.getArchetypeName(), pos, allowDouble, false, fillBelow); } else { newHead = gameObject.createClone(pos.x, pos.y); for (GameObject tmp = gameObject.getArchetype().getMultiNext(); tmp != null; tmp = tmp.getMultiNext()) { Modified: trunk/crossfire/src/cfeditor/ReplaceDialog.java =================================================================== --- trunk/crossfire/src/cfeditor/ReplaceDialog.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/ReplaceDialog.java 2006-11-26 20:06:01 UTC (rev 723) @@ -344,7 +344,7 @@ if (replaceArch.isMulti()) { // multi's cannot be inserted properly, so we just put them ontop replaceArch = replaceArch.getHead(); - mapControl.addArchToMap(replaceArch.getArchetypeName(), pos, 0, false); + mapControl.addArchToMap(replaceArch.getArchetypeName(), pos, false, false); // TODO: if from pickmap it could have special attributes -> copy them } else { Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 20:06:01 UTC (rev 723) @@ -208,28 +208,19 @@ return isPointValid(pos) && !mapGrid[pos.x][pos.y].isEmpty(); } - /** - * Check if a given archetype fits within map bounds. Multi tiles can't be - * set if going out of borders. - * @param archName the archetype to check - * @param xx the x-coordinate to place archName - * @param yy the y-coordinate to place archName - * @param intern ??? - */ - private boolean testArchToMap(final String archName, final int xx, final int yy, final int intern) { + /** {@inheritDoc} */ + public boolean isMultiArchFittingToMap(final String archName, final Point pos, final boolean allowDouble) { for (GameObject part = getArchetype(archName); part != null; part = part.getMultiNext()) { - final int mapx = xx + part.getMultiX(); - final int mapy = yy + part.getMultiY(); + final int mapx = pos.x + part.getMultiX(); + final int mapy = pos.y + part.getMultiY(); if (!isPointValid(mapx, mapy)) { // outside map return false; } - if (intern != -1) { // we use this different - only one object + if (!allowDouble) { final String temp = part.getArchetypeName(); - // run through map parts and test for intern counter - // if == intern, this is painted from this action for (final GameObject node : getMapSquare(new Point(mapx, mapy))) { if (node.getArchetypeName().equals(temp)) { return false; @@ -241,8 +232,8 @@ return true; } - @Deprecated public boolean addArchToMap(final String archName, final int xx, final int yy, final int intern, final boolean join, final boolean insertBelow) { - return addArchToMap(archName, new Point(xx, yy), intern, join, insertBelow); + @Deprecated public boolean addArchToMap(final String archName, final int xx, final int yy, final boolean allowDouble, final boolean join, final boolean insertBelow) { + return addArchToMap(archName, new Point(xx, yy), allowDouble, join, insertBelow); } /** @@ -250,7 +241,7 @@ * allows only to choose from the default arches (->archName). * @param archName Name of a default arch on the ArchetypeSet * @param pos insert-location on this map - * @param intern if NOT '-1': only one arch of the same kind can be + * @param allowDouble if set, only one arch of the same kind can be * inserted per square * @param join if set to JOIN_ENABLE auto-joining is supported; autojoining * is only done if enabled in the main control @@ -258,14 +249,14 @@ * inserted below * @return true if insertion successful, false if not */ - public boolean addArchToMap(String archName, final Point pos, final int intern, final boolean join, final boolean insertBelow) { + public boolean addArchToMap(String archName, final Point pos, final boolean allowDouble, final boolean join, final boolean insertBelow) { GameObject newarch; // our new suckers (copys, not ref ptrs) if (archName == null || !isPointValid(pos)) { // invalid parameter return false; } - if (!testArchToMap(archName, pos.x, pos.y, intern)) { + if (!isMultiArchFittingToMap(archName, pos, allowDouble)) { // does not fit on map return false; } @@ -354,7 +345,7 @@ archName = newarch.getArchetypeName(); } // insert a new instance of the default arch (number 'archName') - if (!mapControl.addArchToMap(archName, pos, -1, join)) { + if (!mapControl.addArchToMap(archName, pos, true, join)) { return false; } } else { Modified: trunk/crossfire/src/cfeditor/map/MapControl.java =================================================================== --- trunk/crossfire/src/cfeditor/map/MapControl.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/map/MapControl.java 2006-11-26 20:06:01 UTC (rev 723) @@ -199,26 +199,26 @@ return levelClosing; } - public boolean addArchToMap(final String archname, final Point pos, final int intern, final boolean join, final boolean insertBelow) { - return mapModel.addArchToMap(archname, pos, intern, join, insertBelow); + public boolean addArchToMap(final String archname, final Point pos, final boolean allowDouble, final boolean join, final boolean insertBelow) { + return mapModel.addArchToMap(archname, pos, allowDouble, join, insertBelow); } /** wrapper method for addArchToMap, always inserting new arches on top */ - public boolean addArchToMap(final String archname, final Point pos, final int intern, final boolean join) { - return addArchToMap(archname, pos, intern, join, false); + public boolean addArchToMap(final String archname, final Point pos, final boolean allowDouble, final boolean join) { + return addArchToMap(archname, pos, allowDouble, join, false); } /** wrapper method for addArchToMap, always inserting new arches on top. * @param archname * @param xx * @param yy - * @param intern + * @param allowDouble * @param join * @return <code>true</code> if insertion is successful, <code>false</code> if not * @deprecated use {@link #addArchToMap(String, Point, int, boolean, boolean)} instead */ - @Deprecated public boolean addArchToMap(final String archname, final int xx, final int yy, final int intern, final boolean join) { - return addArchToMap(archname, new Point(xx, yy), intern, join, false); + @Deprecated public boolean addArchToMap(final String archname, final int xx, final int yy, final boolean allowDouble, final boolean join) { + return addArchToMap(archname, new Point(xx, yy), allowDouble, join, false); } public boolean insertArchToMap(final GameObject newarch, final String archname, final GameObject next, final Point pos, final boolean join) { Modified: trunk/crossfire/src/cfeditor/map/MapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/MapModel.java 2006-11-26 19:53:35 UTC (rev 722) +++ trunk/crossfire/src/cfeditor/map/MapModel.java 2006-11-26 20:06:01 UTC (rev 723) @@ -18,9 +18,21 @@ @Nullable Point getMouseRightPos(); - @Deprecated boolean addArchToMap(String archname, int xx, int yy, int intern, boolean join, boolean insertBelow); - boolean addArchToMap(String archname, Point pos, int intern, boolean join, boolean insertBelow); + /** + * Checks whether an GameObject (multi-arch) would still fit on this map. + * @param archname name of arch to check + * @param pos position of multitile head + * @param allowDouble whether overlapping multitile arches should be allowed (check is done using the arch name) + * @return whether the multi-arch would still fit on this map + * @retval <code>true</code> if the multi-tile arch would still fit on this map + * @retval <code>false</code> otherwise + * @todo discuss whether this method really belongs to the interface of MapModel as it is only used by MapModel implementations and heavily depends on how arches, especially multi-tile arches are implemented. + */ + boolean isMultiArchFittingToMap(String archname, Point pos, boolean allowDouble); + @Deprecated boolean addArchToMap(String archname, int xx, int yy, boolean allowDouble, boolean join, boolean insertBelow); + boolean addArchToMap(String archname, Point pos, boolean allowDouble, boolean join, boolean insertBelow); + @Deprecated boolean insertArchToMap(GameObject newarch, String archname, GameObject next, int mapx, int mapy, boolean join); boolean insertArchToMap(GameObject newarch, String archname, GameObject next, Point pos, boolean join); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2006-11-26 19:53:35
|
Revision: 722 http://svn.sourceforge.net/gridarta/?rev=722&view=rev Author: christianhujer Date: 2006-11-26 11:53:35 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Improved comments. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java trunk/daimonin/src/daieditor/map/DefaultMapModel.java Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:38:59 UTC (rev 721) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:53:35 UTC (rev 722) @@ -750,14 +750,14 @@ */ /** - * Get a default {@link GameObject} instance. + * Get an Archetype. * * @param archName the archetype name * - * @return the default arch object instance corresponding to + * @return the Archetype corresponding to * <code>archName</code>, or <code>null</code> if it does not exist */ - private GameObject getArchetype(final String archName) { + @Nullable private GameObject getArchetype(final String archName) { return mainControl.getArchetypeSet().getArchetype(archName); } Modified: trunk/daimonin/src/daieditor/map/DefaultMapModel.java =================================================================== --- trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 19:38:59 UTC (rev 721) +++ trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 19:53:35 UTC (rev 722) @@ -294,14 +294,14 @@ } /** - * Get a default {@link GameObject} instance. + * Get an Archetype. * * @param archName the archetype name * - * @return the default arch object instance corresponding to + * @return the Archetype corresponding to * <code>archName</code>, or <code>null</code> if it does not exist */ - private GameObject getArchetype(final String archName) { + @Nullable private GameObject getArchetype(final String archName) { return mainControl.getArchetypeSet().getArchetype(archName); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 19:38:59
|
Revision: 721 http://svn.sourceforge.net/gridarta/?rev=721&view=rev Author: akirschbaum Date: 2006-11-26 11:38:59 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify comments. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java trunk/daimonin/src/daieditor/map/DefaultMapModel.java Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:33:16 UTC (rev 720) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:38:59 UTC (rev 721) @@ -53,18 +53,24 @@ /** Flag that indicates if the level has been changed since last save. */ private boolean levelChanged = false; - /** CMainControl. */ + /** + * The CMainControl used for various operations. + * @deprecated it's not a good idea to require the MapModel implementation to know such a heavy-weight strongly UI-related glue class like {@link CMainControl}. + */ private final CMainControl mainControl; - /** The MapControl that controls this MapModel. */ + /** + * The MapControl that controls this MapModel. + * @deprecated it's not a good idea to require the MapModel implementation to know such a heavy-weight strongly UI-related glue class like {@link MapControl}. + * @todo care about Serialization if this field remains + */ private final MapControl mapControl; /** * Constructs a level model. * @param mainControl main controller * @param mapControl the controller of this view - * @param objects the <code>GameObject</code> list of this map or - * <code>null</code> for an empty map + * @param objects the <code>GameObject</code> list of this map or <code>null</code> for an empty map * @param mapArch the map header (<code>MapArchObject</code>) */ public DefaultMapModel(final CMainControl mainControl, final MapControl mapControl, final List<GameObject> objects, final MapArchObject mapArch) { @@ -746,7 +752,7 @@ /** * Get a default {@link GameObject} instance. * - * @param archName arch naem + * @param archName the archetype name * * @return the default arch object instance corresponding to * <code>archName</code>, or <code>null</code> if it does not exist Modified: trunk/daimonin/src/daieditor/map/DefaultMapModel.java =================================================================== --- trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 19:33:16 UTC (rev 720) +++ trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 19:38:59 UTC (rev 721) @@ -294,7 +294,7 @@ } /** - * Get an Archetype. + * Get a default {@link GameObject} instance. * * @param archName the archetype name * This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 19:33:17
|
Revision: 720 http://svn.sourceforge.net/gridarta/?rev=720&view=rev Author: akirschbaum Date: 2006-11-26 11:33:16 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Rename variable name. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:20:41 UTC (rev 719) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 19:33:16 UTC (rev 720) @@ -62,15 +62,15 @@ /** * Constructs a level model. * @param mainControl main controller - * @param control the controller of this view + * @param mapControl the controller of this view * @param objects the <code>GameObject</code> list of this map or * <code>null</code> for an empty map * @param mapArch the map header (<code>MapArchObject</code>) */ - public DefaultMapModel(final CMainControl mainControl, final MapControl control, final List<GameObject> objects, final MapArchObject mapArch) { + public DefaultMapModel(final CMainControl mainControl, final MapControl mapControl, final List<GameObject> objects, final MapArchObject mapArch) { super(mapArch); this.mainControl = mainControl; - mapControl = control; + this.mapControl = mapControl; addObjectListToMap(objects); // init mapArchObject and (when not new map) the arch list } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 19:20:42
|
Revision: 719 http://svn.sourceforge.net/gridarta/?rev=719&view=rev Author: akirschbaum Date: 2006-11-26 11:20:41 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Move unified MultiArchData to gridarta. Modified Paths: -------------- trunk/crossfire/src/cfeditor/gameobject/GameObject.java trunk/daimonin/src/daieditor/gameobject/GameObject.java Added Paths: ----------- trunk/src/app/net/sf/gridarta/gameobject/MultiArchData.java Removed Paths: ------------- trunk/crossfire/src/cfeditor/MultiArchData.java trunk/daimonin/src/daieditor/MultiArchData.java Deleted: trunk/crossfire/src/cfeditor/MultiArchData.java =================================================================== --- trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 19:00:58 UTC (rev 718) +++ trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 19:20:41 UTC (rev 719) @@ -1,217 +0,0 @@ -/* - * Crossfire Java Editor. - * Copyright (C) 2000 Michael Toennies - * Copyright (C) 2001 Andreas Vogl - * Copyright (C) 2006 Andreas Kirschbaum - * - * (code based on: Gridder. 2D grid based level editor. (C) 2000 Pasi Keränen) - * - * 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., 59 Temple Place - Suite 330, Boston, MA - * 02111-1307, USA. - * - */ - -package cfeditor; - -import java.util.ArrayList; -import net.sf.gridarta.gameobject.GameObject; - -/** - * Class related to {@link GameObject} to store multipart information. This - * data is only used for multi-part objects. When the editor is running, - * usually a big number of <code>GameObject</code>s exist - most of them - * single-part objects. The encapsulation of this "multi-part-only" data can - * save a little bit of memory. - * - * @author <a href="mailto:and...@gm...">Andreas Vogl</a> - * @author Andreas Kirschbaum - */ -public final class MultiArchData<G extends GameObject> { - - /** - * Maximum coordinate of any part; it is never negative. - */ - private int maxX = 0; - - /** - * Maximum coordinate of any part; it is never negative. - */ - private int maxY = 0; - - /** - * Minimum coordinate of any part; it is never positive. - */ - private int minX = 0; - - /** - * Minimum coordinate of any part; it is never positive. - */ - private int minY = 0; - - /** - * The shape ID of this object. - */ - private int multiShapeID; - - /** - * All parts belonging to this multi-part object; the first element is the - * head part. - */ - private final ArrayList<G> parts = new ArrayList<G>(); - - /** - * Create a new instance. - * - * @param head the head part of the multi-part object - */ - public MultiArchData(final G head) { - assert head.getMultiX() == 0 && head.getMultiY() == 0; - parts.add(head); - } - - /** - * Return the number of parts this multi-part objects contains. - */ - public int getMultiRefCount() { - return parts.size(); - } - - /** - * Determine the horizontal extent in tiles. For single-part objects 1 is - * returned. - * - * @return the horizontal extent - */ - public int getSizeX() { - return maxX - minX + 1; - } - - /** - * Determine the vertical extent in tiles. For single-part objects 1 is - * returned. - * - * @return the vertical extent - */ - public int getSizeY() { - return maxY - minY + 1; - } - - /** - * Determine the maximum x-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the maximum x-coordinate - */ - public int getMaxX() { - return maxX; - } - - /** - * Determine the maximum y-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the maximum y-coordinate - */ - public int getMaxY() { - return maxY; - } - - /** - * Determine the minimum x-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the minimum x-coordinate - */ - public int getMinX() { - return minX; - } - - /** - * Determine the minimum y-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the minimum y-coordinate - */ - public int getMinY() { - return minY; - } - - /** - * Return the shape ID of this object. - * - * @return the shape ID of this object - */ - public int getMultiShapeID() { - return multiShapeID; - } - - /** - * Set the shape ID of this object. - * - * @param multiShapeID the new shape ID of this object - */ - public void setMultiShapeID(final int multiShapeID) { - this.multiShapeID = multiShapeID; - } - - /** - * Return the head part of this multi-part object. - * - * @return the head part - */ - public G getHead() { - return parts.get(0); - } - - /** - * Return the part following a given part. - * - * @param the current part - * - * @return the part following the current part - */ - public G getNext(final G ob) { - assert ob != null; - final int index = parts.indexOf(ob); - assert index != -1; - return index + 1 < parts.size() ? parts.get(index + 1) : null; - } - - /** - * Add a part to this multi-part object. - * - * @param tail the tail part to add - */ - public void addPart(final G tail) { - assert tail != null; - - parts.add(tail); - - final int x = tail.getMultiX(); - if (x < minX) { - minX = x; - } else if (x > maxX) { - maxX = x; - } - - final int y = tail.getMultiY(); - if (y < minY) { - minY = y; - } else if (y > maxY) { - maxY = y; - } - } - -} // class MultiArchData Modified: trunk/crossfire/src/cfeditor/gameobject/GameObject.java =================================================================== --- trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 19:00:58 UTC (rev 718) +++ trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 19:20:41 UTC (rev 719) @@ -29,7 +29,6 @@ import cfeditor.CFArchTypeList; import cfeditor.CMapArchPanel; import cfeditor.IGUIConstants; -import cfeditor.MultiArchData; import cfeditor.ScriptArchData; import java.io.BufferedReader; import java.io.IOException; @@ -37,6 +36,7 @@ import java.util.Collections; import java.util.List; import javax.swing.JList; +import net.sf.gridarta.gameobject.MultiArchData; import org.apache.log4j.Logger; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; Deleted: trunk/daimonin/src/daieditor/MultiArchData.java =================================================================== --- trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 19:00:58 UTC (rev 718) +++ trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 19:20:41 UTC (rev 719) @@ -1,217 +0,0 @@ -/* - * Daimonin Java Editor. - * Copyright (C) 2000 Michael Toennies - * Copyright (C) 2001 Andreas Vogl - * Copyright (C) 2006 Andreas Kirschbaum - * - * (code based on: Gridder. 2D grid based level editor. (C) 2000 Pasi Keränen) - * - * 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., 59 Temple Place - Suite 330, Boston, MA - * 02111-1307, USA. - * - */ - -package daieditor; - -import java.util.ArrayList; -import net.sf.gridarta.gameobject.GameObject; - -/** - * Class related to {@link GameObject} to store multipart information. This - * data is only used for multi-part objects. When the editor is running, - * usually a big number of <code>GameObject</code>s exist - most of them - * single-part objects. The encapsulation of this "multi-part-only" data can - * save a little bit of memory. - * - * @author <a href="mailto:and...@gm...">Andreas Vogl</a> - * @author Andreas Kirschbaum - */ -public final class MultiArchData<G extends GameObject> { - - /** - * Maximum coordinate of any part; it is never negative. - */ - private int maxX = 0; - - /** - * Maximum coordinate of any part; it is never negative. - */ - private int maxY = 0; - - /** - * Minimum coordinate of any part; it is never positive. - */ - private int minX = 0; - - /** - * Minimum coordinate of any part; it is never positive. - */ - private int minY = 0; - - /** - * The shape ID of this object. - */ - private int multiShapeID; - - /** - * All parts belonging to this multi-part object; the first element is the - * head part. - */ - private final ArrayList<G> parts = new ArrayList<G>(); - - /** - * Create a new instance. - * - * @param head the head part of the multi-part object - */ - public MultiArchData(final G head) { - assert head.getMultiX() == 0 && head.getMultiY() == 0; - parts.add(head); - } - - /** - * Return the number of parts this multi-part objects contains. - */ - public int getMultiRefCount() { - return parts.size(); - } - - /** - * Determine the horizontal extent in tiles. For single-part objects 1 is - * returned. - * - * @return the horizontal extent - */ - public int getSizeX() { - return maxX - minX + 1; - } - - /** - * Determine the vertical extent in tiles. For single-part objects 1 is - * returned. - * - * @return the vertical extent - */ - public int getSizeY() { - return maxY - minY + 1; - } - - /** - * Determine the maximum x-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the maximum x-coordinate - */ - public int getMaxX() { - return maxX; - } - - /** - * Determine the maximum y-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the maximum y-coordinate - */ - public int getMaxY() { - return maxY; - } - - /** - * Determine the minimum x-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the minimum x-coordinate - */ - public int getMinX() { - return minX; - } - - /** - * Determine the minimum y-coordinate of any part. The value is relative to - * the head part. For single-part objects 0 is returned. - * - * @return the minimum y-coordinate - */ - public int getMinY() { - return minY; - } - - /** - * Return the shape ID of this object. - * - * @return the shape ID of this object - */ - public int getMultiShapeID() { - return multiShapeID; - } - - /** - * Set the shape ID of this object. - * - * @param multiShapeID the new shape ID of this object - */ - public void setMultiShapeID(final int multiShapeID) { - this.multiShapeID = multiShapeID; - } - - /** - * Return the head part of this multi-part object. - * - * @return the head part - */ - public G getHead() { - return parts.get(0); - } - - /** - * Return the part following a given part. - * - * @param the current part - * - * @return the part following the current part - */ - public G getNext(final G ob) { - assert ob != null; - final int index = parts.indexOf(ob); - assert index != -1; - return index + 1 < parts.size() ? parts.get(index + 1) : null; - } - - /** - * Add a part to this multi-part object. - * - * @param tail the tail part to add - */ - public void addPart(final G tail) { - assert tail != null; - - parts.add(tail); - - final int x = tail.getMultiX(); - if (x < minX) { - minX = x; - } else if (x > maxX) { - maxX = x; - } - - final int y = tail.getMultiY(); - if (y < minY) { - minY = y; - } else if (y > maxY) { - maxY = y; - } - } - -} // class MultiArchData Modified: trunk/daimonin/src/daieditor/gameobject/GameObject.java =================================================================== --- trunk/daimonin/src/daieditor/gameobject/GameObject.java 2006-11-26 19:00:58 UTC (rev 718) +++ trunk/daimonin/src/daieditor/gameobject/GameObject.java 2006-11-26 19:20:41 UTC (rev 719) @@ -30,7 +30,6 @@ import daieditor.CMainControl; import daieditor.CMapArchPanel; import daieditor.IGUIConstants; -import daieditor.MultiArchData; import daieditor.ScriptArchData; import daieditor.gameobject.anim.AnimationObject; import daieditor.gameobject.anim.AnimationObjects; @@ -38,6 +37,7 @@ import javax.swing.ImageIcon; import javax.swing.JList; import net.sf.gridarta.gameobject.GameObjectContainer; +import net.sf.gridarta.gameobject.MultiArchData; import org.apache.log4j.Logger; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; Added: trunk/src/app/net/sf/gridarta/gameobject/MultiArchData.java =================================================================== --- trunk/src/app/net/sf/gridarta/gameobject/MultiArchData.java (rev 0) +++ trunk/src/app/net/sf/gridarta/gameobject/MultiArchData.java 2006-11-26 19:20:41 UTC (rev 719) @@ -0,0 +1,215 @@ +/* + * Gridarta Editor. + * Copyright (C) 2000 Michael Toennies + * Copyright (C) 2001 Andreas Vogl + * Copyright (C) 2006 Andreas Kirschbaum + * + * (code based on: Gridder. 2D grid based level editor. (C) 2000 Pasi Keränen) + * + * 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., 59 Temple Place - Suite 330, Boston, MA + * 02111-1307, USA. + */ + +package net.sf.gridarta.gameobject; + +import java.util.ArrayList; + +/** + * Class related to {@link GameObject} to store multipart information. This + * data is only used for multi-part objects. When the editor is running, + * usually a big number of <code>GameObject</code>s exist - most of them + * single-part objects. The encapsulation of this "multi-part-only" data can + * save a little bit of memory. + * + * @author <a href="mailto:and...@gm...">Andreas Vogl</a> + * @author Andreas Kirschbaum + */ +public final class MultiArchData<G extends GameObject> { + + /** + * Maximum coordinate of any part; it is never negative. + */ + private int maxX = 0; + + /** + * Maximum coordinate of any part; it is never negative. + */ + private int maxY = 0; + + /** + * Minimum coordinate of any part; it is never positive. + */ + private int minX = 0; + + /** + * Minimum coordinate of any part; it is never positive. + */ + private int minY = 0; + + /** + * The shape ID of this object. + */ + private int multiShapeID; + + /** + * All parts belonging to this multi-part object; the first element is the + * head part. + */ + private final ArrayList<G> parts = new ArrayList<G>(); + + /** + * Create a new instance. + * + * @param head the head part of the multi-part object + */ + public MultiArchData(final G head) { + assert head.getMultiX() == 0 && head.getMultiY() == 0; + parts.add(head); + } + + /** + * Return the number of parts this multi-part objects contains. + */ + public int getMultiRefCount() { + return parts.size(); + } + + /** + * Determine the horizontal extent in tiles. For single-part objects 1 is + * returned. + * + * @return the horizontal extent + */ + public int getSizeX() { + return maxX - minX + 1; + } + + /** + * Determine the vertical extent in tiles. For single-part objects 1 is + * returned. + * + * @return the vertical extent + */ + public int getSizeY() { + return maxY - minY + 1; + } + + /** + * Determine the maximum x-coordinate of any part. The value is relative to + * the head part. For single-part objects 0 is returned. + * + * @return the maximum x-coordinate + */ + public int getMaxX() { + return maxX; + } + + /** + * Determine the maximum y-coordinate of any part. The value is relative to + * the head part. For single-part objects 0 is returned. + * + * @return the maximum y-coordinate + */ + public int getMaxY() { + return maxY; + } + + /** + * Determine the minimum x-coordinate of any part. The value is relative to + * the head part. For single-part objects 0 is returned. + * + * @return the minimum x-coordinate + */ + public int getMinX() { + return minX; + } + + /** + * Determine the minimum y-coordinate of any part. The value is relative to + * the head part. For single-part objects 0 is returned. + * + * @return the minimum y-coordinate + */ + public int getMinY() { + return minY; + } + + /** + * Return the shape ID of this object. + * + * @return the shape ID of this object + */ + public int getMultiShapeID() { + return multiShapeID; + } + + /** + * Set the shape ID of this object. + * + * @param multiShapeID the new shape ID of this object + */ + public void setMultiShapeID(final int multiShapeID) { + this.multiShapeID = multiShapeID; + } + + /** + * Return the head part of this multi-part object. + * + * @return the head part + */ + public G getHead() { + return parts.get(0); + } + + /** + * Return the part following a given part. + * + * @param the current part + * + * @return the part following the current part + */ + public G getNext(final G ob) { + assert ob != null; + final int index = parts.indexOf(ob); + assert index != -1; + return index + 1 < parts.size() ? parts.get(index + 1) : null; + } + + /** + * Add a part to this multi-part object. + * + * @param tail the tail part to add + */ + public void addPart(final G tail) { + assert tail != null; + + parts.add(tail); + + final int x = tail.getMultiX(); + if (x < minX) { + minX = x; + } else if (x > maxX) { + maxX = x; + } + + final int y = tail.getMultiY(); + if (y < minY) { + minY = y; + } else if (y > maxY) { + maxY = y; + } + } + +} // class MultiArchData Property changes on: trunk/src/app/net/sf/gridarta/gameobject/MultiArchData.java ___________________________________________________________________ Name: svn:mime-type + text/plain Name: svn:eol-style + LF This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 19:01:02
|
Revision: 718 http://svn.sourceforge.net/gridarta/?rev=718&view=rev Author: akirschbaum Date: 2006-11-26 11:00:58 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify MultiArchData implementation. Modified Paths: -------------- trunk/crossfire/src/cfeditor/MultiArchData.java trunk/crossfire/src/cfeditor/gameobject/GameObject.java trunk/daimonin/src/daieditor/MultiArchData.java trunk/daimonin/src/daieditor/gameobject/GameObject.java Modified: trunk/crossfire/src/cfeditor/MultiArchData.java =================================================================== --- trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 18:42:44 UTC (rev 717) +++ trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 19:00:58 UTC (rev 718) @@ -25,8 +25,8 @@ package cfeditor; -import cfeditor.gameobject.GameObject; import java.util.ArrayList; +import net.sf.gridarta.gameobject.GameObject; /** * Class related to {@link GameObject} to store multipart information. This @@ -38,7 +38,7 @@ * @author <a href="mailto:and...@gm...">Andreas Vogl</a> * @author Andreas Kirschbaum */ -public final class MultiArchData { +public final class MultiArchData<G extends GameObject> { /** * Maximum coordinate of any part; it is never negative. @@ -69,14 +69,14 @@ * All parts belonging to this multi-part object; the first element is the * head part. */ - private final ArrayList<GameObject> parts = new ArrayList<GameObject>(); + private final ArrayList<G> parts = new ArrayList<G>(); /** * Create a new instance. * * @param head the head part of the multi-part object */ - public MultiArchData(final GameObject head) { + public MultiArchData(final G head) { assert head.getMultiX() == 0 && head.getMultiY() == 0; parts.add(head); } @@ -171,7 +171,7 @@ * * @return the head part */ - public GameObject getHead() { + public G getHead() { return parts.get(0); } @@ -182,7 +182,7 @@ * * @return the part following the current part */ - public GameObject getNext(final GameObject ob) { + public G getNext(final G ob) { assert ob != null; final int index = parts.indexOf(ob); assert index != -1; @@ -194,7 +194,7 @@ * * @param tail the tail part to add */ - public void addPart(final GameObject tail) { + public void addPart(final G tail) { assert tail != null; parts.add(tail); Modified: trunk/crossfire/src/cfeditor/gameobject/GameObject.java =================================================================== --- trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 18:42:44 UTC (rev 717) +++ trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 19:00:58 UTC (rev 718) @@ -71,7 +71,7 @@ * Data for multitile-arches. * Stays null for singlesquare-arches. */ - @Nullable private MultiArchData multi = null; + @Nullable private MultiArchData<GameObject> multi = null; /** * Data for scripted events. @@ -417,7 +417,7 @@ */ private void initMultiData() { if (multi == null) { - multi = new MultiArchData(this); + multi = new MultiArchData<GameObject>(this); } } // ----- end multi-arch get/set ----- Modified: trunk/daimonin/src/daieditor/MultiArchData.java =================================================================== --- trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 18:42:44 UTC (rev 717) +++ trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 19:00:58 UTC (rev 718) @@ -25,8 +25,8 @@ package daieditor; -import daieditor.gameobject.GameObject; import java.util.ArrayList; +import net.sf.gridarta.gameobject.GameObject; /** * Class related to {@link GameObject} to store multipart information. This @@ -38,7 +38,7 @@ * @author <a href="mailto:and...@gm...">Andreas Vogl</a> * @author Andreas Kirschbaum */ -public final class MultiArchData { +public final class MultiArchData<G extends GameObject> { /** * Maximum coordinate of any part; it is never negative. @@ -69,14 +69,14 @@ * All parts belonging to this multi-part object; the first element is the * head part. */ - private final ArrayList<GameObject> parts = new ArrayList<GameObject>(); + private final ArrayList<G> parts = new ArrayList<G>(); /** * Create a new instance. * * @param head the head part of the multi-part object */ - public MultiArchData(final GameObject head) { + public MultiArchData(final G head) { assert head.getMultiX() == 0 && head.getMultiY() == 0; parts.add(head); } @@ -171,7 +171,7 @@ * * @return the head part */ - public GameObject getHead() { + public G getHead() { return parts.get(0); } @@ -182,7 +182,7 @@ * * @return the part following the current part */ - public GameObject getNext(final GameObject ob) { + public G getNext(final G ob) { assert ob != null; final int index = parts.indexOf(ob); assert index != -1; @@ -194,7 +194,7 @@ * * @param tail the tail part to add */ - public void addPart(final GameObject tail) { + public void addPart(final G tail) { assert tail != null; parts.add(tail); Modified: trunk/daimonin/src/daieditor/gameobject/GameObject.java =================================================================== --- trunk/daimonin/src/daieditor/gameobject/GameObject.java 2006-11-26 18:42:44 UTC (rev 717) +++ trunk/daimonin/src/daieditor/gameobject/GameObject.java 2006-11-26 19:00:58 UTC (rev 718) @@ -79,7 +79,7 @@ * Data for multitile-arches. * Stays null for singlesquare-arches. */ - @Nullable private MultiArchData multi = null; + @Nullable private MultiArchData<GameObject> multi = null; private int multiPartNr = 0; @@ -353,7 +353,7 @@ */ private void initMultiData() { if (multi == null) { - multi = new MultiArchData(this); + multi = new MultiArchData<GameObject>(this); } } // ----- end multi-arch get/set ----- This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2006-11-26 18:42:44
|
Revision: 717 http://svn.sourceforge.net/gridarta/?rev=717&view=rev Author: christianhujer Date: 2006-11-26 10:42:44 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Removed unused imports. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/MapControl.java trunk/daimonin/src/daieditor/CFJavaEditor.java Modified: trunk/crossfire/src/cfeditor/map/MapControl.java =================================================================== --- trunk/crossfire/src/cfeditor/map/MapControl.java 2006-11-26 18:41:50 UTC (rev 716) +++ trunk/crossfire/src/cfeditor/map/MapControl.java 2006-11-26 18:42:44 UTC (rev 717) @@ -27,7 +27,6 @@ import cfeditor.CMainControl; import cfeditor.CMainStatusbar; import cfeditor.CMapViewBasic; -import cfeditor.GridderException; import cfeditor.IGUIConstants; import cfeditor.MapViewIFrame; import cfeditor.gameobject.GameObject; Modified: trunk/daimonin/src/daieditor/CFJavaEditor.java =================================================================== --- trunk/daimonin/src/daieditor/CFJavaEditor.java 2006-11-26 18:41:50 UTC (rev 716) +++ trunk/daimonin/src/daieditor/CFJavaEditor.java 2006-11-26 18:42:44 UTC (rev 717) @@ -30,7 +30,6 @@ import java.util.Locale; import java.util.MissingResourceException; import java.util.ResourceBundle; -import java.util.logging.Level; import static java.util.prefs.Preferences.userNodeForPackage; import net.sf.japi.swing.ActionFactory; import org.apache.log4j.Logger; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <chr...@us...> - 2006-11-26 18:41:50
|
Revision: 716 http://svn.sourceforge.net/gridarta/?rev=716&view=rev Author: christianhujer Date: 2006-11-26 10:41:50 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Improved format. Modified Paths: -------------- trunk/README Modified: trunk/README =================================================================== --- trunk/README 2006-11-26 17:54:54 UTC (rev 715) +++ trunk/README 2006-11-26 18:41:50 UTC (rev 716) @@ -1,8 +1,8 @@ GRIDARTA README =============== -This file contains some important information about Gridarta. You should read it -first. +This file contains some important information about Gridarta. You should read +it first. TABLE OF CONTENTS @@ -39,9 +39,9 @@ SYSTEM REQUIREMENTS ------------------- Java 5.0 - Previous versions of Java will not work. Gridarta uses Generics, autoboxing, - static imports, foreach loops, assertions, covariant return types and varargs - quite a lot. + Previous versions of Java will not work. Gridarta uses Generics, + autoboxing, static imports, foreach loops, assertions, covariant return + types and varargs quite a lot. Ant 1.6.5 Previous versions of Ant might work but are not tested. @@ -53,8 +53,8 @@ The build file to build the project with Ant. COPYING - Gridarta license conditions. Note: applies to Gridarta only, not third party - libraries. + Gridarta license conditions. Note: applies to Gridarta only, not third + party libraries. CREDITS List of project contributors. See also MAINTAINERS. @@ -80,9 +80,10 @@ Description of how to build and install Gridarta. lib/ - Directory containing third part libraries used to build Gridarta. Please note - that these third party libraries have their own license conditions. The - licenses of the third party libraries are included in the lib/ directory. + Directory containing third part libraries used to build Gridarta. Please + note that these third party libraries have their own license conditions. + The licenses of the third party libraries are included in the lib/ + directory. LICENSE File with license information. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:54:55
|
Revision: 715 http://svn.sourceforge.net/gridarta/?rev=715&view=rev Author: akirschbaum Date: 2006-11-26 09:54:54 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify implementation -- add (unused) attributes to cfeditor; remove unused field. Modified Paths: -------------- trunk/crossfire/src/cfeditor/MultiArchData.java trunk/daimonin/src/daieditor/MultiArchData.java Modified: trunk/crossfire/src/cfeditor/MultiArchData.java =================================================================== --- trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 17:47:43 UTC (rev 714) +++ trunk/crossfire/src/cfeditor/MultiArchData.java 2006-11-26 17:54:54 UTC (rev 715) @@ -61,6 +61,11 @@ private int minY = 0; /** + * The shape ID of this object. + */ + private int multiShapeID; + + /** * All parts belonging to this multi-part object; the first element is the * head part. */ @@ -144,6 +149,24 @@ } /** + * Return the shape ID of this object. + * + * @return the shape ID of this object + */ + public int getMultiShapeID() { + return multiShapeID; + } + + /** + * Set the shape ID of this object. + * + * @param multiShapeID the new shape ID of this object + */ + public void setMultiShapeID(final int multiShapeID) { + this.multiShapeID = multiShapeID; + } + + /** * Return the head part of this multi-part object. * * @return the head part Modified: trunk/daimonin/src/daieditor/MultiArchData.java =================================================================== --- trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 17:47:43 UTC (rev 714) +++ trunk/daimonin/src/daieditor/MultiArchData.java 2006-11-26 17:54:54 UTC (rev 715) @@ -60,10 +60,11 @@ */ private int minY = 0; - private int multiShapeID; // the ID of the multiPositionData + /** + * The shape ID of this object. + */ + private int multiShapeID; - private int multiPartNr; // the part number for this tile - /** * All parts belonging to this multi-part object; the first element is the * head part. @@ -147,10 +148,20 @@ return minY; } + /** + * Return the shape ID of this object. + * + * @return the shape ID of this object + */ public int getMultiShapeID() { return multiShapeID; } + /** + * Set the shape ID of this object. + * + * @param multiShapeID the new shape ID of this object + */ public void setMultiShapeID(final int multiShapeID) { this.multiShapeID = multiShapeID; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:47:43
|
Revision: 714 http://svn.sourceforge.net/gridarta/?rev=714&view=rev Author: akirschbaum Date: 2006-11-26 09:47:43 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify comments. Modified Paths: -------------- trunk/crossfire/src/cfeditor/IGUIConstants.java trunk/daimonin/src/daieditor/IGUIConstants.java Modified: trunk/crossfire/src/cfeditor/IGUIConstants.java =================================================================== --- trunk/crossfire/src/cfeditor/IGUIConstants.java 2006-11-26 17:36:15 UTC (rev 713) +++ trunk/crossfire/src/cfeditor/IGUIConstants.java 2006-11-26 17:47:43 UTC (rev 714) @@ -104,14 +104,17 @@ */ int DOUBLECLICK_MS = 300; - // defaults for new maps - String DEF_MAPFNAME = "<new map>"; // default file name + /** Default file name for new maps. */ + String DEF_MAPFNAME = "<new map>"; - int DEF_MAPSIZE = 10; // default map size (both lenght & width) + /** Default map size (both height and width). */ + int DEF_MAPSIZE = 10; - int DEF_PICKMAP_WIDTH = 7; // default width for pickmaps + /** Default width for pickmaps. */ + int DEF_PICKMAP_WIDTH = 7; - int DEF_PICKMAP_HEIGHT = 12; // default height for pickmaps + /** Default height for pickmaps. */ + int DEF_PICKMAP_HEIGHT = 12; /** The directory that contains the common-use icons. */ String ICON_DIR = "resource" + File.separator + "icons"; Modified: trunk/daimonin/src/daieditor/IGUIConstants.java =================================================================== --- trunk/daimonin/src/daieditor/IGUIConstants.java 2006-11-26 17:36:15 UTC (rev 713) +++ trunk/daimonin/src/daieditor/IGUIConstants.java 2006-11-26 17:47:43 UTC (rev 714) @@ -98,22 +98,25 @@ int[] ALL_TILE_PATHS = {TILE_PATH_NORTH, TILE_PATH_EAST, TILE_PATH_SOUTH, TILE_PATH_WEST, TILE_PATH_NORTHEAST, TILE_PATH_SOUTHEAST, TILE_PATH_SOUTHWEST, TILE_PATH_NORTHWEST}; /** - * The height of rigid area between the two tab-panes on - * the pickmap- and arch-panel. + * The height of rigid area between the two tab-panes on the pickmap- and + * arch-panel. */ int SPACE_PICKARCH_TOP = 10; /** The Border object to be used when creating dialogs. */ Border DIALOG_BORDER = new EmptyBorder(new Insets(4, 4, 4, 4)); - // defaults for new maps - String DEF_MAPFNAME = "<new map>"; // default file name + /** Default file name for new maps. */ + String DEF_MAPFNAME = "<new map>"; - int DEF_MAPSIZE = 24; // default map size (both lenght & width) + /** Default map size (both height and width). */ + int DEF_MAPSIZE = 24; - int DEF_PICKMAP_WIDTH = 20; // default width for pickmaps + /** Default width for pickmaps. */ + int DEF_PICKMAP_WIDTH = 20; - int DEF_PICKMAP_HEIGHT = 20; // default height for pickmaps + /** Default height for pickmaps. */ + int DEF_PICKMAP_HEIGHT = 20; /** The directory that contains the common-use icons.*/ String ICON_DIR = "resource" + File.separator + "icons"; @@ -122,14 +125,12 @@ String SYSTEM_DIR = "resource" + File.separator + "system"; /** The directory that contains all pickmaps. */ - // public static final String PICKMAP_DIR = "resource"+File.separator+"pickmaps"; String PICKMAP_DIR = "dev" + File.separator + "editor" + File.separator + "pickmaps"; /** * The directory that contains all configuration files (careful - if you * change this, check directory creation for file writing). */ - // public static final String CONFIG_DIR = "resource"+File.separator+"conf"; String CONFIG_DIR = "dev" + File.separator + "editor" + File.separator + "conf"; // name of the configuration files: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:36:23
|
Revision: 713 http://svn.sourceforge.net/gridarta/?rev=713&view=rev Author: akirschbaum Date: 2006-11-26 09:36:15 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify logging statements. Modified Paths: -------------- trunk/crossfire/src/cfeditor/gameobject/face/FaceObject.java trunk/daimonin/src/daieditor/gameobject/face/FaceObject.java Modified: trunk/crossfire/src/cfeditor/gameobject/face/FaceObject.java =================================================================== --- trunk/crossfire/src/cfeditor/gameobject/face/FaceObject.java 2006-11-26 17:33:39 UTC (rev 712) +++ trunk/crossfire/src/cfeditor/gameobject/face/FaceObject.java 2006-11-26 17:36:15 UTC (rev 713) @@ -39,6 +39,7 @@ */ public final class FaceObject extends AbstractFaceObject { + /** Logger. */ private static final Logger log = Logger.getLogger(FaceObject.class); //private ImageIcon face; Modified: trunk/daimonin/src/daieditor/gameobject/face/FaceObject.java =================================================================== --- trunk/daimonin/src/daieditor/gameobject/face/FaceObject.java 2006-11-26 17:33:39 UTC (rev 712) +++ trunk/daimonin/src/daieditor/gameobject/face/FaceObject.java 2006-11-26 17:36:15 UTC (rev 713) @@ -23,6 +23,7 @@ import javax.swing.ImageIcon; import net.sf.gridarta.gameobject.face.AbstractFaceObject; +import org.apache.log4j.Logger; /** * A FaceObject stores information and meta information about a face and provides methods for accessing these. @@ -40,6 +41,9 @@ */ public class FaceObject extends AbstractFaceObject { + /** Logger. */ + private static final Logger log = Logger.getLogger(FaceObject.class); + /** The face name. */ private final String faceName; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:33:39
|
Revision: 712 http://svn.sourceforge.net/gridarta/?rev=712&view=rev Author: akirschbaum Date: 2006-11-26 09:33:39 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify logging statements. Modified Paths: -------------- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java trunk/daimonin/src/daieditor/io/CMapWriter.java trunk/daimonin/src/daieditor/map/DefaultMapModel.java Modified: trunk/crossfire/src/cfeditor/map/DefaultMapModel.java =================================================================== --- trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 17:29:48 UTC (rev 711) +++ trunk/crossfire/src/cfeditor/map/DefaultMapModel.java 2006-11-26 17:33:39 UTC (rev 712) @@ -47,6 +47,7 @@ */ public final class DefaultMapModel extends AbstractMapModel<GameObject, MapArchObject> implements MapModel { + /** Logger. */ private static final Logger log = Logger.getLogger(DefaultMapModel.class); /** Flag that indicates if the level has been changed since last save. */ Modified: trunk/daimonin/src/daieditor/io/CMapWriter.java =================================================================== --- trunk/daimonin/src/daieditor/io/CMapWriter.java 2006-11-26 17:29:48 UTC (rev 711) +++ trunk/daimonin/src/daieditor/io/CMapWriter.java 2006-11-26 17:33:39 UTC (rev 712) @@ -34,6 +34,7 @@ import net.sf.gridarta.gameobject.Archetype; import net.sf.gridarta.io.AbstractMapWriter; import net.sf.gridarta.io.MapWriter; +import org.apache.log4j.Logger; import org.jetbrains.annotations.NotNull; /** Modified: trunk/daimonin/src/daieditor/map/DefaultMapModel.java =================================================================== --- trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 17:29:48 UTC (rev 711) +++ trunk/daimonin/src/daieditor/map/DefaultMapModel.java 2006-11-26 17:33:39 UTC (rev 712) @@ -36,6 +36,7 @@ import net.sf.gridarta.map.AbstractMapModel; import net.sf.gridarta.map.MapSquare; import net.sf.japi.swing.ActionFactory; +import org.apache.log4j.Logger; import org.jetbrains.annotations.Nullable; /** @@ -54,6 +55,9 @@ */ public final class DefaultMapModel extends AbstractMapModel<GameObject, MapArchObject> implements MapModel { + /** Logger. */ + private static final Logger log = Logger.getLogger(DefaultMapModel.class); + /** Action Factory. */ private static final ActionFactory ACTION_FACTORY = ActionFactory.getFactory("daieditor"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:29:52
|
Revision: 711 http://svn.sourceforge.net/gridarta/?rev=711&view=rev Author: akirschbaum Date: 2006-11-26 09:29:48 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Unify logging statements. Modified Paths: -------------- trunk/crossfire/src/cfeditor/io/CMapWriter.java trunk/daimonin/src/daieditor/io/CMapWriter.java Modified: trunk/crossfire/src/cfeditor/io/CMapWriter.java =================================================================== --- trunk/crossfire/src/cfeditor/io/CMapWriter.java 2006-11-26 17:27:47 UTC (rev 710) +++ trunk/crossfire/src/cfeditor/io/CMapWriter.java 2006-11-26 17:29:48 UTC (rev 711) @@ -50,6 +50,7 @@ */ public final class CMapWriter extends AbstractMapWriter<GameObject, MapArchObject, MapModel> { + /** Logger. */ private static final Logger log = Logger.getLogger(CMapWriter.class); /** Modified: trunk/daimonin/src/daieditor/io/CMapWriter.java =================================================================== --- trunk/daimonin/src/daieditor/io/CMapWriter.java 2006-11-26 17:27:47 UTC (rev 710) +++ trunk/daimonin/src/daieditor/io/CMapWriter.java 2006-11-26 17:29:48 UTC (rev 711) @@ -45,6 +45,9 @@ @SuppressWarnings({"HardcodedLineSeparator"}) public final class CMapWriter extends AbstractMapWriter<GameObject, MapArchObject, MapModel> { + /** Logger. */ + private static final Logger log = Logger.getLogger(CMapWriter.class); + /** * Formatter to use for writing maps. * @note use '\n' for line endings only. The fileformat requires Unix LF only. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <aki...@us...> - 2006-11-26 17:27:47
|
Revision: 710 http://svn.sourceforge.net/gridarta/?rev=710&view=rev Author: akirschbaum Date: 2006-11-26 09:27:47 -0800 (Sun, 26 Nov 2006) Log Message: ----------- Add comment. Modified Paths: -------------- trunk/crossfire/src/cfeditor/gameobject/GameObject.java Modified: trunk/crossfire/src/cfeditor/gameobject/GameObject.java =================================================================== --- trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 17:25:41 UTC (rev 709) +++ trunk/crossfire/src/cfeditor/gameobject/GameObject.java 2006-11-26 17:27:47 UTC (rev 710) @@ -48,6 +48,7 @@ */ public class GameObject extends net.sf.gridarta.gameobject.GameObject<GameObject> implements Cloneable, Iterable<GameObject> { + /** Logger. */ private static final Logger log = Logger.getLogger(GameObject.class); /** Static reference to the typeList (find syntax errors). */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |