summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--COPYING2
-rw-r--r--Makefile.in7
-rw-r--r--src/admin/ladmin.cpp21
-rw-r--r--src/admin/ladmin.hpp25
-rw-r--r--src/admin/main.cpp19
-rw-r--r--src/char/char.cpp22
-rw-r--r--src/char/char.hpp22
-rw-r--r--src/char/int_party.cpp20
-rw-r--r--src/char/int_party.hpp22
-rw-r--r--src/char/int_storage.cpp20
-rw-r--r--src/char/int_storage.hpp22
-rw-r--r--src/char/inter.cpp20
-rw-r--r--src/char/inter.hpp22
-rw-r--r--src/char/main.cpp19
-rw-r--r--src/compat/alg.cpp18
-rw-r--r--src/compat/alg.hpp18
-rw-r--r--src/compat/attr.hpp18
-rw-r--r--src/compat/cast.cpp18
-rw-r--r--src/compat/cast.hpp18
-rw-r--r--src/compat/fun.hpp20
-rw-r--r--src/compat/iter.cpp18
-rw-r--r--src/compat/iter_test.cpp22
-rw-r--r--src/compat/memory.cpp18
-rw-r--r--src/compat/memory.hpp18
-rw-r--r--src/compat/nullpo.cpp20
-rw-r--r--src/compat/nullpo.hpp22
-rw-r--r--src/compat/rawmem.cpp18
-rw-r--r--src/compat/rawmem.hpp21
-rw-r--r--src/conf/version.hpp20
-rw-r--r--src/generic/db.cpp18
-rw-r--r--src/generic/enum.cpp18
-rw-r--r--src/generic/enum.hpp18
-rw-r--r--src/generic/intern-pool.cpp18
-rw-r--r--src/generic/intern-pool.hpp20
-rw-r--r--src/generic/intern-pool_test.cpp20
-rw-r--r--src/generic/matrix.cpp18
-rw-r--r--src/generic/matrix.hpp18
-rw-r--r--src/generic/md5.cpp18
-rw-r--r--src/generic/md5.hpp18
-rw-r--r--src/generic/md5_test.cpp20
-rw-r--r--src/generic/operators.cpp18
-rw-r--r--src/generic/operators.hpp20
-rw-r--r--src/generic/random.cpp18
-rw-r--r--src/generic/random.hpp20
-rw-r--r--src/generic/random.t.hpp20
-rw-r--r--src/generic/random2.hpp20
-rw-r--r--src/io/cxxstdio.cpp18
-rw-r--r--src/io/line_test.cpp20
-rw-r--r--src/io/lock.hpp2
-rw-r--r--src/io/read_test.cpp20
-rw-r--r--src/io/write_test.cpp20
-rw-r--r--src/login/login.cpp22
-rw-r--r--src/login/login.hpp25
-rw-r--r--src/login/main.cpp19
-rw-r--r--src/map/atcommand.cpp20
-rw-r--r--src/map/atcommand.hpp22
-rw-r--r--src/map/battle.cpp21
-rw-r--r--src/map/battle.hpp22
-rw-r--r--src/map/battle.t.hpp22
-rw-r--r--src/map/chrif.cpp20
-rw-r--r--src/map/chrif.hpp22
-rw-r--r--src/map/clif.cpp20
-rw-r--r--src/map/clif.hpp22
-rw-r--r--src/map/clif.t.hpp22
-rw-r--r--src/map/grfio.cpp21
-rw-r--r--src/map/grfio.hpp22
-rw-r--r--src/map/intif.cpp20
-rw-r--r--src/map/intif.hpp22
-rw-r--r--src/map/itemdb.cpp20
-rw-r--r--src/map/itemdb.hpp22
-rw-r--r--src/map/magic-expr-eval.cpp18
-rw-r--r--src/map/magic-expr-eval.hpp21
-rw-r--r--src/map/magic-expr.cpp19
-rw-r--r--src/map/magic-expr.hpp21
-rw-r--r--src/map/magic-interpreter-aux.cpp18
-rw-r--r--src/map/magic-interpreter-aux.hpp21
-rw-r--r--src/map/magic-interpreter-base.cpp19
-rw-r--r--src/map/magic-interpreter-base.hpp25
-rw-r--r--src/map/magic-interpreter.cpp18
-rw-r--r--src/map/magic-interpreter.hpp21
-rw-r--r--src/map/magic-interpreter.t.hpp21
-rw-r--r--src/map/magic-stmt.cpp19
-rw-r--r--src/map/magic-stmt.hpp25
-rw-r--r--src/map/magic-v2.hpp2
-rw-r--r--src/map/magic.cpp20
-rw-r--r--src/map/magic.hpp21
-rw-r--r--src/map/main.cpp21
-rw-r--r--src/map/map.cpp21
-rw-r--r--src/map/map.hpp22
-rw-r--r--src/map/map.t.hpp22
-rw-r--r--src/map/mob.cpp22
-rw-r--r--src/map/mob.hpp22
-rw-r--r--src/map/mob.t.hpp22
-rw-r--r--src/map/npc.cpp20
-rw-r--r--src/map/npc.hpp22
-rw-r--r--src/map/party.cpp21
-rw-r--r--src/map/party.hpp22
-rw-r--r--src/map/path.cpp21
-rw-r--r--src/map/path.hpp22
-rw-r--r--src/map/pc.cpp22
-rw-r--r--src/map/pc.hpp22
-rw-r--r--src/map/pc.t.hpp23
-rw-r--r--src/map/script.cpp22
-rw-r--r--src/map/script.hpp22
-rw-r--r--src/map/skill-pools.cpp19
-rw-r--r--src/map/skill-pools.hpp25
-rw-r--r--src/map/skill.cpp21
-rw-r--r--src/map/skill.hpp22
-rw-r--r--src/map/skill.t.hpp22
-rw-r--r--src/map/storage.hpp23
-rw-r--r--src/map/tmw.cpp19
-rw-r--r--src/map/tmw.hpp21
-rw-r--r--src/map/trade.cpp20
-rw-r--r--src/map/trade.hpp22
-rw-r--r--src/mmo/config_parse.cpp2
-rw-r--r--src/mmo/core.cpp20
-rw-r--r--src/mmo/core.hpp20
-rw-r--r--src/mmo/dumb_ptr.cpp18
-rw-r--r--src/mmo/extract_test.cpp20
-rw-r--r--src/mmo/human_time_diff.cpp18
-rw-r--r--src/mmo/human_time_diff_test.cpp20
-rw-r--r--src/mmo/ip_test.cpp20
-rw-r--r--src/mmo/md5more.cpp20
-rw-r--r--src/mmo/md5more.hpp22
-rw-r--r--src/mmo/mmo.cpp18
-rw-r--r--src/mmo/mmo.hpp21
-rw-r--r--src/mmo/socket.cpp21
-rw-r--r--src/mmo/socket.hpp20
-rw-r--r--src/mmo/timer.cpp20
-rw-r--r--src/mmo/timer.hpp20
-rw-r--r--src/mmo/timer.t.hpp22
-rw-r--r--src/mmo/utils.cpp20
-rw-r--r--src/mmo/utils.hpp20
-rw-r--r--src/mmo/version.cpp20
-rw-r--r--src/mmo/version.hpp22
-rw-r--r--src/monitor/main.cpp27
-rw-r--r--src/poison.hpp22
-rw-r--r--src/range/slice.cpp20
-rw-r--r--src/range/slice_test.cpp20
-rw-r--r--src/sanity.hpp23
-rw-r--r--src/sexpr/lexer_test.cpp20
-rw-r--r--src/sexpr/main.cpp18
-rw-r--r--src/sexpr/parser_test.cpp20
-rw-r--r--src/spell-convert/ast.cpp24
-rw-r--r--src/spell-convert/ast.hpp34
-rw-r--r--src/spell-convert/lexer.lpp19
-rw-r--r--src/spell-convert/main.cpp21
-rw-r--r--src/spell-convert/parser.ypp20
-rw-r--r--src/strings/all.hpp2
-rw-r--r--src/strings/astring.hpp2
-rw-r--r--src/strings/base.hpp4
-rw-r--r--src/strings/base_test.cpp20
-rw-r--r--src/strings/mstring.hpp2
-rw-r--r--src/strings/rstring.hpp2
-rw-r--r--src/strings/sstring.hpp2
-rw-r--r--src/strings/strings2_test.cpp21
-rw-r--r--src/strings/strings_test.cpp20
-rw-r--r--src/strings/tstring.hpp2
-rw-r--r--src/strings/vstring.hpp2
-rw-r--r--src/strings/xstring.hpp2
-rw-r--r--src/strings/zstring.hpp2
-rw-r--r--src/tests/test.cpp20
-rw-r--r--src/warnings.hpp23
163 files changed, 3049 insertions, 39 deletions
diff --git a/COPYING b/COPYING
index 95e03e3..edf98ab 100644
--- a/COPYING
+++ b/COPYING
@@ -13,4 +13,4 @@ Originally, tmwAthena was forked from eAthena in 2004.
We don't have a list of copyright holders from this time.
Until 2012, tmwAthena was GPL2+ and did not put per-file copyright notices.
-A list of copyright holders during this time is in the git history.
+A list of specific copyright holders during this time is in the git history.
diff --git a/Makefile.in b/Makefile.in
index 797d3b8..962eaaf 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -450,21 +450,28 @@ format-ypp: $(patsubst src/%,obj/%.formatted,${PARSERS})
obj/%.cpp.formatted: src/%.cpp tools/indenter
$(MKDIR_FIRST)
apply-filter 'indenter -cpp' $<
+ fgrep -q Copyright $<
+ fgrep -q ../poison.hpp $<
touch $@
obj/%.hpp.formatted: src/%.hpp tools/indenter
$(MKDIR_FIRST)
apply-filter 'indenter -cpp' $<
+ fgrep -q Copyright $<
+ fgrep -q ../sanity.hpp $<
touch $@
obj/%.tcc.formatted: src/%.tcc tools/indenter
$(MKDIR_FIRST)
apply-filter 'indenter -cpp' $<
+ fgrep -q Copyright $<
touch $@
obj/%.lpp.formatted: src/%.lpp tools/indenter
$(MKDIR_FIRST)
apply-filter 'indenter -lpp' $<
+ fgrep -q Copyright $<
touch $@
obj/%.ypp.formatted: src/%.ypp tools/indenter
$(MKDIR_FIRST)
apply-filter 'indenter -ypp' $<
+ fgrep -q Copyright $<
touch $@
.PHONY: format format-cpp format-hpp format-lpp format-ypp
diff --git a/src/admin/ladmin.cpp b/src/admin/ladmin.cpp
index b56fd65..5d772e3 100644
--- a/src/admin/ladmin.cpp
+++ b/src/admin/ladmin.cpp
@@ -1,4 +1,25 @@
#include <arpa/inet.h>
+// ladmin.cpp - Local administration tool.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 MadCamel
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <netdb.h>
#include <unistd.h>
diff --git a/src/admin/ladmin.hpp b/src/admin/ladmin.hpp
index 8c7e195..034f644 100644
--- a/src/admin/ladmin.hpp
+++ b/src/admin/ladmin.hpp
@@ -1 +1,24 @@
-// dummy header to make Make dependencies work
+#ifndef TMWA_ADMIN_LADMIN_HPP
+#define TMWA_ADMIN_LADMIN_HPP
+// ladmin.hpp - dummy header to make Make dependencies work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
+
+#endif // TMWA_ADMIN_LADMIN_HPP
diff --git a/src/admin/main.cpp b/src/admin/main.cpp
index bed1539..c6f075e 100644
--- a/src/admin/main.cpp
+++ b/src/admin/main.cpp
@@ -1,4 +1,21 @@
-// dummy file to make Make dependencies work
#include "ladmin.hpp"
+// admin/main.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/char/char.cpp b/src/char/char.cpp
index 91ff2e2..d7849af 100644
--- a/src/char/char.cpp
+++ b/src/char/char.cpp
@@ -1,4 +1,26 @@
#include "char.hpp"
+// char.cpp - Character server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013-2014 MadCamel
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include <arpa/inet.h>
#include <sys/socket.h>
diff --git a/src/char/char.hpp b/src/char/char.hpp
index f765b39..4c11073 100644
--- a/src/char/char.hpp
+++ b/src/char/char.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_CHAR_CHAR_HPP
#define TMWA_CHAR_CHAR_HPP
+// char.hpp - Character server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/char/int_party.cpp b/src/char/int_party.cpp
index 864972d..c9965dc 100644
--- a/src/char/int_party.cpp
+++ b/src/char/int_party.cpp
@@ -1,4 +1,24 @@
#include "int_party.hpp"
+// int_party.cpp - Internal party handling.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstdlib>
#include <cstring>
diff --git a/src/char/int_party.hpp b/src/char/int_party.hpp
index 9fe68fa..1608c37 100644
--- a/src/char/int_party.hpp
+++ b/src/char/int_party.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_CHAR_INT_PARTY_HPP
#define TMWA_CHAR_INT_PARTY_HPP
+// int_party.hpp - Internal party handling.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/char/int_storage.cpp b/src/char/int_storage.cpp
index d2782b4..c7c1343 100644
--- a/src/char/int_storage.cpp
+++ b/src/char/int_storage.cpp
@@ -1,4 +1,24 @@
#include "int_storage.hpp"
+// int_storage.cpp - Internal storage handling.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstdlib>
#include <cstring>
diff --git a/src/char/int_storage.hpp b/src/char/int_storage.hpp
index c6cd084..7f6deb5 100644
--- a/src/char/int_storage.hpp
+++ b/src/char/int_storage.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_CHAR_INT_STORAGE_HPP
#define TMWA_CHAR_INT_STORAGE_HPP
+// int_storage.hpp - Internal storage handling.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/char/inter.cpp b/src/char/inter.cpp
index 0c41c86..204a0e2 100644
--- a/src/char/inter.cpp
+++ b/src/char/inter.cpp
@@ -1,4 +1,24 @@
#include "inter.hpp"
+// inter.cpp - Internal server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cstdlib>
diff --git a/src/char/inter.hpp b/src/char/inter.hpp
index 06c99f6..7d1a38b 100644
--- a/src/char/inter.hpp
+++ b/src/char/inter.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_CHAR_INTER_HPP
#define TMWA_CHAR_INTER_HPP
+// inter.hpp - Internal server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/char/main.cpp b/src/char/main.cpp
index de51ae3..6814574 100644
--- a/src/char/main.cpp
+++ b/src/char/main.cpp
@@ -1,4 +1,21 @@
-// dummy file to make Make dependencies work
#include "char.hpp"
+// char/main.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/alg.cpp b/src/compat/alg.cpp
index 7800e79..8cfd00a 100644
--- a/src/compat/alg.cpp
+++ b/src/compat/alg.cpp
@@ -1,3 +1,21 @@
#include "alg.hpp"
+// alg.cpp - Silly math stuff.
+//
+// Copyright © 2012 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/alg.hpp b/src/compat/alg.hpp
index 250c161..adf3f3f 100644
--- a/src/compat/alg.hpp
+++ b/src/compat/alg.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_COMPAT_ALG_HPP
#define TMWA_COMPAT_ALG_HPP
+// alg.hpp - Silly math stuff.
+//
+// Copyright © 2012 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/compat/attr.hpp b/src/compat/attr.hpp
index ca9a7a2..ea7ba86 100644
--- a/src/compat/attr.hpp
+++ b/src/compat/attr.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_COMPAT_ATTR_HPP
#define TMWA_COMPAT_ATTR_HPP
+// attr.hpp - Attributes.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/compat/cast.cpp b/src/compat/cast.cpp
index 015fd27..43c0b53 100644
--- a/src/compat/cast.cpp
+++ b/src/compat/cast.cpp
@@ -1,3 +1,21 @@
#include "cast.hpp"
+// cast.cpp - Change the type of a variable.
+//
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/cast.hpp b/src/compat/cast.hpp
index c1b9bab..8db486f 100644
--- a/src/compat/cast.hpp
+++ b/src/compat/cast.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_COMPAT_CAST_HPP
#define TMWA_COMPAT_CAST_HPP
+// cast.hpp - Change the type of a variable.
+//
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/compat/fun.hpp b/src/compat/fun.hpp
index 536a113..005f2c5 100644
--- a/src/compat/fun.hpp
+++ b/src/compat/fun.hpp
@@ -1,10 +1,30 @@
#ifndef TMWA_COMPAT_FUN_HPP
#define TMWA_COMPAT_FUN_HPP
+// fun.hpp - Functional placeholders.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
# include <functional>
+# include "../sanity.hpp"
+
namespace ph = std::placeholders;
diff --git a/src/compat/iter.cpp b/src/compat/iter.cpp
index 2b1fb0c..f0ab0af 100644
--- a/src/compat/iter.cpp
+++ b/src/compat/iter.cpp
@@ -1,3 +1,21 @@
#include "iter.hpp"
+// iter.cpp - tools for dealing with iterators
+//
+// Copyright © 2012-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/iter_test.cpp b/src/compat/iter_test.cpp
index 647ebf9..a07cb0f 100644
--- a/src/compat/iter_test.cpp
+++ b/src/compat/iter_test.cpp
@@ -1,10 +1,30 @@
#include "iter.hpp"
+// iter_test.cpp - Testsuite for tools for dealing with iterators
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/xstring.hpp"
-TEST(iterpair, string)
+#include "../poison.hpp"
+
+TEST(iterpair, strings)
{
IteratorPair<ValueIterator<char>> pair = value_range('0', ':');
const char *str = "0123456789";
diff --git a/src/compat/memory.cpp b/src/compat/memory.cpp
index 6a5f526..5db23b2 100644
--- a/src/compat/memory.cpp
+++ b/src/compat/memory.cpp
@@ -1,3 +1,21 @@
#include "memory.hpp"
+// memory.cpp - I forget ...
+//
+// Copyright © 2013-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/memory.hpp b/src/compat/memory.hpp
index 2839640..2c0f742 100644
--- a/src/compat/memory.hpp
+++ b/src/compat/memory.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_COMPAT_MEMORY_HPP
#define TMWA_COMPAT_MEMORY_HPP
+// memory.hpp - I forget ...
+//
+// Copyright © 2013-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/compat/nullpo.cpp b/src/compat/nullpo.cpp
index 423ed8c..a31cc34 100644
--- a/src/compat/nullpo.cpp
+++ b/src/compat/nullpo.cpp
@@ -1,4 +1,24 @@
#include "nullpo.hpp"
+// nullpo.cpp - Non-fatal pointer assertions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstdio>
diff --git a/src/compat/nullpo.hpp b/src/compat/nullpo.hpp
index 6eca4b6..75f8110 100644
--- a/src/compat/nullpo.hpp
+++ b/src/compat/nullpo.hpp
@@ -1,6 +1,26 @@
-/// return wrappers for unexpected NULL pointers
#ifndef TMWA_COMPAT_NULLPO_HPP
#define TMWA_COMPAT_NULLPO_HPP
+// nullpo.hpp - Non-fatal pointer assertions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
/// Uncomment this to live dangerously
/// (really exist to detect mostly-unused variables)
//# define BUG_FREE
diff --git a/src/compat/rawmem.cpp b/src/compat/rawmem.cpp
index 9e353e8..74fdc0b 100644
--- a/src/compat/rawmem.cpp
+++ b/src/compat/rawmem.cpp
@@ -1,3 +1,21 @@
#include "rawmem.hpp"
+// rawmem.cpp - Ignore poisoning and really frob this memory unsafely.
+//
+// Copyright © 2013-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/compat/rawmem.hpp b/src/compat/rawmem.hpp
index ac08964..bbe917c 100644
--- a/src/compat/rawmem.hpp
+++ b/src/compat/rawmem.hpp
@@ -1,10 +1,30 @@
#ifndef TMWA_COMPAT_RAWMEM_HPP
#define TMWA_COMPAT_RAWMEM_HPP
+// rawmem.hpp - Ignore poisoning and really frob this memory unsafely.
+//
+// Copyright © 2013-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include <cstddef>
# include <cstdint>
# include <cstring>
+# include "../sanity.hpp"
+
inline
void really_memcpy(uint8_t *dest, const uint8_t *src, size_t n)
{
@@ -27,4 +47,5 @@ void really_memset0(uint8_t *dest, size_t n)
{
memset(dest, '\0', n);
}
+
#endif // TMWA_COMPAT_RAWMEM_HPP
diff --git a/src/conf/version.hpp b/src/conf/version.hpp
index 8dd31ed..ea394e6 100644
--- a/src/conf/version.hpp
+++ b/src/conf/version.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_CONF_VERSION_HPP
#define TMWA_CONF_VERSION_HPP
+// conf/version.hpp - Import configuration variables related to version.
+//
+// Copyright © 2013-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "conf-raw/str-VERSION_FULL.h"
# include "conf-raw/str-VERSION_HASH.h"
diff --git a/src/generic/db.cpp b/src/generic/db.cpp
index cc58ad8..b953ff0 100644
--- a/src/generic/db.cpp
+++ b/src/generic/db.cpp
@@ -1,3 +1,21 @@
#include "db.hpp"
+// db.cpp - convenience wrappers over std::map<K, V>
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/enum.cpp b/src/generic/enum.cpp
index c5ab250..8c54aba 100644
--- a/src/generic/enum.cpp
+++ b/src/generic/enum.cpp
@@ -1,3 +1,21 @@
#include "enum.hpp"
+// enum.cpp - Safe building blocks for enumerated types.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/enum.hpp b/src/generic/enum.hpp
index 29e5c36..8b3509f 100644
--- a/src/generic/enum.hpp
+++ b/src/generic/enum.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_GENERIC_ENUM_HPP
#define TMWA_GENERIC_ENUM_HPP
+// enum.hpp - Safe building blocks for enumerated types.
+//
+// Copyright © 2012-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/generic/intern-pool.cpp b/src/generic/intern-pool.cpp
index 33649f2..f6df5a6 100644
--- a/src/generic/intern-pool.cpp
+++ b/src/generic/intern-pool.cpp
@@ -1,3 +1,21 @@
#include "intern-pool.hpp"
+// intern-pool.cpp - Cached integer/string lookups.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/intern-pool.hpp b/src/generic/intern-pool.hpp
index f9c1e8f..0ffddd2 100644
--- a/src/generic/intern-pool.hpp
+++ b/src/generic/intern-pool.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_GENERIC_INTERN_POOL_HPP
#define TMWA_GENERIC_INTERN_POOL_HPP
+// intern-pool.hpp - Cached integer/string lookups.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cassert>
diff --git a/src/generic/intern-pool_test.cpp b/src/generic/intern-pool_test.cpp
index bf17b67..b72ab04 100644
--- a/src/generic/intern-pool_test.cpp
+++ b/src/generic/intern-pool_test.cpp
@@ -1,9 +1,29 @@
#include "intern-pool.hpp"
+// intern-pool.hpp - Testsuite for cached integer/string lookups.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/base.hpp"
+#include "../poison.hpp"
+
TEST(InternPool, whydoesthisalwaysneedasecondname)
{
InternPool p;
diff --git a/src/generic/matrix.cpp b/src/generic/matrix.cpp
index 9ee049e..e1e1f5e 100644
--- a/src/generic/matrix.cpp
+++ b/src/generic/matrix.cpp
@@ -1,3 +1,21 @@
#include "matrix.hpp"
+// matrix.cpp - A 2D array.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/matrix.hpp b/src/generic/matrix.hpp
index b337249..40ff9a8 100644
--- a/src/generic/matrix.hpp
+++ b/src/generic/matrix.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_GENERIC_MATRIX_HPP
#define TMWA_GENERIC_MATRIX_HPP
+// matrix.hpp - A 2D array.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/generic/md5.cpp b/src/generic/md5.cpp
index a626dc5..b49d36f 100644
--- a/src/generic/md5.cpp
+++ b/src/generic/md5.cpp
@@ -1,4 +1,22 @@
#include "md5.hpp"
+// md5.cpp - Fundamental MD5 operations.
+//
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstring>
diff --git a/src/generic/md5.hpp b/src/generic/md5.hpp
index ba1212a..8b1c6ad 100644
--- a/src/generic/md5.hpp
+++ b/src/generic/md5.hpp
@@ -1,5 +1,23 @@
#ifndef TMWA_GENERIC_MD5CALC_HPP
#define TMWA_GENERIC_MD5CALC_HPP
+// md5.hpp - Fundamental MD5 operations.
+//
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/generic/md5_test.cpp b/src/generic/md5_test.cpp
index 7086c8c..f6a2324 100644
--- a/src/generic/md5_test.cpp
+++ b/src/generic/md5_test.cpp
@@ -1,10 +1,30 @@
#include "md5.hpp"
+// md5_test.cpp - Testsuite for fundamental MD5 operations.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/xstring.hpp"
#include "../strings/vstring.hpp"
+#include "../poison.hpp"
+
// This should be made part of the main API,
// but is not yet to keep the diff small.
// Edit: hack to fix the new strict comparison.
diff --git a/src/generic/operators.cpp b/src/generic/operators.cpp
index 877aec6..8d79e1b 100644
--- a/src/generic/operators.cpp
+++ b/src/generic/operators.cpp
@@ -1,3 +1,21 @@
#include "operators.hpp"
+// operators.cpp - ADL helper for value wrappers.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/operators.hpp b/src/generic/operators.hpp
index 3d3dccd..2a71c46 100644
--- a/src/generic/operators.hpp
+++ b/src/generic/operators.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_GENERIC_OPERATORS_HPP
#define TMWA_GENERIC_OPERATORS_HPP
+// operators.hpp - ADL helper for value wrappers.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
namespace _operators
{
diff --git a/src/generic/random.cpp b/src/generic/random.cpp
index 273dcec..8a06571 100644
--- a/src/generic/random.cpp
+++ b/src/generic/random.cpp
@@ -1,4 +1,22 @@
#include "random2.hpp"
+// random.cpp - Random number generation.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/generic/random.hpp b/src/generic/random.hpp
index 5d7a7af..45b5371 100644
--- a/src/generic/random.hpp
+++ b/src/generic/random.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_GENERIC_RANDOM_HPP
#define TMWA_GENERIC_RANDOM_HPP
+// random.hpp - Random number generation.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "random.t.hpp"
diff --git a/src/generic/random.t.hpp b/src/generic/random.t.hpp
index feea2b0..d26bf56 100644
--- a/src/generic/random.t.hpp
+++ b/src/generic/random.t.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_GENERIC_RANDOM_T_HPP
#define TMWA_GENERIC_RANDOM_T_HPP
+// random.t.hpp - Random number generation.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
namespace random_
{
diff --git a/src/generic/random2.hpp b/src/generic/random2.hpp
index 4bdc72e..40fcbcf 100644
--- a/src/generic/random2.hpp
+++ b/src/generic/random2.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_GENERIC_RANDOM2_HPP
#define TMWA_GENERIC_RANDOM2_HPP
+// random2.hpp - Random number generation.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "random.hpp"
diff --git a/src/io/cxxstdio.cpp b/src/io/cxxstdio.cpp
index aa603e4..fbfdd46 100644
--- a/src/io/cxxstdio.cpp
+++ b/src/io/cxxstdio.cpp
@@ -1,3 +1,21 @@
#include "cxxstdio.hpp"
+// cxxstdio.cpp - pass C++ types through scanf/printf
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/io/line_test.cpp b/src/io/line_test.cpp
index df8a0d3..feee1fb 100644
--- a/src/io/line_test.cpp
+++ b/src/io/line_test.cpp
@@ -1,9 +1,29 @@
#include "line.hpp"
+// io/line_test.cpp - Testsuite for input from files, line-by-line
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/zstring.hpp"
+#include "../poison.hpp"
+
static
io::FD string_pipe(ZString sz)
{
diff --git a/src/io/lock.hpp b/src/io/lock.hpp
index b5052cf..b879da5 100644
--- a/src/io/lock.hpp
+++ b/src/io/lock.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "write.hpp"
# include "../strings/rstring.hpp"
diff --git a/src/io/read_test.cpp b/src/io/read_test.cpp
index 5d287dd..87f95ba 100644
--- a/src/io/read_test.cpp
+++ b/src/io/read_test.cpp
@@ -1,9 +1,29 @@
#include "read.hpp"
+// io/read_test.cpp - Testsuite for input from files
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/zstring.hpp"
+#include "../poison.hpp"
+
static
io::FD string_pipe(ZString sz)
{
diff --git a/src/io/write_test.cpp b/src/io/write_test.cpp
index f703850..ae8eccd 100644
--- a/src/io/write_test.cpp
+++ b/src/io/write_test.cpp
@@ -1,4 +1,22 @@
#include "write.hpp"
+// io/write_test.cpp - Testsuite for output to files
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
@@ -9,6 +27,8 @@
#include "../strings/mstring.hpp"
#include "../strings/xstring.hpp"
+#include "../poison.hpp"
+
static
io::FD pipew(io::FD& rfd)
{
diff --git a/src/login/login.cpp b/src/login/login.cpp
index 0a4ac99..f784c6a 100644
--- a/src/login/login.cpp
+++ b/src/login/login.cpp
@@ -1,3 +1,25 @@
+// login.cpp - Core of the login server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2014 MadCamel
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include <arpa/inet.h>
#include <sys/types.h>
#include <sys/wait.h>
diff --git a/src/login/login.hpp b/src/login/login.hpp
index 8c7e195..3458dab 100644
--- a/src/login/login.hpp
+++ b/src/login/login.hpp
@@ -1 +1,24 @@
-// dummy header to make Make dependencies work
+#ifndef TMWA_LOGIN_LOGIN_HPP
+#define TMWA_LOGIN_LOGIN_HPP
+// login.hpp - dummy header to make Make dependencies work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
+
+#endif // TMWA_LOGIN_LOGIN_HPP
diff --git a/src/login/main.cpp b/src/login/main.cpp
index 470bcd1..5d51212 100644
--- a/src/login/main.cpp
+++ b/src/login/main.cpp
@@ -1,4 +1,21 @@
-// dummy file to make Make dependencies work
#include "login.hpp"
+// login/main.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/map/atcommand.cpp b/src/map/atcommand.cpp
index 4b07a52..240df8b 100644
--- a/src/map/atcommand.cpp
+++ b/src/map/atcommand.cpp
@@ -1,4 +1,24 @@
#include "atcommand.hpp"
+// atcommand.cpp - GM commands.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cmath>
#include <cstring>
diff --git a/src/map/atcommand.hpp b/src/map/atcommand.hpp
index 45759a6..95e3814 100644
--- a/src/map/atcommand.hpp
+++ b/src/map/atcommand.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_ATCOMMAND_HPP
#define TMWA_MAP_ATCOMMAND_HPP
+// atcommand.hpp - GM commands.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/map/battle.cpp b/src/map/battle.cpp
index 75ae4f0..8e4d435 100644
--- a/src/map/battle.cpp
+++ b/src/map/battle.cpp
@@ -1,4 +1,25 @@
#include "battle.hpp"
+// battle.cpp - Not so scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2012 Vincent Petithory
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstring>
diff --git a/src/map/battle.hpp b/src/map/battle.hpp
index 5c62785..b8060a9 100644
--- a/src/map/battle.hpp
+++ b/src/map/battle.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_BATTLE_HPP
#define TMWA_MAP_BATTLE_HPP
+// battle.hpp - Not so scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "battle.t.hpp"
diff --git a/src/map/battle.t.hpp b/src/map/battle.t.hpp
index 76ff571..9685ae7 100644
--- a/src/map/battle.t.hpp
+++ b/src/map/battle.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_BATTLE_T_HPP
#define TMWA_MAP_BATTLE_T_HPP
+// battle.t.hpp - Not so scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../generic/enum.hpp"
diff --git a/src/map/chrif.cpp b/src/map/chrif.cpp
index ea74ca4..9a70d63 100644
--- a/src/map/chrif.cpp
+++ b/src/map/chrif.cpp
@@ -1,4 +1,24 @@
#include "chrif.hpp"
+// chrif.cpp - Network interface to the character server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <arpa/inet.h>
diff --git a/src/map/chrif.hpp b/src/map/chrif.hpp
index 2dfda43..5e8263d 100644
--- a/src/map/chrif.hpp
+++ b/src/map/chrif.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_CHRIF_HPP
#define TMWA_MAP_CHRIF_HPP
+// chrif.hpp - Network interface to the character server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/map/clif.cpp b/src/map/clif.cpp
index ecf9ec6..a7dcb52 100644
--- a/src/map/clif.cpp
+++ b/src/map/clif.cpp
@@ -1,4 +1,24 @@
#include "clif.hpp"
+// clif.cpp - Network interface to the client.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <arpa/inet.h>
diff --git a/src/map/clif.hpp b/src/map/clif.hpp
index 571f68e..1fdd67c 100644
--- a/src/map/clif.hpp
+++ b/src/map/clif.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_CLIF_HPP
#define TMWA_MAP_CLIF_HPP
+// clif.hpp - Network interface to the client.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "clif.t.hpp"
diff --git a/src/map/clif.t.hpp b/src/map/clif.t.hpp
index a52b33a..5cb06ad 100644
--- a/src/map/clif.t.hpp
+++ b/src/map/clif.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_CLIF_T_HPP
#define TMWA_MAP_CLIF_T_HPP
+// clif.t.hpp - Network interface to the client.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/map/grfio.cpp b/src/map/grfio.cpp
index bf55cf7..c3d1e40 100644
--- a/src/map/grfio.cpp
+++ b/src/map/grfio.cpp
@@ -1,5 +1,24 @@
-// Reads .gat files by name-mapping .wlk files
#include "grfio.hpp"
+// grfio.cpp - Don't read GRF files, just name-map .wlk files.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <sys/stat.h>
diff --git a/src/map/grfio.hpp b/src/map/grfio.hpp
index e0758fe..9b6d5e2 100644
--- a/src/map/grfio.hpp
+++ b/src/map/grfio.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_GRFIO_HPP
#define TMWA_MAP_GRFIO_HPP
+// grfio.hpp - Don't read GRF files, just name-map .wlk files.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/map/intif.cpp b/src/map/intif.cpp
index b2b95fe..2cae2ad 100644
--- a/src/map/intif.cpp
+++ b/src/map/intif.cpp
@@ -1,4 +1,24 @@
#include "intif.hpp"
+// intif.cpp - Network interface to the internal server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstdlib>
#include <cstring>
diff --git a/src/map/intif.hpp b/src/map/intif.hpp
index 7028ed9..80de797 100644
--- a/src/map/intif.hpp
+++ b/src/map/intif.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_INTIF_HPP
#define TMWA_MAP_INTIF_HPP
+// intif.hpp - Network interface to the internal server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/map/itemdb.cpp b/src/map/itemdb.cpp
index 52a14aa..4ebb52c 100644
--- a/src/map/itemdb.cpp
+++ b/src/map/itemdb.cpp
@@ -1,4 +1,24 @@
#include "itemdb.hpp"
+// itemdb.cpp - Item definitions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstdlib>
#include <cstring>
diff --git a/src/map/itemdb.hpp b/src/map/itemdb.hpp
index ab06189..16802da 100644
--- a/src/map/itemdb.hpp
+++ b/src/map/itemdb.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_ITEMDB_HPP
#define TMWA_MAP_ITEMDB_HPP
+// itemdb.hpp - Item definitions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../mmo/mmo.hpp"
diff --git a/src/map/magic-expr-eval.cpp b/src/map/magic-expr-eval.cpp
index 57f9c32..36b69f5 100644
--- a/src/map/magic-expr-eval.cpp
+++ b/src/map/magic-expr-eval.cpp
@@ -1,3 +1,21 @@
#include "magic-expr-eval.hpp"
+// magic-expr-eval.cpp - Utilities for evaluating magic.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/map/magic-expr-eval.hpp b/src/map/magic-expr-eval.hpp
index 4de2f81..9b9f5f8 100644
--- a/src/map/magic-expr-eval.hpp
+++ b/src/map/magic-expr-eval.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_EXPR_EVAL_HPP
#define TMWA_MAP_MAGIC_EXPR_EVAL_HPP
+// magic-expr-eval.hpp - Utilities for evaluating magic.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../range/slice.hpp"
diff --git a/src/map/magic-expr.cpp b/src/map/magic-expr.cpp
index d05f713..42ff3a7 100644
--- a/src/map/magic-expr.cpp
+++ b/src/map/magic-expr.cpp
@@ -1,6 +1,25 @@
#include "magic-expr-eval.hpp"
#include "magic-expr.hpp"
#include "magic-interpreter-aux.hpp"
+// magic-expr.cpp - Pure functions for the old magic backend.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cmath>
diff --git a/src/map/magic-expr.hpp b/src/map/magic-expr.hpp
index b2b0dd2..58f6596 100644
--- a/src/map/magic-expr.hpp
+++ b/src/map/magic-expr.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_EXPR_HPP
#define TMWA_MAP_MAGIC_EXPR_HPP
+// magic-expr.hpp - Pure functions for the old magic backend.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "magic-interpreter.hpp"
diff --git a/src/map/magic-interpreter-aux.cpp b/src/map/magic-interpreter-aux.cpp
index e293e78..10a376b 100644
--- a/src/map/magic-interpreter-aux.cpp
+++ b/src/map/magic-interpreter-aux.cpp
@@ -1,3 +1,21 @@
#include "magic-interpreter-aux.hpp"
+// magic-interpreter-aux.cpp - Edge of the magic system.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/map/magic-interpreter-aux.hpp b/src/map/magic-interpreter-aux.hpp
index 6f5ad79..1369b38 100644
--- a/src/map/magic-interpreter-aux.hpp
+++ b/src/map/magic-interpreter-aux.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_INTERPRETER_AUX_HPP
#define TMWA_MAP_MAGIC_INTERPRETER_AUX_HPP
+// magic-interpreter-aux.hpp - Edge of the magic system.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "magic-interpreter.t.hpp"
diff --git a/src/map/magic-interpreter-base.cpp b/src/map/magic-interpreter-base.cpp
index 40f186b..d86f595 100644
--- a/src/map/magic-interpreter-base.cpp
+++ b/src/map/magic-interpreter-base.cpp
@@ -1,4 +1,23 @@
#include "magic-interpreter-base.hpp"
+// magic-interpreter-base.cpp - Core of the old magic system.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "magic-interpreter-aux.hpp"
#include "magic-interpreter.hpp"
diff --git a/src/map/magic-interpreter-base.hpp b/src/map/magic-interpreter-base.hpp
index 8c7e195..9b1e08a 100644
--- a/src/map/magic-interpreter-base.hpp
+++ b/src/map/magic-interpreter-base.hpp
@@ -1 +1,24 @@
-// dummy header to make Make dependencies work
+#ifndef TMWA_MAP_MAGIC_INTERPRETER_BASE_HPP
+#define TMWA_MAP_MAGIC_INTERPRETER_BASE_HPP
+// magic-interpreter-base.hpp - dummy header to make Make dependencies work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
+
+#endif // TMWA_MAP_MAGIC_INTERPRETER_BASE_HPP
diff --git a/src/map/magic-interpreter.cpp b/src/map/magic-interpreter.cpp
index 526d549..4680971 100644
--- a/src/map/magic-interpreter.cpp
+++ b/src/map/magic-interpreter.cpp
@@ -1,3 +1,21 @@
#include "magic-interpreter.hpp"
+// magic-interpreter.hpp - Old magic.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/map/magic-interpreter.hpp b/src/map/magic-interpreter.hpp
index c6abb81..7d529ee 100644
--- a/src/map/magic-interpreter.hpp
+++ b/src/map/magic-interpreter.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_INTERPRETER_HPP
#define TMWA_MAP_MAGIC_INTERPRETER_HPP
+// magic-interpreter.hpp - Old magic.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "magic-interpreter.t.hpp"
diff --git a/src/map/magic-interpreter.t.hpp b/src/map/magic-interpreter.t.hpp
index e8d7e06..9310a7b 100644
--- a/src/map/magic-interpreter.t.hpp
+++ b/src/map/magic-interpreter.t.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_INTERPRETER_T_HPP
#define TMWA_MAP_MAGIC_INTERPRETER_T_HPP
+// magic-interpreter.t.hpp - Old magic.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../generic/enum.hpp"
diff --git a/src/map/magic-stmt.cpp b/src/map/magic-stmt.cpp
index 081651c..ba99409 100644
--- a/src/map/magic-stmt.cpp
+++ b/src/map/magic-stmt.cpp
@@ -1,4 +1,23 @@
#include "magic-stmt.hpp"
+// magic-stmt.cpp - Imperative commands for the magic backend.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
diff --git a/src/map/magic-stmt.hpp b/src/map/magic-stmt.hpp
index 8c7e195..838854f 100644
--- a/src/map/magic-stmt.hpp
+++ b/src/map/magic-stmt.hpp
@@ -1 +1,24 @@
-// dummy header to make Make dependencies work
+#ifndef TMWA_MAP_MAGIC_STMT_HPP
+#define TMWA_MAP_MAGIC_STMT_HPP
+// magic-stmt.hpp - dummy header to make Make dependencies work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
+
+#endif // TMWA_MAP_MAGIC_STMT_HPP
diff --git a/src/map/magic-v2.hpp b/src/map/magic-v2.hpp
index d9140dc..888e183 100644
--- a/src/map/magic-v2.hpp
+++ b/src/map/magic-v2.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "../strings/zstring.hpp"
bool magic_init0();
diff --git a/src/map/magic.cpp b/src/map/magic.cpp
index 56705fe..9896b26 100644
--- a/src/map/magic.cpp
+++ b/src/map/magic.cpp
@@ -1,3 +1,23 @@
+// magic.cpp - Entry to the magic system.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include <cstring>
#include "../strings/xstring.hpp"
diff --git a/src/map/magic.hpp b/src/map/magic.hpp
index 1562469..a5a966c 100644
--- a/src/map/magic.hpp
+++ b/src/map/magic.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_MAGIC_HPP
#define TMWA_MAP_MAGIC_HPP
+// magic.hpp - Entry to the magic system.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/map/main.cpp b/src/map/main.cpp
index de1ca3c..2db1408 100644
--- a/src/map/main.cpp
+++ b/src/map/main.cpp
@@ -1,6 +1,21 @@
-// dummy file to make Make dependencies work
#include "map.hpp"
-
-#include "magic-v2.hpp"
+// map/main.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/map/map.cpp b/src/map/map.cpp
index f701730..b49b225 100644
--- a/src/map/map.cpp
+++ b/src/map/map.cpp
@@ -1,4 +1,25 @@
#include "map.hpp"
+// map.cpp - Core of the map server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 Freeyorp
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <sys/time.h>
#include <sys/wait.h>
diff --git a/src/map/map.hpp b/src/map/map.hpp
index 9ab256d..0cec5e8 100644
--- a/src/map/map.hpp
+++ b/src/map/map.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_MAP_HPP
#define TMWA_MAP_MAP_HPP
+// map.hpp - Core of the map server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "map.t.hpp"
diff --git a/src/map/map.t.hpp b/src/map/map.t.hpp
index 4a41ea8..b73cbdd 100644
--- a/src/map/map.t.hpp
+++ b/src/map/map.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_MAP_T_HPP
#define TMWA_MAP_MAP_T_HPP
+// map.t.hpp - Core of the map server.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/vstring.hpp"
diff --git a/src/map/mob.cpp b/src/map/mob.cpp
index c4a4304..a96f829 100644
--- a/src/map/mob.cpp
+++ b/src/map/mob.cpp
@@ -1,5 +1,25 @@
-
#include "mob.hpp"
+// mob.cpp - Really scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 Freeyorp
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cmath>
diff --git a/src/map/mob.hpp b/src/map/mob.hpp
index 305cd16..e7d81bd 100644
--- a/src/map/mob.hpp
+++ b/src/map/mob.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_MOB_HPP
#define TMWA_MAP_MOB_HPP
+// mob.hpp - Really scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "mob.t.hpp"
diff --git a/src/map/mob.t.hpp b/src/map/mob.t.hpp
index c8b1e7a..37fd13e 100644
--- a/src/map/mob.t.hpp
+++ b/src/map/mob.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_MOB_T_HPP
#define TMWA_MAP_MOB_T_HPP
+// mob.t.hpp - Really scary code.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/map/npc.cpp b/src/map/npc.cpp
index 514c042..7fe13f1 100644
--- a/src/map/npc.cpp
+++ b/src/map/npc.cpp
@@ -1,4 +1,24 @@
#include "npc.hpp"
+// npc.cpp - Noncombatants.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cstdlib>
diff --git a/src/map/npc.hpp b/src/map/npc.hpp
index 8d2dc5b..eb9a5eb 100644
--- a/src/map/npc.hpp
+++ b/src/map/npc.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_NPC_HPP
#define TMWA_MAP_NPC_HPP
+// npc.hpp - Noncombatants.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstddef>
# include <cstdint>
diff --git a/src/map/party.cpp b/src/map/party.cpp
index eadf392..75c54cf 100644
--- a/src/map/party.cpp
+++ b/src/map/party.cpp
@@ -1,4 +1,25 @@
#include "party.hpp"
+// party.cpp - Small groups of temporary allies.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 Freeyorp
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cstring>
diff --git a/src/map/party.hpp b/src/map/party.hpp
index c2d4e9d..007de6b 100644
--- a/src/map/party.hpp
+++ b/src/map/party.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_PARTY_HPP
#define TMWA_MAP_PARTY_HPP
+// party.hpp - Small groups of temporary allies.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <functional>
diff --git a/src/map/path.cpp b/src/map/path.cpp
index a237fa8..f0204a4 100644
--- a/src/map/path.cpp
+++ b/src/map/path.cpp
@@ -1,4 +1,25 @@
#include "path.hpp"
+// path.cpp - Pathfinding system.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 Stefan Dombrowski
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
diff --git a/src/map/path.hpp b/src/map/path.hpp
index 69316e9..47b9814 100644
--- a/src/map/path.hpp
+++ b/src/map/path.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_PATH_HPP
#define TMWA_MAP_PATH_HPP
+// path.hpp - Pathfinding system.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "map.hpp"
diff --git a/src/map/pc.cpp b/src/map/pc.cpp
index fa633b8..0256eff 100644
--- a/src/map/pc.cpp
+++ b/src/map/pc.cpp
@@ -1,4 +1,26 @@
#include "pc.hpp"
+// pc.cpp - Player state changes.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011 Jessica Tölke
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2012-2013 Freeyorp
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cstdlib>
diff --git a/src/map/pc.hpp b/src/map/pc.hpp
index 0226019..35d9c70 100644
--- a/src/map/pc.hpp
+++ b/src/map/pc.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_PC_HPP
#define TMWA_MAP_PC_HPP
+// pc.hpp - Player state changes.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "pc.t.hpp"
diff --git a/src/map/pc.t.hpp b/src/map/pc.t.hpp
index 29c3515..65e1046 100644
--- a/src/map/pc.t.hpp
+++ b/src/map/pc.t.hpp
@@ -1,5 +1,28 @@
#ifndef TMWA_MAP_PC_T_HPP
#define TMWA_MAP_PC_T_HPP
+// pc.t.hpp - Player state changes.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 Freeyorp
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/map/script.cpp b/src/map/script.cpp
index a088cb8..93f9d31 100644
--- a/src/map/script.cpp
+++ b/src/map/script.cpp
@@ -1,4 +1,26 @@
#include "script.hpp"
+// script.cpp - EAthena script frontend, engine, and library.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011 Chuck Miller
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 wushin
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cctype>
diff --git a/src/map/script.hpp b/src/map/script.hpp
index ea087c2..9ae893d 100644
--- a/src/map/script.hpp
+++ b/src/map/script.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_SCRIPT_HPP
#define TMWA_MAP_SCRIPT_HPP
+// script.hpp - EAthena script frontend, engine, and library.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
# include <cstring> // for inlined get_str - TODO remove
diff --git a/src/map/skill-pools.cpp b/src/map/skill-pools.cpp
index 2ac3a93..6b46d79 100644
--- a/src/map/skill-pools.cpp
+++ b/src/map/skill-pools.cpp
@@ -1,4 +1,23 @@
#include "skill.hpp"
+// skill-pools.cpp - Additional support for focusable skills.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../io/cxxstdio.hpp"
diff --git a/src/map/skill-pools.hpp b/src/map/skill-pools.hpp
index 8c7e195..6781907 100644
--- a/src/map/skill-pools.hpp
+++ b/src/map/skill-pools.hpp
@@ -1 +1,24 @@
-// dummy header to make Make dependencies work
+#ifndef TMWA_MAP_SKILL_POOLS_HPP
+#define TMWA_MAP_SKILL_POOLS_HPP
+// skill-pools.hpp - dummy header to make Make dependencies work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
+
+#endif // TMWA_MAP_SKILL_POOLS_HPP
diff --git a/src/map/skill.cpp b/src/map/skill.cpp
index c29704a..37a3b44 100644
--- a/src/map/skill.cpp
+++ b/src/map/skill.cpp
@@ -1,4 +1,25 @@
#include "skill.hpp"
+// skill.cpp - Old-style skills.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2012 Vincent Petithory
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cassert>
#include <cstdlib>
diff --git a/src/map/skill.hpp b/src/map/skill.hpp
index ece2ab5..1a615c1 100644
--- a/src/map/skill.hpp
+++ b/src/map/skill.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_SKILL_HPP
#define TMWA_MAP_SKILL_HPP
+// skill.hpp - Old-style skills.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "skill.t.hpp"
# include "skill-pools.hpp"
diff --git a/src/map/skill.t.hpp b/src/map/skill.t.hpp
index aedbb11..4e30cba 100644
--- a/src/map/skill.t.hpp
+++ b/src/map/skill.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_SKILL_T_HPP
#define TMWA_MAP_SKILL_T_HPP
+// skill.t.hpp - Old-style skills.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/map/storage.hpp b/src/map/storage.hpp
index 0e6d111..702c908 100644
--- a/src/map/storage.hpp
+++ b/src/map/storage.hpp
@@ -1,8 +1,27 @@
#ifndef TMWA_MAP_STORAGE_HPP
#define TMWA_MAP_STORAGE_HPP
+// storage.hpp - Storage handling.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
-// Copyright (c) Athena Dev Teams - Licensed under GNU GPL
-// For more information, see COPYING in the main folder
+# include "../sanity.hpp"
# include "map.hpp"
diff --git a/src/map/tmw.cpp b/src/map/tmw.cpp
index 1c18bd5..46128d1 100644
--- a/src/map/tmw.cpp
+++ b/src/map/tmw.cpp
@@ -1,4 +1,23 @@
#include "tmw.hpp"
+// tmw.cpp - Some random functions added by TMW.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <cctype>
#include <cstring>
diff --git a/src/map/tmw.hpp b/src/map/tmw.hpp
index 65eb28a..670599e 100644
--- a/src/map/tmw.hpp
+++ b/src/map/tmw.hpp
@@ -1,5 +1,26 @@
#ifndef TMWA_MAP_TMW_HPP
#define TMWA_MAP_TMW_HPP
+// tmw.hpp - Some random functions added by TMW.
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../strings/fwd.hpp"
diff --git a/src/map/trade.cpp b/src/map/trade.cpp
index bd6e2bf..f358d90 100644
--- a/src/map/trade.cpp
+++ b/src/map/trade.cpp
@@ -1,4 +1,24 @@
#include "trade.hpp"
+// trade.cpp - Inter-player item and money transactions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../compat/nullpo.hpp"
diff --git a/src/map/trade.hpp b/src/map/trade.hpp
index 1fb30f4..dc81c54 100644
--- a/src/map/trade.hpp
+++ b/src/map/trade.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MAP_TRADE_HPP
#define TMWA_MAP_TRADE_HPP
+// trade.hpp - Inter-player item and money transactions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "map.hpp"
diff --git a/src/mmo/config_parse.cpp b/src/mmo/config_parse.cpp
index d677d8e..b954e8b 100644
--- a/src/mmo/config_parse.cpp
+++ b/src/mmo/config_parse.cpp
@@ -1,5 +1,5 @@
#include "config_parse.hpp"
-// config_parse.hpp - Framework for per-server config parsers.
+// config_parse.cpp - Framework for per-server config parsers.
//
// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
//
diff --git a/src/mmo/core.cpp b/src/mmo/core.cpp
index 26b5128..68b7823 100644
--- a/src/mmo/core.cpp
+++ b/src/mmo/core.cpp
@@ -1,4 +1,24 @@
#include "core.hpp"
+// core.cpp - The main loop.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <sys/wait.h>
diff --git a/src/mmo/core.hpp b/src/mmo/core.hpp
index 7a26f7d..5699045 100644
--- a/src/mmo/core.hpp
+++ b/src/mmo/core.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_MMO_CORE_HPP
#define TMWA_MMO_CORE_HPP
+// core.hpp - The main loop.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/mmo/dumb_ptr.cpp b/src/mmo/dumb_ptr.cpp
index 5f73d27..77e3080 100644
--- a/src/mmo/dumb_ptr.cpp
+++ b/src/mmo/dumb_ptr.cpp
@@ -1,3 +1,21 @@
#include "dumb_ptr.hpp"
+// dumb_ptr.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/mmo/extract_test.cpp b/src/mmo/extract_test.cpp
index 3d0610e..60ab49e 100644
--- a/src/mmo/extract_test.cpp
+++ b/src/mmo/extract_test.cpp
@@ -1,9 +1,29 @@
#include "extract.hpp"
+// extract_test.cpp - Testsuite for a simple, hierarchical, tokenizer
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../strings/xstring.hpp"
+#include "../poison.hpp"
+
TEST(extract, record_int)
{
int x, y, z;
diff --git a/src/mmo/human_time_diff.cpp b/src/mmo/human_time_diff.cpp
index 93a6d52..f2f720e 100644
--- a/src/mmo/human_time_diff.cpp
+++ b/src/mmo/human_time_diff.cpp
@@ -1,3 +1,21 @@
#include "human_time_diff.hpp"
+// human_time_diff.cpp - broken deltas
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/mmo/human_time_diff_test.cpp b/src/mmo/human_time_diff_test.cpp
index d3ddad1..138849b 100644
--- a/src/mmo/human_time_diff_test.cpp
+++ b/src/mmo/human_time_diff_test.cpp
@@ -1,7 +1,27 @@
#include "human_time_diff.hpp"
+// human_time_diff.hpp - Testwuite for broken deltas
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
// a sequence of [-+]?[0-9]+([ay]|m|[jd]|h|mn|s)
TEST(humantimediff, single)
diff --git a/src/mmo/ip_test.cpp b/src/mmo/ip_test.cpp
index 7ef1047..8e50453 100644
--- a/src/mmo/ip_test.cpp
+++ b/src/mmo/ip_test.cpp
@@ -1,9 +1,29 @@
#include "ip.hpp"
+// ip_test.cpp - Testsuite for implementation of IP address functions.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
#include "../io/cxxstdio.hpp"
+#include "../poison.hpp"
+
#define CB(X) (std::integral_constant<bool, (X)>::value)
TEST(ip4addr, cmp)
{
diff --git a/src/mmo/md5more.cpp b/src/mmo/md5more.cpp
index 51ff5c4..3fce5c7 100644
--- a/src/mmo/md5more.cpp
+++ b/src/mmo/md5more.cpp
@@ -1,4 +1,24 @@
#include "md5more.hpp"
+// md5more.cpp - Non-basic MD5 functions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../compat/rawmem.hpp"
diff --git a/src/mmo/md5more.hpp b/src/mmo/md5more.hpp
index 0c50cca..b1da783 100644
--- a/src/mmo/md5more.hpp
+++ b/src/mmo/md5more.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MMO_MD5MORE_HPP
#define TMWA_MMO_MD5MORE_HPP
+// md5more.hpp - Non-basic MD5 functions.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include "../generic/md5.hpp"
diff --git a/src/mmo/mmo.cpp b/src/mmo/mmo.cpp
index e9893ee..8bf7edf 100644
--- a/src/mmo/mmo.cpp
+++ b/src/mmo/mmo.cpp
@@ -1,3 +1,21 @@
#include "mmo.hpp"
+// mmo.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../poison.hpp"
diff --git a/src/mmo/mmo.hpp b/src/mmo/mmo.hpp
index f867492..c9d62ca 100644
--- a/src/mmo/mmo.hpp
+++ b/src/mmo/mmo.hpp
@@ -1,6 +1,25 @@
-/// Global structures and defines
#ifndef TMWA_MMO_MMO_HPP
#define TMWA_MMO_MMO_HPP
+// mmo.hpp - Huge mess of structures and constants.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/mmo/socket.cpp b/src/mmo/socket.cpp
index 73e32a4..48cd149 100644
--- a/src/mmo/socket.cpp
+++ b/src/mmo/socket.cpp
@@ -1,4 +1,25 @@
#include "socket.hpp"
+// socket.cpp - Network event system.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+// Copyright © 2013 MadCamel
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <arpa/inet.h>
#include <netinet/tcp.h>
diff --git a/src/mmo/socket.hpp b/src/mmo/socket.hpp
index a77f512..3b411e3 100644
--- a/src/mmo/socket.hpp
+++ b/src/mmo/socket.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_MMO_SOCKET_HPP
#define TMWA_MMO_SOCKET_HPP
+// socket.hpp - Network event system.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/mmo/timer.cpp b/src/mmo/timer.cpp
index b5a2a5e..6e28a12 100644
--- a/src/mmo/timer.cpp
+++ b/src/mmo/timer.cpp
@@ -1,4 +1,24 @@
#include "timer.hpp"
+// timer.cpp - Future event scheduler.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <sys/stat.h>
#include <sys/time.h>
diff --git a/src/mmo/timer.hpp b/src/mmo/timer.hpp
index 01b8623..363cf17 100644
--- a/src/mmo/timer.hpp
+++ b/src/mmo/timer.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_MMO_TIMER_HPP
#define TMWA_MMO_TIMER_HPP
+// timer.hpp - Future event scheduler.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "timer.t.hpp"
diff --git a/src/mmo/timer.t.hpp b/src/mmo/timer.t.hpp
index dcc88f8..6066e7c 100644
--- a/src/mmo/timer.t.hpp
+++ b/src/mmo/timer.t.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MMO_TIMER_T_HPP
#define TMWA_MMO_TIMER_T_HPP
+// timer.t.hpp - Future event scheduler.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <chrono>
# include <functional>
diff --git a/src/mmo/utils.cpp b/src/mmo/utils.cpp
index 0dbf145..a1316d1 100644
--- a/src/mmo/utils.cpp
+++ b/src/mmo/utils.cpp
@@ -1,4 +1,24 @@
#include "utils.hpp"
+// utils.cpp - Useful stuff that hasn't been categorized.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <netinet/in.h>
#include <sys/time.h>
diff --git a/src/mmo/utils.hpp b/src/mmo/utils.hpp
index 40ff595..d59f7ac 100644
--- a/src/mmo/utils.hpp
+++ b/src/mmo/utils.hpp
@@ -1,5 +1,25 @@
#ifndef TMWA_MMO_UTILS_HPP
#define TMWA_MMO_UTILS_HPP
+// utils.hpp - Useful stuff that hasn't been categorized.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
# include "../sanity.hpp"
diff --git a/src/mmo/version.cpp b/src/mmo/version.cpp
index 6f42f11..54b1709 100644
--- a/src/mmo/version.cpp
+++ b/src/mmo/version.cpp
@@ -1,4 +1,24 @@
#include "version.hpp"
+// version.cpp - Prevent mass rebuild when conf/version.hpp changes.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../conf/version.hpp"
diff --git a/src/mmo/version.hpp b/src/mmo/version.hpp
index 420cbf9..11bab39 100644
--- a/src/mmo/version.hpp
+++ b/src/mmo/version.hpp
@@ -1,5 +1,27 @@
#ifndef TMWA_MMO_VERSION_HPP
#define TMWA_MMO_VERSION_HPP
+// version.hpp - Prevent mass rebuild when conf/version.hpp changes.
+//
+// Copyright © ????-2004 Athena Dev Teams
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <cstdint>
diff --git a/src/monitor/main.cpp b/src/monitor/main.cpp
index d2d22c4..c882105 100644
--- a/src/monitor/main.cpp
+++ b/src/monitor/main.cpp
@@ -1,11 +1,22 @@
-/**
- * Name: eAthena processes monitor
- * Original Author: Bartosz Waszak <waszi@evil.org.pl>
- * Rewrite Author: Ben Longbons <b.r.longbons@gmail.com>
- * License: GPL
- * Compilation:
- * gcc -o eathena-monitor eathena-monitor.c
- */
+// monitor/main.cpp - Old daemon to restart servers when they crashed.
+//
+// Copyright © ???? Bartosz Waszak <waszi@evil.org.pl>
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <sys/wait.h>
diff --git a/src/poison.hpp b/src/poison.hpp
index 51bf6ef..0328825 100644
--- a/src/poison.hpp
+++ b/src/poison.hpp
@@ -1,4 +1,26 @@
#ifndef GENERATING_DEPENDENCIES
+// poison.hpp - List of dangerous functions and objects.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# if 0
+# include "../sanity.hpp"
+# endif
// impossible(*) to use safely
// removed in C11
diff --git a/src/range/slice.cpp b/src/range/slice.cpp
index 5b23447..5e00233 100644
--- a/src/range/slice.cpp
+++ b/src/range/slice.cpp
@@ -1 +1,21 @@
#include "slice.hpp"
+// slice.cpp - dummy file to make Make dependencies work
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+#include "../poison.hpp"
diff --git a/src/range/slice_test.cpp b/src/range/slice_test.cpp
index 5bd2748..f59bf84 100644
--- a/src/range/slice_test.cpp
+++ b/src/range/slice_test.cpp
@@ -1,7 +1,27 @@
#include "slice.hpp"
+// slice_test.cpp - Testsuite for a borrowed array
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
TEST(slice, slice)
{
int init[] = {1, 2, 3, 4, 5};
diff --git a/src/sanity.hpp b/src/sanity.hpp
index b048c36..f29a7c3 100644
--- a/src/sanity.hpp
+++ b/src/sanity.hpp
@@ -1,6 +1,27 @@
-/// Keep spatulas out of the build environment
#ifndef TMWA_SANITY_HPP
#define TMWA_SANITY_HPP
+// sanity.hpp - Keep spatulas out of the build environment.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# if 0
+# include "../sanity.hpp"
+# endif
# ifndef __cplusplus
# error "Please compile in C++ mode"
diff --git a/src/sexpr/lexer_test.cpp b/src/sexpr/lexer_test.cpp
index 7a2dc09..ade79af 100644
--- a/src/sexpr/lexer_test.cpp
+++ b/src/sexpr/lexer_test.cpp
@@ -1,7 +1,27 @@
#include "lexer.hpp"
+// lexer_test.cpp - Testsuite for sexpr tokenizer.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
static
io::FD string_pipe(ZString sz)
{
diff --git a/src/sexpr/main.cpp b/src/sexpr/main.cpp
index 7d63ddf..18cb8c2 100644
--- a/src/sexpr/main.cpp
+++ b/src/sexpr/main.cpp
@@ -1,3 +1,21 @@
+// sexpr/main.cpp - Driver for new magic formatter.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <stack>
#include <map>
diff --git a/src/sexpr/parser_test.cpp b/src/sexpr/parser_test.cpp
index a752313..d67d041 100644
--- a/src/sexpr/parser_test.cpp
+++ b/src/sexpr/parser_test.cpp
@@ -1,7 +1,27 @@
#include "parser.hpp"
+// parser_test.cpp - Testsuite for sexpr tree builder.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
static
io::FD string_pipe(ZString sz)
{
diff --git a/src/spell-convert/ast.cpp b/src/spell-convert/ast.cpp
index eb66752..e9ec19c 100644
--- a/src/spell-convert/ast.cpp
+++ b/src/spell-convert/ast.cpp
@@ -1,7 +1,27 @@
#include "ast.hpp"
+// ast.cpp - Hacky converter between magic formats.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../io/cxxstdio.hpp"
+#include "../poison.hpp"
+
void Constant::dump()
{
PRINTF("(CONST %s\n", name);
@@ -113,7 +133,7 @@ void ExplicitCallEffect::print()
void SleepEffect::print()
{
PRINTF("(WAIT ");
- time->show();
+ time_->show();
PRINTF(")");
}
void CallExpr::print()
@@ -255,6 +275,6 @@ void SpellGuardMana::declare()
void SpellGuardCasttime::declare()
{
PRINTF("(CASTTIME ");
- time->show();
+ time_->show();
PRINTF(")");
}
diff --git a/src/spell-convert/ast.hpp b/src/spell-convert/ast.hpp
index afb280a..3d2f282 100644
--- a/src/spell-convert/ast.hpp
+++ b/src/spell-convert/ast.hpp
@@ -1,5 +1,25 @@
-#ifndef AST_HPP
-#define AST_HPP
+#ifndef TMWA_SPELL_CONVERT_AST_HPP
+#define TMWA_SPELL_CONVERT_AST_HPP
+// ast.hpp - Hacky converter between magic formats.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+# include "../sanity.hpp"
# include <deque>
# include <vector>
@@ -222,10 +242,10 @@ struct ExplicitCallEffect : Effect
struct SleepEffect : Effect
{
- Expression *time;
+ Expression *time_;
SleepEffect(Expression *t)
- : time(t)
+ : time_(t)
{}
virtual void print() override;
@@ -336,9 +356,9 @@ struct SpellGuardMana : SpellGuard
};
struct SpellGuardCasttime : SpellGuard
{
- Expression *time;
+ Expression *time_;
- SpellGuardCasttime(Expression *x) : time(x) {}
+ SpellGuardCasttime(Expression *x) : time_(x) {}
virtual void declare() override;
};
@@ -442,4 +462,4 @@ struct AreaBar : Expression
# undef override
# endif
-#endif // AST_HPP
+#endif // TMWA_SPELL_CONVERT_AST_HPP
diff --git a/src/spell-convert/lexer.lpp b/src/spell-convert/lexer.lpp
index 92acf48..b6c6d76 100644
--- a/src/spell-convert/lexer.lpp
+++ b/src/spell-convert/lexer.lpp
@@ -1,6 +1,25 @@
%{
/* vim: set ft=lex: */
//#include "lexer.hpp"
+// magic-interpreter-lexer.lpp - Old magic tokenizer
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include "../strings/rstring.hpp"
#include "../strings/zstring.hpp"
diff --git a/src/spell-convert/main.cpp b/src/spell-convert/main.cpp
index 87f42b9..0c0d04e 100644
--- a/src/spell-convert/main.cpp
+++ b/src/spell-convert/main.cpp
@@ -1,6 +1,27 @@
+// spell-convert/main.cpp - Hacky magic conversion driver.
+//
+// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include "lexer.hpp"
#include "parser.hpp"
+#include "../poison.hpp"
+
int main()
{
spell_converterparse();
diff --git a/src/spell-convert/parser.ypp b/src/spell-convert/parser.ypp
index 822727d..8a40543 100644
--- a/src/spell-convert/parser.ypp
+++ b/src/spell-convert/parser.ypp
@@ -1,6 +1,26 @@
%code requires
{
/* vim: set ft=yacc: */
+// magic-interpreter-parser.ypp - Old magic tokenizer
+//
+// Copyright © 2004-2011 The Mana World Development Team
+// Copyright © 2011-2014 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include "../strings/rstring.hpp"
#include "ast.hpp"
diff --git a/src/strings/all.hpp b/src/strings/all.hpp
index 46d5366..26079ed 100644
--- a/src/strings/all.hpp
+++ b/src/strings/all.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "base.hpp"
# include "mstring.hpp"
# include "rstring.hpp"
diff --git a/src/strings/astring.hpp b/src/strings/astring.hpp
index e682ef0..aab14cf 100644
--- a/src/strings/astring.hpp
+++ b/src/strings/astring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include <cstdarg>
# include <cstring>
diff --git a/src/strings/base.hpp b/src/strings/base.hpp
index c5181da..ee7480b 100644
--- a/src/strings/base.hpp
+++ b/src/strings/base.hpp
@@ -1,6 +1,6 @@
#ifndef TMWA_STRINGS_BASE_HPP
#define TMWA_STRINGS_BASE_HPP
-// strings/base.cls.hpp - CRTP base for string implementations.
+// strings/base.hpp - CRTP base for string implementations.
//
// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
//
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "fwd.hpp"
# include "pair.hpp"
diff --git a/src/strings/base_test.cpp b/src/strings/base_test.cpp
index 3f9900e..52c44dc 100644
--- a/src/strings/base_test.cpp
+++ b/src/strings/base_test.cpp
@@ -1,4 +1,22 @@
#include "base.hpp"
+// strings/base_test.cpp - Testsuite for CRTP base for string implementations.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <gtest/gtest.h>
@@ -6,6 +24,8 @@
#include "xstring.hpp"
#include "rstring.hpp"
+#include "../poison.hpp"
+
using namespace strings;
struct _test : VString<1> {};
diff --git a/src/strings/mstring.hpp b/src/strings/mstring.hpp
index 6f257ed..8225d9e 100644
--- a/src/strings/mstring.hpp
+++ b/src/strings/mstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include <deque>
# include "base.hpp"
diff --git a/src/strings/rstring.hpp b/src/strings/rstring.hpp
index b79c7f6..7cb19d6 100644
--- a/src/strings/rstring.hpp
+++ b/src/strings/rstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include <cstdarg>
# include <cstring>
diff --git a/src/strings/sstring.hpp b/src/strings/sstring.hpp
index 1836d69..7166e94 100644
--- a/src/strings/sstring.hpp
+++ b/src/strings/sstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "base.hpp"
# include "rstring.hpp"
diff --git a/src/strings/strings2_test.cpp b/src/strings/strings2_test.cpp
index 24bfc0c..e5d5281 100644
--- a/src/strings/strings2_test.cpp
+++ b/src/strings/strings2_test.cpp
@@ -1,7 +1,28 @@
#include "all.hpp"
+// strings2_test.cpp - Testsuite part 2 for strings.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
TEST(StringTests, traits2)
{
ZString print_non = "\t\e";
diff --git a/src/strings/strings_test.cpp b/src/strings/strings_test.cpp
index 55a2ffa..dca463d 100644
--- a/src/strings/strings_test.cpp
+++ b/src/strings/strings_test.cpp
@@ -1,9 +1,29 @@
#include "all.hpp"
+// strings_test.cpp - Testsuite part 1 for strings.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
#include <algorithm>
#include <gtest/gtest.h>
+#include "../poison.hpp"
+
template<typename T>
class StringTest : public ::testing::Test
{
diff --git a/src/strings/tstring.hpp b/src/strings/tstring.hpp
index 700ec3d..7003d37 100644
--- a/src/strings/tstring.hpp
+++ b/src/strings/tstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "base.hpp"
# include "rstring.hpp"
diff --git a/src/strings/vstring.hpp b/src/strings/vstring.hpp
index c467b64..9952ff9 100644
--- a/src/strings/vstring.hpp
+++ b/src/strings/vstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "base.hpp"
namespace strings
diff --git a/src/strings/xstring.hpp b/src/strings/xstring.hpp
index 2766810..8f6eac5 100644
--- a/src/strings/xstring.hpp
+++ b/src/strings/xstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include "base.hpp"
namespace strings
diff --git a/src/strings/zstring.hpp b/src/strings/zstring.hpp
index 96aadc0..717da88 100644
--- a/src/strings/zstring.hpp
+++ b/src/strings/zstring.hpp
@@ -19,6 +19,8 @@
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
+# include "../sanity.hpp"
+
# include <cstring>
# include "base.hpp"
diff --git a/src/tests/test.cpp b/src/tests/test.cpp
index 96d7200..d9cba5e 100644
--- a/src/tests/test.cpp
+++ b/src/tests/test.cpp
@@ -1,4 +1,24 @@
#include <gtest/gtest.h>
+// test.cpp - Driver for testwuite
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+#include "../poison.hpp"
int main(int argc, char **argv)
{
diff --git a/src/warnings.hpp b/src/warnings.hpp
index 61482bf..1ea0074 100644
--- a/src/warnings.hpp
+++ b/src/warnings.hpp
@@ -2,6 +2,29 @@
// This is the first file in every compilation, passed by the makefile.
// This file contains only preprocessor directions.
+// warnings.hpp - Make the compiler do the hard work.
+//
+// Copyright © 2013 Ben Longbons <b.r.longbons@gmail.com>
+//
+// This file is part of The Mana World (Athena server)
+//
+// 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 3 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, see <http://www.gnu.org/licenses/>.
+
+#if 0
+# include "../sanity.hpp"
+#endif
+
// This file is currently targeted at:
// GCC 4.6 (incomplete due to bugs)
// GCC 4.7 (for few minor workarounds)