summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBardur Arantsson <bardur@scientician.net>2015-02-23 09:12:01 +0100
committerBardur Arantsson <bardur@scientician.net>2015-02-23 09:12:01 +0100
commit0f610b77f2016ca80b18fdfb7a0bdd6eeb804743 (patch)
treea8dd6a05e76885826bdce314e610fcdcbbebfc25
parent22d802ecbdbee5b06d32d1643af01744689c8b87 (diff)
Split spells4.cc declarations into separate header file
-rw-r--r--src/cmd5.cc1
-rw-r--r--src/externs.h40
-rw-r--r--src/q_library.cc1
-rw-r--r--src/script.cc1
-rw-r--r--src/skills.cc1
-rw-r--r--src/spell_type.cc1
-rw-r--r--src/spells1.cc1
-rw-r--r--src/spells3.cc1
-rw-r--r--src/spells4.cc2
-rw-r--r--src/spells4.hpp41
-rw-r--r--src/spells5.cc1
-rw-r--r--src/spells6.cc1
12 files changed, 51 insertions, 41 deletions
diff --git a/src/cmd5.cc b/src/cmd5.cc
index b58df8f0..93f29a99 100644
--- a/src/cmd5.cc
+++ b/src/cmd5.cc
@@ -16,6 +16,7 @@
#include "spell_type.hpp"
#include "spells1.hpp"
#include "spells2.hpp"
+#include "spells4.hpp"
#include "spells5.hpp"
#include "quark.h"
#include "wizard2.hpp"
diff --git a/src/externs.h b/src/externs.h
index cf90a208..f85cffb8 100644
--- a/src/externs.h
+++ b/src/externs.h
@@ -760,46 +760,6 @@ extern s16b m_bonus(int max, int level);
extern void object_gain_level(object_type *o_ptr);
extern s32b flag_cost(object_type * o_ptr, int plusses);
-/* spells4.c */
-
-extern s32b SCHOOL_AIR;
-extern s32b SCHOOL_AULE;
-extern s32b SCHOOL_CONVEYANCE;
-extern s32b SCHOOL_DEMON;
-extern s32b SCHOOL_DEVICE;
-extern s32b SCHOOL_DIVINATION;
-extern s32b SCHOOL_EARTH;
-extern s32b SCHOOL_ERU;
-extern s32b SCHOOL_FIRE;
-extern s32b SCHOOL_GEOMANCY;
-extern s32b SCHOOL_MANA;
-extern s32b SCHOOL_MANDOS;
-extern s32b SCHOOL_MANWE;
-extern s32b SCHOOL_MELKOR;
-extern s32b SCHOOL_META;
-extern s32b SCHOOL_MIND;
-extern s32b SCHOOL_MUSIC;
-extern s32b SCHOOL_NATURE;
-extern s32b SCHOOL_TEMPORAL;
-extern s32b SCHOOL_TULKAS;
-extern s32b SCHOOL_UDUN;
-extern s32b SCHOOL_ULMO;
-extern s32b SCHOOL_VARDA;
-extern s32b SCHOOL_WATER;
-extern s32b SCHOOL_YAVANNA;
-
-void print_spell_desc(int s, int y);
-void init_school_books();
-school_book_type *school_books_at(int sval);
-void school_book_add_spell(school_book_type *school_book, s32b spell_idx);
-void random_book_setup(s16b sval, s32b spell_idx);
-int print_spell(cptr label, byte color, int y, s32b s);
-int print_book(s16b sval, s32b pval, object_type *obj);
-int school_book_length(int sval);
-int spell_x(int sval, int pval, int i);
-bool_ school_book_contains_spell(int sval, s32b spell_idx);
-void lua_cast_school_spell(s32b spell_idx, bool_ no_cost);
-
/* spells6.c */
void schools_init();
diff --git a/src/q_library.cc b/src/q_library.cc
index c3c044cd..b87b346c 100644
--- a/src/q_library.cc
+++ b/src/q_library.cc
@@ -2,6 +2,7 @@
#include "quark.h"
#include "hooks.h"
#include "spells3.hpp"
+#include "spells4.hpp"
#include <cassert>
diff --git a/src/script.cc b/src/script.cc
index 55b89bdd..3e3ce8a3 100644
--- a/src/script.cc
+++ b/src/script.cc
@@ -12,6 +12,7 @@
#include "angband.h"
#include "q_library.h"
+#include "spells4.hpp"
#include "spells5.hpp"
diff --git a/src/skills.cc b/src/skills.cc
index 84715150..c3fb3835 100644
--- a/src/skills.cc
+++ b/src/skills.cc
@@ -16,6 +16,7 @@
#include "help.hpp"
#include "hooks.h"
#include "spells1.hpp"
+#include "spells4.hpp"
#include "traps.hpp"
#include "util.hpp"
#include "xtra2.hpp"
diff --git a/src/spell_type.cc b/src/spell_type.cc
index eef93e6d..867068f8 100644
--- a/src/spell_type.cc
+++ b/src/spell_type.cc
@@ -2,6 +2,7 @@
#include "range.h"
#include "device_allocation.h"
#include "dice.h"
+#include "spells4.hpp"
#include "angband.h"
diff --git a/src/spells1.cc b/src/spells1.cc
index e51b8ee8..189ad043 100644
--- a/src/spells1.cc
+++ b/src/spells1.cc
@@ -16,6 +16,7 @@
#include "skills.hpp"
#include "spell_type.hpp"
#include "spells2.hpp"
+#include "spells4.hpp"
#include "spells5.hpp"
#include "squeltch.hpp"
#include "traps.hpp"
diff --git a/src/spells3.cc b/src/spells3.cc
index a36dcf1d..22bede27 100644
--- a/src/spells3.cc
+++ b/src/spells3.cc
@@ -8,6 +8,7 @@
#include "spell_idx_list.hpp"
#include "spells1.hpp"
#include "spells2.hpp"
+#include "spells4.hpp"
#include "spells5.hpp"
#include "mimic.hpp"
#include "xtra2.hpp"
diff --git a/src/spells4.cc b/src/spells4.cc
index 75f836a0..9e389d8e 100644
--- a/src/spells4.cc
+++ b/src/spells4.cc
@@ -1,4 +1,4 @@
-#include "angband.h"
+#include "spells4.hpp"
#include "cave.hpp"
#include "cmd5.hpp"
diff --git a/src/spells4.hpp b/src/spells4.hpp
new file mode 100644
index 00000000..b358b571
--- /dev/null
+++ b/src/spells4.hpp
@@ -0,0 +1,41 @@
+#pragma once
+
+#include "angband.h"
+
+extern s32b SCHOOL_AIR;
+extern s32b SCHOOL_AULE;
+extern s32b SCHOOL_CONVEYANCE;
+extern s32b SCHOOL_DEMON;
+extern s32b SCHOOL_DEVICE;
+extern s32b SCHOOL_DIVINATION;
+extern s32b SCHOOL_EARTH;
+extern s32b SCHOOL_ERU;
+extern s32b SCHOOL_FIRE;
+extern s32b SCHOOL_GEOMANCY;
+extern s32b SCHOOL_MANA;
+extern s32b SCHOOL_MANDOS;
+extern s32b SCHOOL_MANWE;
+extern s32b SCHOOL_MELKOR;
+extern s32b SCHOOL_META;
+extern s32b SCHOOL_MIND;
+extern s32b SCHOOL_MUSIC;
+extern s32b SCHOOL_NATURE;
+extern s32b SCHOOL_TEMPORAL;
+extern s32b SCHOOL_TULKAS;
+extern s32b SCHOOL_UDUN;
+extern s32b SCHOOL_ULMO;
+extern s32b SCHOOL_VARDA;
+extern s32b SCHOOL_WATER;
+extern s32b SCHOOL_YAVANNA;
+
+void print_spell_desc(int s, int y);
+void init_school_books();
+school_book_type *school_books_at(int sval);
+void school_book_add_spell(school_book_type *school_book, s32b spell_idx);
+void random_book_setup(s16b sval, s32b spell_idx);
+int print_spell(cptr label, byte color, int y, s32b s);
+int print_book(s16b sval, s32b pval, object_type *obj);
+int school_book_length(int sval);
+int spell_x(int sval, int pval, int i);
+bool_ school_book_contains_spell(int sval, s32b spell_idx);
+void lua_cast_school_spell(s32b spell_idx, bool_ no_cost);
diff --git a/src/spells5.cc b/src/spells5.cc
index 8e7bd4ab..32de8771 100644
--- a/src/spells5.cc
+++ b/src/spells5.cc
@@ -4,6 +4,7 @@
#include "spell_type.hpp"
#include "device_allocation.h"
#include "spells3.hpp"
+#include "spells4.hpp"
#include <cassert>
diff --git a/src/spells6.cc b/src/spells6.cc
index ca344f7c..5c2d2a67 100644
--- a/src/spells6.cc
+++ b/src/spells6.cc
@@ -3,6 +3,7 @@
#include "gods.hpp"
#include "skills.hpp"
#include "spell_type.hpp"
+#include "spells4.hpp"
#include <cassert>
#include <vector>