diff --git a/src/common/kernel/item.c b/src/common/kernel/item.c
index bf55c38ea..3ad2185fc 100644
--- a/src/common/kernel/item.c
+++ b/src/common/kernel/item.c
@@ -391,6 +391,7 @@ static const char * it_aliases[][2] = {
{ "diamond", "adamantium" },
{ "diamondaxe", "adamantiumaxe" },
{ "diamondplate", "adamantiumplate" },
+ { "aoh", "ao_healing" },
{ NULL, NULL },
};
@@ -716,7 +717,7 @@ typedef struct t_item {
} t_item;
const char * itemnames[MAXITEMS] = {
- "iron", "stone", "horse", "aoh",
+ "iron", "stone", "horse", "ao_healing",
"aots", "roi", "rop", "ao_chastity",
"laen", "fairyboot", "aoc", "pegasus",
"elvenhorse", "dolphin", "roqf", "trollbelt",
diff --git a/src/eressea.sln b/src/eressea.sln
index 1016a7601..1ed731289 100644
--- a/src/eressea.sln
+++ b/src/eressea.sln
@@ -1,5 +1,5 @@
Microsoft Visual Studio Solution File, Format Version 9.00
-# Visual C++ Express 2005
+# Visual Studio 2005
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "util", "common\util.vcproj", "{F70CFB27-8A2F-E447-B452-4E1C590EDA6D}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "kernel", "common\kernel.vcproj", "{6F104C0A-DDF5-A34B-A89C-0DC278DCEF6D}"
@@ -21,9 +21,11 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "eressea-lua", "eressea\eres
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "eressea", "eressea.vcproj", "{AD80EB0B-7CB4-42F2-9C95-8CCEF68DB387}"
EndProject
-Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "codegen", "tools\codegen\codegen.vcproj", "{BEF9E49F-3E98-4CE7-B641-62456E656E34}"
-EndProject
Global
+ GlobalSection(SubversionScc) = preSolution
+ Svn-Managed = True
+ Manager = AnkhSVN - Subversion Support for Visual Studio
+ EndGlobalSection
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
Profile|Win32 = Profile|Win32
@@ -66,18 +68,8 @@ Global
{AD80EB0B-7CB4-42F2-9C95-8CCEF68DB387}.Profile|Win32.Build.0 = Release|Win32
{AD80EB0B-7CB4-42F2-9C95-8CCEF68DB387}.Release|Win32.ActiveCfg = Release|Win32
{AD80EB0B-7CB4-42F2-9C95-8CCEF68DB387}.Release|Win32.Build.0 = Release|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Debug|Win32.ActiveCfg = Debug|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Debug|Win32.Build.0 = Debug|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Profile|Win32.ActiveCfg = Release|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Profile|Win32.Build.0 = Release|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Release|Win32.ActiveCfg = Release|Win32
- {BEF9E49F-3E98-4CE7-B641-62456E656E34}.Release|Win32.Build.0 = Release|Win32
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
- GlobalSection(SubversionScc) = preSolution
- Svn-Managed = True
- Manager = AnkhSVN - Subversion Support for Visual Studio
- EndGlobalSection
EndGlobal
diff --git a/src/eressea/tolua/bind_unit.c b/src/eressea/tolua/bind_unit.c
index 39ce9ce4d..8cf0f3cdb 100644
--- a/src/eressea/tolua/bind_unit.c
+++ b/src/eressea/tolua/bind_unit.c
@@ -828,7 +828,8 @@ tolua_unit_create(lua_State* tolua_S)
{
faction * f = (faction *)tolua_tousertype(tolua_S, 1, 0);
region * r = (region *)tolua_tousertype(tolua_S, 2, 0);
- unit * u = create_unit(r, f, 0, f->race, 0, NULL, NULL);
+ int num = (int)tolua_tonumber(tolua_S, 3, 0);
+ unit * u = create_unit(r, f, num, f->race, 0, NULL, NULL);
tolua_pushusertype(tolua_S, u, "unit");
return 1;
diff --git a/src/res/asgard.xml b/src/res/asgard.xml
index 88e172d85..f6b44c4ed 100644
--- a/src/res/asgard.xml
+++ b/src/res/asgard.xml
@@ -15,6 +15,13 @@
+
+
+
+
+
+
+
@@ -109,12 +116,6 @@
-
-
-
-
-
-
eressea-server@eressea.kn-bremen.de
diff --git a/src/res/asgard/items.xml b/src/res/asgard/items.xml
index 2f370b0fc..569a7ac9f 100644
--- a/src/res/asgard/items.xml
+++ b/src/res/asgard/items.xml
@@ -1,7 +1,7 @@
-
+
@@ -79,7 +79,7 @@
-
+
-
@@ -91,16 +91,17 @@
-
+
-
+
-
+
-
@@ -135,11 +136,15 @@
-
+ -
+
+
-
+ -
+
+
@@ -435,7 +440,7 @@
-
+
diff --git a/src/res/common/armor.xml b/src/res/common/armor.xml
new file mode 100644
index 000000000..dbf673144
--- /dev/null
+++ b/src/res/common/armor.xml
@@ -0,0 +1,68 @@
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
diff --git a/src/res/common/construction.xml b/src/res/common/construction.xml
new file mode 100644
index 000000000..95dcb6a33
--- /dev/null
+++ b/src/res/common/construction.xml
@@ -0,0 +1,10 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/common/items.xml b/src/res/common/items.xml
new file mode 100644
index 000000000..061a1cbba
--- /dev/null
+++ b/src/res/common/items.xml
@@ -0,0 +1,178 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+ -
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/common/luxuries.xml b/src/res/common/luxuries.xml
new file mode 100644
index 000000000..bdf9c110b
--- /dev/null
+++ b/src/res/common/luxuries.xml
@@ -0,0 +1,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/common/potions.xml b/src/res/common/potions.xml
new file mode 100644
index 000000000..48f66068a
--- /dev/null
+++ b/src/res/common/potions.xml
@@ -0,0 +1,282 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/common/resources.xml b/src/res/common/resources.xml
new file mode 100644
index 000000000..434ee5210
--- /dev/null
+++ b/src/res/common/resources.xml
@@ -0,0 +1,74 @@
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/common/weapons.xml b/src/res/common/weapons.xml
new file mode 100644
index 000000000..eec8ff264
--- /dev/null
+++ b/src/res/common/weapons.xml
@@ -0,0 +1,276 @@
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+ -
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/res/conquest.xml b/src/res/conquest.xml
index 27a466f6e..437727e91 100644
--- a/src/res/conquest.xml
+++ b/src/res/conquest.xml
@@ -1,14 +1,20 @@
-
+
Localization
-
-
+
+
-
-
-
-
+
+
+
+
+
+
+
+
+
+
Game specific
@@ -16,6 +22,6 @@
-
-
+
+
diff --git a/src/res/de/strings.xml b/src/res/de/strings.xml
index 62b0dac9a..a47a962a1 100644
--- a/src/res/de/strings.xml
+++ b/src/res/de/strings.xml
@@ -70,7 +70,7 @@
Beim Barte des Proheten! Ach nein, Zwergen. Irgendetwas riecht hier ranzig.
Sniff... Bleah. Don't they ever wash these?
-
+
Diese Amulett ist ein hervorragender Fokus für alle Heilzauber. Ein
mit diesem Fokus gewirkter Heilzauber wird mit größerer
Warscheinlichkeit Erfolgreich sein und doppelt so viele Leute heilen
@@ -1342,10 +1342,10 @@
Amulette der Keuschheit
-
+
Amulett der Heilung
-
+
Amulette der Heilung
diff --git a/src/res/en/strings.xml b/src/res/en/strings.xml
index b65b6dfc6..c7b9f517b 100644
--- a/src/res/en/strings.xml
+++ b/src/res/en/strings.xml
@@ -459,10 +459,10 @@
amulets of gathering
-
+
amulet of healing
-
+
amulets of healing
diff --git a/src/res/eressea.xml b/src/res/eressea.xml
index 53b66ae59..e21623f50 100644
--- a/src/res/eressea.xml
+++ b/src/res/eressea.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/fr/strings.xml b/src/res/fr/strings.xml
index 70087f38e..702eb4c29 100644
--- a/src/res/fr/strings.xml
+++ b/src/res/fr/strings.xml
@@ -476,10 +476,10 @@
amulettes de rassemblement
-
+
amulette de soin
-
+
amulettes de soin
diff --git a/src/res/hse-05-01.xml b/src/res/hse-05-01.xml
index 936e30b23..d63a6328d 100644
--- a/src/res/hse-05-01.xml
+++ b/src/res/hse-05-01.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/hse4.xml b/src/res/hse4.xml
index ca66d2d2c..76eabee98 100644
--- a/src/res/hse4.xml
+++ b/src/res/hse4.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/kingdoms.xml b/src/res/kingdoms.xml
index 43a02c55c..7ef0f07d2 100644
--- a/src/res/kingdoms.xml
+++ b/src/res/kingdoms.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/resources.xml b/src/res/resources.xml
deleted file mode 100644
index 46089da90..000000000
--- a/src/res/resources.xml
+++ /dev/null
@@ -1,882 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
-
-
- -
-
-
-
-
-
-
-
-
-
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- a/src/res/rts.xml
+++ b/src/res/rts.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/tutorial.xml b/src/res/tutorial.xml
index 5a42ea74d..01f87c9bc 100644
--- a/src/res/tutorial.xml
+++ b/src/res/tutorial.xml
@@ -7,7 +7,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/vinyambar-3.xml b/src/res/vinyambar-3.xml
index 08fd2eeba..5bd628ca0 100644
--- a/src/res/vinyambar-3.xml
+++ b/src/res/vinyambar-3.xml
@@ -1,14 +1,14 @@
-
+
Localization
-
-
+
+
-
-
-
-
+
+
+
+
Game specific
@@ -27,8 +27,8 @@
-
-
+
+
vinyambar@eressea.amber.kn-bremen.de
diff --git a/src/res/vinyambar-classic.xml b/src/res/vinyambar-classic.xml
index 96c3fcbbe..fd73b3924 100644
--- a/src/res/vinyambar-classic.xml
+++ b/src/res/vinyambar-classic.xml
@@ -1,13 +1,13 @@
-
+
Localization
-
-
+
+
-
-
-
+
+
+
Game specific
@@ -21,8 +21,8 @@
-
-
+
+
vinyambar@eressea.amber.kn-bremen.de
diff --git a/src/res/vinyambar-wdw.xml b/src/res/vinyambar-wdw.xml
index 52aa89d3d..71c242a66 100644
--- a/src/res/vinyambar-wdw.xml
+++ b/src/res/vinyambar-wdw.xml
@@ -6,7 +6,12 @@
-
+
+
+
+
+
+
diff --git a/src/res/vinyambar.xml b/src/res/vinyambar.xml
index ce3938ffc..f0cc02759 100644
--- a/src/res/vinyambar.xml
+++ b/src/res/vinyambar.xml
@@ -1,13 +1,13 @@
-
+
Localization
-
-
+
+
-
-
-
+
+
+
Game specific
@@ -22,8 +22,8 @@
-
-
+
+
vinyambar@eressea.amber.kn-bremen.de
diff --git a/src/scripts/tests.lua b/src/scripts/tests.lua
index 1b197a8ff..03d320b95 100644
--- a/src/scripts/tests.lua
+++ b/src/scripts/tests.lua
@@ -1,3 +1,12 @@
+local function test_rename()
+ free_game()
+ local r = region.create(0, 0, "plain")
+ local f = faction.create("enno@eressea.de", "human", "de")
+ local u = unit.create(f, r)
+ u:add_item("aoh", 1)
+ assert(u:get_item("ao_healing")==1)
+end
+
local function test_pure()
free_game()
local r = region.create(0, 0, "plain")
@@ -236,6 +245,21 @@ local function test_recruit()
assert(u:get_item("money")==10)
end
+local function test_produce()
+ free_game()
+ local r = region.create(0, 0, "plain")
+ local f = faction.create("enno@eressea.de", "human", "de")
+ local u = unit.create(f, r, 1)
+ u:clear_orders()
+ u:set_skill("weaponsmithing", 3)
+ u:add_item("iron", 2)
+ u:add_item("money", u.number * 10)
+ u:add_order("MACHE Schwert")
+ process_orders()
+ assert(u:get_item("iron")==1)
+ assert(u:get_item("sword")==1)
+end
+
loadscript("extensions.lua")
tests = {
["pure"] = test_pure,
@@ -248,6 +272,8 @@ tests = {
["hashtable"] = test_hashtable,
["gmtool"] = test_gmtool,
["events"] = test_events,
+ ["produce"] = test_produce,
+ ["rename"] = test_rename,
["recruit"] = test_recruit
}