summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2005-01-03 16:27:26 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2005-01-03 16:27:26 +0000
commit1dbd7d35ca9b7c7514fbf3491598835f3ee168cf (patch)
tree1ac4879a4814544e5a485d30e8a0ca7e89f8f575 /src
parent182b5231ba13a0a5865a1b7dcb4731c3009d4c57 (diff)
downloadMana-1dbd7d35ca9b7c7514fbf3491598835f3ee168cf.tar.gz
Mana-1dbd7d35ca9b7c7514fbf3491598835f3ee168cf.tar.bz2
Mana-1dbd7d35ca9b7c7514fbf3491598835f3ee168cf.tar.xz
Mana-1dbd7d35ca9b7c7514fbf3491598835f3ee168cf.zip
Some more comment and indent changes.
Diffstat (limited to 'src')
-rw-r--r--src/being.cpp19
-rw-r--r--src/being.h14
-rw-r--r--src/configuration.cpp2
-rw-r--r--src/graphic/graphic.cpp6
-rw-r--r--src/graphic/graphic.h10
5 files changed, 34 insertions, 17 deletions
diff --git a/src/being.cpp b/src/being.cpp
index 92a1989e..31b87d73 100644
--- a/src/being.cpp
+++ b/src/being.cpp
@@ -18,7 +18,7 @@
* along with The Mana World; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * By ElvenProgrammer aka Eugenio Favalli (umperio@users.sourceforge.net)
+ * $Id$
*/
#include <stdio.h>
@@ -30,16 +30,17 @@ NODE *player_node = NULL;
NODE *head = NULL; // First node of the list
unsigned int b_count = 0; // Number of beings in the list
-/** Create a path node */
PATH_NODE::PATH_NODE(unsigned short x, unsigned short y):
- next(NULL)
+ next(NULL)
{
- this->x = x;
- this->y = y;
+ this->x = x;
+ this->y = y;
}
-/** Return a* path */
-PATH_NODE *calculate_path(unsigned short src_x, unsigned short src_y, unsigned short dest_x, unsigned short dest_y) {
+PATH_NODE *calculate_path(
+ unsigned short src_x, unsigned short src_y,
+ unsigned short dest_x, unsigned short dest_y)
+{
return find_path(1, src_x, src_y, dest_x, dest_y);
}
@@ -61,8 +62,8 @@ NODE::NODE():
hair_style(1), hair_color(1),
weapon(0)
{
- memset(coordinates, 0, 3);
- speech_color = makecol(255,255,255);
+ memset(coordinates, 0, 3);
+ speech_color = makecol(0, 0, 0);
}
/** Returns number of beings in the list */
diff --git a/src/being.h b/src/being.h
index 48e5825b..f45023a1 100644
--- a/src/being.h
+++ b/src/being.h
@@ -18,7 +18,7 @@
* along with The Mana World; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * By ElvenProgrammer aka Eugenio Favalli (umperio@users.sourceforge.net)
+ * $Id$
*/
#ifndef _TMW_BEING_H
@@ -27,11 +27,14 @@
#include "./net/protocol.h"
#define ACTION_NODE 0
-#define PLAYER_NODE 1
-#define NPC_NODE 2
-#define MONSTER_NODE 3
+//#define PLAYER_NODE 1
+//#define NPC_NODE 2
+//#define MONSTER_NODE 3
struct PATH_NODE {
+ /**
+ * Constructor.
+ */
PATH_NODE(unsigned short x, unsigned short y);
unsigned short x, y;
@@ -39,6 +42,9 @@ struct PATH_NODE {
};
struct NODE {
+ /**
+ * Constructor.
+ */
NODE();
unsigned int id;
diff --git a/src/configuration.cpp b/src/configuration.cpp
index 27b47ac7..75d28b8f 100644
--- a/src/configuration.cpp
+++ b/src/configuration.cpp
@@ -105,7 +105,7 @@ bool Configuration::write(std::string filename) {
#ifdef __DEBUG
std::cout << "Configuration::write(" << iter->first.c_str() <<
", \"" << iter->second.stringValue << "\" / " <<
- iter->second.numericValue << ")\n";
+ numericValue << ")\n";
#endif
out.write("\n", 1);
}
diff --git a/src/graphic/graphic.cpp b/src/graphic/graphic.cpp
index 20649d3c..92acd9be 100644
--- a/src/graphic/graphic.cpp
+++ b/src/graphic/graphic.cpp
@@ -17,6 +17,8 @@
* You should have received a copy of the GNU General Public License
* along with The Mana World; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * $Id$
*/
#include "graphic.h"
@@ -412,7 +414,9 @@ void GraphicEngine::refresh() {
buffer, i * 32 - offset_x, j * 32 - offset_y);
}
#ifdef DEBUG
- rect(buffer, i * 32 - offset_x, j * 32 - offset_y, i * 32 - offset_x+32, j * 32 - offset_y+32,makecol(0,0,0));
+ rect(buffer, i * 32 - offset_x, j * 32 - offset_y,
+ i * 32 - offset_x + 32, j * 32 - offset_y + 32,
+ makecol(0,0,0));
#endif
}
}
diff --git a/src/graphic/graphic.h b/src/graphic/graphic.h
index c87cf3ca..0f6710f8 100644
--- a/src/graphic/graphic.h
+++ b/src/graphic/graphic.h
@@ -17,6 +17,8 @@
* You should have received a copy of the GNU General Public License
* along with The Mana World; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * $Id$
*/
#ifndef _GRAPHIC_H
@@ -62,13 +64,17 @@ extern InventoryWindow *inventoryWindow;
extern NpcListDialog *npcListDialog;
extern NpcTextDialog *npcTextDialog;
-// The action listener for the chat field
+/**
+ * The action listener for the chat field.
+ */
class ChatListener : public gcn::ActionListener {
public:
void action(const std::string& eventId);
};
-// The action listener for the buy or sell dialog
+/**
+ * The action listener for the buy or sell dialog.
+ */
class BuySellListener : public gcn::ActionListener {
public:
void action(const std::string& eventId);