--- deliantra/server/common/exp.C 2007/11/08 19:43:23 1.17
+++ deliantra/server/common/exp.C 2009/11/06 12:27:05 1.21
@@ -1,22 +1,23 @@
/*
* This file is part of Deliantra, the Roguelike Realtime MMORPG.
*
- * Copyright (©) 2005,2006,2007 Marc Alexander Lehmann / Robin Redeker / the Deliantra team
+ * Copyright (©) 2005,2006,2007,2008 Marc Alexander Lehmann / Robin Redeker / the Deliantra team
* Copyright (©) 2002,2007 Mark Wedel & Crossfire Development Team
* Copyright (©) 1992,2007 Frank Tore Johansen
*
- * Deliantra 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.
+ * Deliantra is free software: you can redistribute it and/or modify it under
+ * the terms of the Affero 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 .
+ * You should have received a copy of the Affero GNU General Public License
+ * and the GNU General Public License along with this program. If not, see
+ * .
*
* The authors can be reached via e-mail to
*/
@@ -73,6 +74,20 @@
};
/*
+ * Returns true if the monster specified has any innate abilities.
+ */
+int
+has_ability (const object *ob)
+{
+ object *tmp;
+
+ for (tmp = ob->inv; tmp != NULL; tmp = tmp->below)
+ if (tmp->type == SPELL || tmp->type == SPELLBOOK)
+ return true;
+ return false;
+}
+
+/*
* new_exp() is an alternative way to calculate experience based
* on the ability of a monster.
* It's far from perfect, and doesn't consider everything which
@@ -121,21 +136,6 @@
return (int) exp;
}
-/*
- * Returns true if the monster specified has any innate abilities.
- */
-
-int
-has_ability (const object *ob)
-{
- object *tmp;
-
- for (tmp = ob->inv; tmp != NULL; tmp = tmp->below)
- if (tmp->type == SPELL || tmp->type == SPELLBOOK)
- return true;
- return false;
-}
-
/* This loads the experience table from the exp_table
* file. This tends to exit on any errors, since it
* populates the table as it goes along, so if there
@@ -231,18 +231,3 @@
}
}
-/* Dump the table - useful in terms of debugging to make sure the
- * format of the exp_table is correct.
- */
-
-void
-dump_experience ()
-{
- int i;
-
- for (i = 1; i <= settings.max_level; i++)
- {
- fprintf (logfile, "%4d %20lld\n", i, (long long) levels[i]);
- }
- exit (0);
-}