undo more CRLF screwups.

This commit is contained in:
Enno Rehling 2010-08-08 01:06:34 -07:00
parent 72d186787b
commit 44804c2074
29 changed files with 920 additions and 920 deletions

View File

@ -1,17 +1,17 @@
[eressea]
base = .
load = setup.lua
report = reports
verbose = 0
lomem = 0
debug = 0
memcheck = 0
locales = de,en
[config]
game = example
source_dir = ../..
maxnmrs = 10
[editor]
color = 1
[eressea]
base = .
load = setup.lua
report = reports
verbose = 0
lomem = 0
debug = 0
memcheck = 0
locales = de,en
[config]
game = example
source_dir = ../..
maxnmrs = 10
[editor]
color = 1

View File

@ -1,15 +1,15 @@
local srcpath = config.source_dir
local respath = srcpath .. '/example/res'
local paths = {
'example/scripts/?.lua',
'server/scripts/?.lua',
'external/lunit/?.lua'
}
for idx, path in pairs(paths) do
package.path = srcpath .. '/' .. path .. ';' .. package.path
end
read_xml(respath..'/config-example.xml', respath..'/catalog-example.xml')
require "init"
local srcpath = config.source_dir
local respath = srcpath .. '/example/res'
local paths = {
'example/scripts/?.lua',
'server/scripts/?.lua',
'external/lunit/?.lua'
}
for idx, path in pairs(paths) do
package.path = srcpath .. '/' .. path .. ';' .. package.path
end
read_xml(respath..'/config-example.xml', respath..'/catalog-example.xml')
require "init"

View File

@ -1,13 +1,13 @@
<?xml version="1.0"?>
<resources xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- this file contains a lot of armor -->
<xi:include href="eressea:///core/armor/plate.xml"/>
<xi:include href="eressea:///core/armor/chainmail.xml"/>
<xi:include href="eressea:///core/armor/laenmail.xml"/>
<xi:include href="eressea:///core/armor/laenshield.xml"/>
<xi:include href="eressea:///core/armor/rustychainmail.xml"/>
<xi:include href="eressea:///core/armor/rustyshield.xml"/>
<xi:include href="eressea:///core/armor/shield.xml"/>
</resources>
<?xml version="1.0"?>
<resources xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- this file contains a lot of armor -->
<xi:include href="eressea:///core/armor/plate.xml"/>
<xi:include href="eressea:///core/armor/chainmail.xml"/>
<xi:include href="eressea:///core/armor/laenmail.xml"/>
<xi:include href="eressea:///core/armor/laenshield.xml"/>
<xi:include href="eressea:///core/armor/rustychainmail.xml"/>
<xi:include href="eressea:///core/armor/rustyshield.xml"/>
<xi:include href="eressea:///core/armor/shield.xml"/>
</resources>

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<buildings xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="buildings/castle.xml"/>
</buildings>
<?xml version="1.0" encoding="iso-8859-1" ?>
<buildings xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="buildings/castle.xml"/>
</buildings>

View File

@ -1,26 +1,26 @@
<?xml version="1.0"?>
<building name="castle" capacity="1">
<function name="name" value="castle_name"/>
<function name="protection" value="eressea_building_protection"/>
<construction skill="building" minskill="1" maxsize="2" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="1" maxsize="8" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="2" maxsize="40" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="3" maxsize="200" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="4" maxsize="1000" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="5" maxsize="5000" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="6" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
</building>
<?xml version="1.0"?>
<building name="castle" capacity="1">
<function name="name" value="castle_name"/>
<function name="protection" value="eressea_building_protection"/>
<construction skill="building" minskill="1" maxsize="2" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="1" maxsize="8" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="2" maxsize="40" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="3" maxsize="200" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="4" maxsize="1000" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="5" maxsize="5000" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
<construction skill="building" minskill="6" reqsize="1">
<requirement type="stone" quantity="1"/>
</construction>
</building>

View File

@ -1,10 +1,10 @@
<?xml version="1.0"?>
<!DOCTYPE catalog
PUBLIC "-//OASIS/DTD Entity Resolution XML Catalog V1.0//EN"
"http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
<rewriteURI
uriStartString="eressea:///core/"
rewritePrefix="../../server/res/" />
</catalog>
<?xml version="1.0"?>
<!DOCTYPE catalog
PUBLIC "-//OASIS/DTD Entity Resolution XML Catalog V1.0//EN"
"http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd">
<catalog xmlns="urn:oasis:names:tc:entity:xmlns:xml:catalog">
<rewriteURI
uriStartString="eressea:///core/"
rewritePrefix="../../server/res/" />
</catalog>

View File

@ -1,3 +1,3 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<items>
</items>
<?xml version="1.0" encoding="iso-8859-1" ?>
<items>
</items>

View File

@ -1,14 +1,14 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<races xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="races/aquarian.xml"/>
<xi:include href="races/cat.xml"/>
<xi:include href="races/demon.xml"/>
<xi:include href="races/dwarf.xml"/>
<xi:include href="races/elf.xml"/>
<xi:include href="races/goblin.xml"/>
<xi:include href="races/halfling.xml"/>
<xi:include href="races/human.xml"/>
<xi:include href="races/insect.xml"/>
<xi:include href="races/orc.xml"/>
<xi:include href="races/troll.xml"/>
</races>
<?xml version="1.0" encoding="iso-8859-1" ?>
<races xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="races/aquarian.xml"/>
<xi:include href="races/cat.xml"/>
<xi:include href="races/demon.xml"/>
<xi:include href="races/dwarf.xml"/>
<xi:include href="races/elf.xml"/>
<xi:include href="races/goblin.xml"/>
<xi:include href="races/halfling.xml"/>
<xi:include href="races/human.xml"/>
<xi:include href="races/insect.xml"/>
<xi:include href="races/orc.xml"/>
<xi:include href="races/troll.xml"/>
</races>

View File

@ -1,20 +1,20 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="aquarian" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" shipspeed="yes" playerrace="yes" coastal="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="-2"/>
<skill name="building" modifier="-1"/>
<skill name="trade" modifier="2"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="3"/>
<skill name="sailing" modifier="3"/>
<skill name="roadwork" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="giantturtle" default="yes"/>
<familiar race="dolphin"/>
<familiar race="giantturtle"/>
<familiar race="dolphin"/>
<familiar race="dolphin"/>
<familiar race="kraken"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="aquarian" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" shipspeed="yes" playerrace="yes" coastal="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="-2"/>
<skill name="building" modifier="-1"/>
<skill name="trade" modifier="2"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="3"/>
<skill name="sailing" modifier="3"/>
<skill name="roadwork" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="giantturtle" default="yes"/>
<familiar race="dolphin"/>
<familiar race="giantturtle"/>
<familiar race="dolphin"/>
<familiar race="dolphin"/>
<familiar race="kraken"/>
</race>

View File

@ -1,27 +1,27 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="cat" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="90" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" defensemodifier="1" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="-1"/>
<skill name="mining" modifier="-2"/>
<skill name="building" modifier="-1"/>
<skill name="catapult" modifier="-1"/>
<skill name="herbalism" modifier="1"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-2"/>
<skill name="espionage" modifier="2"/>
<skill name="quarrying" modifier="-1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="perception" modifier="2"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="lynx" default="yes"/>
<familiar race="dreamcat"/>
<familiar race="lynx"/>
<familiar race="songdragon"/>
<familiar race="tiger"/>
<familiar race="hellcat"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="cat" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="90" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" defensemodifier="1" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="-1"/>
<skill name="mining" modifier="-2"/>
<skill name="building" modifier="-1"/>
<skill name="catapult" modifier="-1"/>
<skill name="herbalism" modifier="1"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-2"/>
<skill name="espionage" modifier="2"/>
<skill name="quarrying" modifier="-1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="perception" modifier="2"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="lynx" default="yes"/>
<familiar race="dreamcat"/>
<familiar race="lynx"/>
<familiar race="songdragon"/>
<familiar race="tiger"/>
<familiar race="hellcat"/>
</race>

View File

@ -1,33 +1,33 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="demon" magres="0.150000" maxaura="1.000000" regaura="1.250000" recruitcost="150" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="50" ac="2" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" shapeshift="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" recruitethereal="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="initfamiliar" value="oldfamiliars"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="2"/>
<skill name="trade" modifier="-3"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="-3"/>
<skill name="magic" modifier="1"/>
<skill name="training" modifier="-3"/>
<skill name="riding" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-1"/>
<skill name="polearm" modifier="1"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="-3"/>
<skill name="weaponsmithing" modifier="1"/>
<skill name="cartmaking" modifier="-2"/>
<skill name="perception" modifier="1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<attack type="5"/>
<familiar race="imp" default="yes"/>
<familiar race="imp"/>
<familiar race="ghost"/>
<familiar race="rat"/>
<familiar race="wolf"/>
<familiar race="imp"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="demon" magres="0.150000" maxaura="1.000000" regaura="1.250000" recruitcost="150" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="50" ac="2" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" shapeshift="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" recruitethereal="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="initfamiliar" value="oldfamiliars"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="2"/>
<skill name="trade" modifier="-3"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="-3"/>
<skill name="magic" modifier="1"/>
<skill name="training" modifier="-3"/>
<skill name="riding" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-1"/>
<skill name="polearm" modifier="1"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="-3"/>
<skill name="weaponsmithing" modifier="1"/>
<skill name="cartmaking" modifier="-2"/>
<skill name="perception" modifier="1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<attack type="5"/>
<familiar race="imp" default="yes"/>
<familiar race="imp"/>
<familiar race="ghost"/>
<familiar race="rat"/>
<familiar race="wolf"/>
<familiar race="imp"/>
</race>

View File

@ -1,33 +1,33 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="dwarf" magres="0.050000" maxaura="1.000000" regaura="0.500000" recruitcost="110" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="2"/>
<skill name="bow" modifier="-1"/>
<skill name="building" modifier="2"/>
<skill name="trade" modifier="1"/>
<skill name="forestry" modifier="-1"/>
<skill name="catapult" modifier="2"/>
<skill name="herbalism" modifier="-2"/>
<skill name="magic" modifier="-2"/>
<skill name="training" modifier="-2"/>
<skill name="riding" modifier="-2"/>
<skill name="armorer" modifier="2"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-2"/>
<skill name="quarrying" modifier="2"/>
<skill name="roadwork" modifier="2"/>
<skill name="stealth" modifier="-1"/>
<skill name="entertainment" modifier="-1"/>
<skill name="weaponsmithing" modifier="2"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="tunnelworm" default="yes"/>
<familiar race="eagle"/>
<familiar race="owl"/>
<familiar race="lynx"/>
<familiar race="wolf"/>
<familiar race="rat"/>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="dwarf" magres="0.050000" maxaura="1.000000" regaura="0.500000" recruitcost="110" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="2"/>
<skill name="bow" modifier="-1"/>
<skill name="building" modifier="2"/>
<skill name="trade" modifier="1"/>
<skill name="forestry" modifier="-1"/>
<skill name="catapult" modifier="2"/>
<skill name="herbalism" modifier="-2"/>
<skill name="magic" modifier="-2"/>
<skill name="training" modifier="-2"/>
<skill name="riding" modifier="-2"/>
<skill name="armorer" modifier="2"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-2"/>
<skill name="quarrying" modifier="2"/>
<skill name="roadwork" modifier="2"/>
<skill name="stealth" modifier="-1"/>
<skill name="entertainment" modifier="-1"/>
<skill name="weaponsmithing" modifier="2"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="tunnelworm" default="yes"/>
<familiar race="eagle"/>
<familiar race="owl"/>
<familiar race="lynx"/>
<familiar race="wolf"/>
<familiar race="rat"/>
</race>

View File

@ -1,29 +1,29 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="elf" magres="0.100000" maxaura="1.000000" regaura="1.250000" recruitcost="130" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="18" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="-1"/>
<skill name="mining" modifier="-2"/>
<skill name="bow" modifier="2"/>
<skill name="building" modifier="-1"/>
<skill name="catapult" modifier="-2"/>
<skill name="herbalism" modifier="2"/>
<skill name="magic" modifier="1"/>
<skill name="training" modifier="1"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-1"/>
<skill name="quarrying" modifier="-1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="perception" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="lynx" default="yes"/>
<familiar race="fairy"/>
<familiar race="owl"/>
<familiar race="nymph"/>
<familiar race="unicorn"/>
<familiar race="imp"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="elf" magres="0.100000" maxaura="1.000000" regaura="1.250000" recruitcost="130" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="18" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="-1"/>
<skill name="mining" modifier="-2"/>
<skill name="bow" modifier="2"/>
<skill name="building" modifier="-1"/>
<skill name="catapult" modifier="-2"/>
<skill name="herbalism" modifier="2"/>
<skill name="magic" modifier="1"/>
<skill name="training" modifier="1"/>
<skill name="armorer" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-1"/>
<skill name="quarrying" modifier="-1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="stealth" modifier="1"/>
<skill name="perception" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="lynx" default="yes"/>
<familiar race="fairy"/>
<familiar race="owl"/>
<familiar race="nymph"/>
<familiar race="unicorn"/>
<familiar race="imp"/>
</race>

View File

@ -1,27 +1,27 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="goblin" magres="-0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="40" maintenance="10" weight="600" capacity="440" speed="1.000000" hp="16" damage="1d5" unarmedattack="-2" unarmeddefense="0" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="initfamiliar" value="oldfamiliars"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="-1"/>
<skill name="catapult" modifier="1"/>
<skill name="magic" modifier="-1"/>
<skill name="shipcraft" modifier="-2"/>
<skill name="sailing" modifier="-2"/>
<skill name="roadwork" modifier="-2"/>
<skill name="tactics" modifier="-2"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="-1"/>
<skill name="cartmaking" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="rat" default="yes"/>
<familiar race="songdragon"/>
<familiar race="imp"/>
<familiar race="rat"/>
<familiar race="rat"/>
<familiar race="imp"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="goblin" magres="-0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="40" maintenance="10" weight="600" capacity="440" speed="1.000000" hp="16" damage="1d5" unarmedattack="-2" unarmeddefense="0" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="initfamiliar" value="oldfamiliars"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="alchemy" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="-1"/>
<skill name="catapult" modifier="1"/>
<skill name="magic" modifier="-1"/>
<skill name="shipcraft" modifier="-2"/>
<skill name="sailing" modifier="-2"/>
<skill name="roadwork" modifier="-2"/>
<skill name="tactics" modifier="-2"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="-1"/>
<skill name="cartmaking" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="rat" default="yes"/>
<familiar race="songdragon"/>
<familiar race="imp"/>
<familiar race="rat"/>
<familiar race="rat"/>
<familiar race="imp"/>
</race>

View File

@ -1,34 +1,34 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="halfling" magres="0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="18" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<param name="hunger.damage" value="1d14+14"/>
<skill name="crossbow" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="bow" modifier="-1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="2"/>
<skill name="catapult" modifier="-1"/>
<skill name="herbalism" modifier="2"/>
<skill name="training" modifier="-1"/>
<skill name="riding" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="-1"/>
<skill name="sailing" modifier="-2"/>
<skill name="polearm" modifier="-1"/>
<skill name="espionage" modifier="1"/>
<skill name="roadwork" modifier="1"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="1"/>
<skill name="cartmaking" modifier="2"/>
<skill name="perception" modifier="1"/>
<skill name="taxation" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="owl" default="yes"/>
<familiar race="rat"/>
<familiar race="eagle"/>
<familiar race="songdragon"/>
<familiar race="eagle"/>
<familiar race="rat"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="halfling" magres="0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="18" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<param name="hunger.damage" value="1d14+14"/>
<skill name="crossbow" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="bow" modifier="-1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="2"/>
<skill name="catapult" modifier="-1"/>
<skill name="herbalism" modifier="2"/>
<skill name="training" modifier="-1"/>
<skill name="riding" modifier="-1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="-1"/>
<skill name="sailing" modifier="-2"/>
<skill name="polearm" modifier="-1"/>
<skill name="espionage" modifier="1"/>
<skill name="roadwork" modifier="1"/>
<skill name="stealth" modifier="1"/>
<skill name="entertainment" modifier="1"/>
<skill name="cartmaking" modifier="2"/>
<skill name="perception" modifier="1"/>
<skill name="taxation" modifier="-1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="owl" default="yes"/>
<familiar race="rat"/>
<familiar race="eagle"/>
<familiar race="songdragon"/>
<familiar race="eagle"/>
<familiar race="rat"/>
</race>

View File

@ -1,17 +1,17 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="human" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="75" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="trade" modifier="1"/>
<skill name="herbalism" modifier="-1"/>
<skill name="shipcraft" modifier="1"/>
<skill name="sailing" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="wolf" default="yes"/>
<familiar race="dreamcat"/>
<familiar race="owl"/>
<familiar race="owl"/>
<familiar race="eagle"/>
<familiar race="imp"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="human" magres="0.000000" maxaura="1.000000" regaura="1.000000" recruitcost="75" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="20" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="trade" modifier="1"/>
<skill name="herbalism" modifier="-1"/>
<skill name="shipcraft" modifier="1"/>
<skill name="sailing" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="wolf" default="yes"/>
<familiar race="dreamcat"/>
<familiar race="owl"/>
<familiar race="owl"/>
<familiar race="eagle"/>
<familiar race="imp"/>
</race>

View File

@ -1,30 +1,30 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="insect" magres="0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" ac="2" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="crossbow" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="bow" modifier="-2"/>
<skill name="building" modifier="2"/>
<skill name="trade" modifier="-1"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="1"/>
<skill name="training" modifier="-3"/>
<skill name="riding" modifier="-3"/>
<skill name="armorer" modifier="2"/>
<skill name="melee" modifier="-1"/>
<skill name="polearm" modifier="1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="-1"/>
<skill name="entertainment" modifier="-2"/>
<skill name="perception" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="ghost" default="yes"/>
<familiar race="rat"/>
<familiar race="owl"/>
<familiar race="rat"/>
<familiar race="tunnelworm"/>
<familiar race="imp"/>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="insect" magres="0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="80" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" ac="2" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="crossbow" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="bow" modifier="-2"/>
<skill name="building" modifier="2"/>
<skill name="trade" modifier="-1"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="1"/>
<skill name="training" modifier="-3"/>
<skill name="riding" modifier="-3"/>
<skill name="armorer" modifier="2"/>
<skill name="melee" modifier="-1"/>
<skill name="polearm" modifier="1"/>
<skill name="roadwork" modifier="-1"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="-1"/>
<skill name="entertainment" modifier="-2"/>
<skill name="perception" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="ghost" default="yes"/>
<familiar race="rat"/>
<familiar race="owl"/>
<familiar race="rat"/>
<familiar race="tunnelworm"/>
<familiar race="imp"/>
</race>

View File

@ -1,31 +1,31 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="orc" magres="-0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="70" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<param name="recruit_multi" value="0.5"/>
<skill name="alchemy" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="-3"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="-2"/>
<skill name="magic" modifier="-1"/>
<skill name="training" modifier="-1"/>
<skill name="armorer" modifier="1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-1"/>
<skill name="espionage" modifier="-1"/>
<skill name="quarrying" modifier="1"/>
<skill name="tactics" modifier="1"/>
<skill name="entertainment" modifier="-2"/>
<skill name="weaponsmithing" modifier="2"/>
<skill name="cartmaking" modifier="-1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="goblin" default="yes"/>
<familiar race="ghost"/>
<familiar race="imp"/>
<familiar race="rat"/>
<familiar race="wolf"/>
<familiar race="demon"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="orc" magres="-0.050000" maxaura="1.000000" regaura="1.000000" recruitcost="70" maintenance="10" weight="1000" capacity="540" speed="1.000000" hp="24" damage="1d5" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<param name="recruit_multi" value="0.5"/>
<skill name="alchemy" modifier="1"/>
<skill name="mining" modifier="1"/>
<skill name="building" modifier="1"/>
<skill name="trade" modifier="-3"/>
<skill name="forestry" modifier="1"/>
<skill name="herbalism" modifier="-2"/>
<skill name="magic" modifier="-1"/>
<skill name="training" modifier="-1"/>
<skill name="armorer" modifier="1"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="sailing" modifier="-1"/>
<skill name="espionage" modifier="-1"/>
<skill name="quarrying" modifier="1"/>
<skill name="tactics" modifier="1"/>
<skill name="entertainment" modifier="-2"/>
<skill name="weaponsmithing" modifier="2"/>
<skill name="cartmaking" modifier="-1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5"/>
<familiar race="goblin" default="yes"/>
<familiar race="ghost"/>
<familiar race="imp"/>
<familiar race="rat"/>
<familiar race="wolf"/>
<familiar race="demon"/>
</race>

View File

@ -1,32 +1,32 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="troll" magres="0.100000" maxaura="1.000000" regaura="1.000000" recruitcost="90" maintenance="10" weight="2000" capacity="1080" speed="1.000000" hp="30" ac="1" damage="1d5+3" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="2"/>
<skill name="bow" modifier="-2"/>
<skill name="building" modifier="2"/>
<skill name="catapult" modifier="2"/>
<skill name="herbalism" modifier="-1"/>
<skill name="training" modifier="-1"/>
<skill name="riding" modifier="-2"/>
<skill name="armorer" modifier="2"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-1"/>
<skill name="espionage" modifier="-3"/>
<skill name="quarrying" modifier="2"/>
<skill name="roadwork" modifier="2"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="-3"/>
<skill name="entertainment" modifier="-1"/>
<skill name="perception" modifier="-1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5+3"/>
<familiar race="tunnelworm" default="yes"/>
<familiar race="rat"/>
<familiar race="rat"/>
<familiar race="eagle"/>
<familiar race="tunnelworm"/>
<familiar race="wolf"/>
</race>
<?xml version="1.0" encoding="iso-8859-1" ?>
<race name="troll" magres="0.100000" maxaura="1.000000" regaura="1.000000" recruitcost="90" maintenance="10" weight="2000" capacity="1080" speed="1.000000" hp="30" ac="1" damage="1d5+3" unarmedattack="-2" unarmeddefense="-2" playerrace="yes" walk="yes" giveitem="yes" giveperson="yes" giveunit="yes" getitem="yes" equipment="yes">
<ai splitsize="10000" moverandom="yes" learn="yes"/>
<function name="itemdrop" value="defaultdrops"/>
<skill name="mining" modifier="2"/>
<skill name="bow" modifier="-2"/>
<skill name="building" modifier="2"/>
<skill name="catapult" modifier="2"/>
<skill name="herbalism" modifier="-1"/>
<skill name="training" modifier="-1"/>
<skill name="riding" modifier="-2"/>
<skill name="armorer" modifier="2"/>
<skill name="shipcraft" modifier="-1"/>
<skill name="melee" modifier="1"/>
<skill name="sailing" modifier="-1"/>
<skill name="espionage" modifier="-3"/>
<skill name="quarrying" modifier="2"/>
<skill name="roadwork" modifier="2"/>
<skill name="tactics" modifier="-1"/>
<skill name="stealth" modifier="-3"/>
<skill name="entertainment" modifier="-1"/>
<skill name="perception" modifier="-1"/>
<skill name="taxation" modifier="1"/>
<skill name="unarmed" modifier="-99"/>
<attack type="1" damage="1d5+3"/>
<familiar race="tunnelworm" default="yes"/>
<familiar race="rat"/>
<familiar race="rat"/>
<familiar race="eagle"/>
<familiar race="tunnelworm"/>
<familiar race="wolf"/>
</race>

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<ships xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="ships/boat.xml"/>
</ships>
<?xml version="1.0" encoding="iso-8859-1" ?>
<ships xmlns:xi="http://www.w3.org/2001/XInclude">
<xi:include href="ships/boat.xml"/>
</ships>

View File

@ -1,18 +1,18 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<ship name="boat" range="2" storm="1.00" damage="1.00" cargo="5000" cptskill="1" minskill="1" sumskill="2" opensea="yes">
<coast terrain="ocean"/>
<coast terrain="plain"/>
<coast terrain="swamp"/>
<coast terrain="desert"/>
<coast terrain="highland"/>
<coast terrain="mountain"/>
<coast terrain="glacier"/>
<coast terrain="volcano"/>
<coast terrain="activevolcano"/>
<coast terrain="iceberg_sleep"/>
<coast terrain="iceberg"/>
<construction skill="shipcraft" minskill="1" maxsize="5" reqsize="1">
<requirement type="log" quantity="1"/>
</construction>
</ship>
<?xml version="1.0" encoding="iso-8859-1" ?>
<ship name="boat" range="2" storm="1.00" damage="1.00" cargo="5000" cptskill="1" minskill="1" sumskill="2" opensea="yes">
<coast terrain="ocean"/>
<coast terrain="plain"/>
<coast terrain="swamp"/>
<coast terrain="desert"/>
<coast terrain="highland"/>
<coast terrain="mountain"/>
<coast terrain="glacier"/>
<coast terrain="volcano"/>
<coast terrain="activevolcano"/>
<coast terrain="iceberg_sleep"/>
<coast terrain="iceberg"/>
<construction skill="shipcraft" minskill="1" maxsize="5" reqsize="1">
<requirement type="log" quantity="1"/>
</construction>
</ship>

View File

@ -1,166 +1,166 @@
<?xml version="1.0" encoding="iso-8859-1" ?>
<spells>
<!-- draig spells -->
<spell name="create_roi" type="draig" ship="true" rank="5" level="6" index="130">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#draig" type="draig" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="draig" ship="true" rank="5" level="6" index="125">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_firesword" type="draig" ship="true" rank="5" level="12" index="148">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="p10" amount="1" cost="fixed"/>
<resource name="sword" amount="1" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_trollbelt" type="draig" ship="true" rank="5" level="9" index="48">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="20" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<!-- gwyrrd spells -->
<spell name="create_roi" type="gwyrrd" ship="true" rank="5" level="6" index="129">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#gwyrrd" type="gwyrrd" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="gwyrrd" ship="true" rank="5" level="6" index="124">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_magicherbbag" type="gwyrrd" ship="true" rank="5" level="5" index="165">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="30" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="p2" amount="1" cost="fixed"/>
</spell>
<!-- illaun spells -->
<spell name="create_roi" type="illaun" ship="true" rank="5" level="6" index="131">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#illaun" type="illaun" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="illaun" ship="true" rank="5" level="6" index="126">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_dreameye" type="illaun" ship="true" rank="5" level="14" index="149">
<function name="cast" value="lua_castspell"/>
<resource name="dragonhead" amount="1" cost="fixed"/>
<resource name="permaura" amount="5" cost="fixed"/>
</spell>
<spell name="create_invisibility_sphere" type="illaun" ship="true" rank="5" level="13" index="178">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="150" cost="fixed"/>
<resource name="money" amount="30000" cost="fixed"/>
<resource name="permaura" amount="3" cost="fixed"/>
</spell>
<!-- tybied spells -->
<spell name="create_roi" type="tybied" ship="true" rank="5" level="6" index="133">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#tybied" type="tybied" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="tybied" ship="true" rank="5" level="6" index="128">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_antimagic" type="tybied" ship="true" rank="5" level="7" index="38">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
</spell>
<spell name="create_rop" type="tybied" ship="true" rank="5" level="9" index="1">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="4000" cost="fixed"/>
</spell>
<spell name="create_bagofholding" type="tybied" ship="true" rank="5" level="10" index="155">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="30" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="5000" cost="fixed"/>
</spell>
<!-- gray magic -->
<spell name="create_runesword" type="gray" ship="true" rank="5" level="6" index="135">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="1000" cost="fixed"/>
<resource name="laensword" amount="1" cost="fixed"/>
</spell>
<spell name="create_chastitybelt" type="gray" ship="true" rank="5" level="7" index="134">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
</spell>
<spell name="create_focus" type="gray" ship="true" rank="5" level="9" index="2">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_ror" type="gray" ship="true" rank="5" level="9" index="3">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
</spells>
<?xml version="1.0" encoding="iso-8859-1" ?>
<spells>
<!-- draig spells -->
<spell name="create_roi" type="draig" ship="true" rank="5" level="6" index="130">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#draig" type="draig" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="draig" ship="true" rank="5" level="6" index="125">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_firesword" type="draig" ship="true" rank="5" level="12" index="148">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="p10" amount="1" cost="fixed"/>
<resource name="sword" amount="1" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_trollbelt" type="draig" ship="true" rank="5" level="9" index="48">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="20" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<!-- gwyrrd spells -->
<spell name="create_roi" type="gwyrrd" ship="true" rank="5" level="6" index="129">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#gwyrrd" type="gwyrrd" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="gwyrrd" ship="true" rank="5" level="6" index="124">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_magicherbbag" type="gwyrrd" ship="true" rank="5" level="5" index="165">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="30" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="p2" amount="1" cost="fixed"/>
</spell>
<!-- illaun spells -->
<spell name="create_roi" type="illaun" ship="true" rank="5" level="6" index="131">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#illaun" type="illaun" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="illaun" ship="true" rank="5" level="6" index="126">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_dreameye" type="illaun" ship="true" rank="5" level="14" index="149">
<function name="cast" value="lua_castspell"/>
<resource name="dragonhead" amount="1" cost="fixed"/>
<resource name="permaura" amount="5" cost="fixed"/>
</spell>
<spell name="create_invisibility_sphere" type="illaun" ship="true" rank="5" level="13" index="178">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="150" cost="fixed"/>
<resource name="money" amount="30000" cost="fixed"/>
<resource name="permaura" amount="3" cost="fixed"/>
</spell>
<!-- tybied spells -->
<spell name="create_roi" type="tybied" ship="true" rank="5" level="6" index="133">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="earn_silver#tybied" type="tybied" ship="true" variable="true" rank="5" level="1" index="159">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="1" cost="level"/>
</spell>
<spell name="create_aots" type="tybied" ship="true" rank="5" level="6" index="128">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_antimagic" type="tybied" ship="true" rank="5" level="7" index="38">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
</spell>
<spell name="create_rop" type="tybied" ship="true" rank="5" level="9" index="1">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="4000" cost="fixed"/>
</spell>
<spell name="create_bagofholding" type="tybied" ship="true" rank="5" level="10" index="155">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="30" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="5000" cost="fixed"/>
</spell>
<!-- gray magic -->
<spell name="create_runesword" type="gray" ship="true" rank="5" level="6" index="135">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="1000" cost="fixed"/>
<resource name="laensword" amount="1" cost="fixed"/>
</spell>
<spell name="create_chastitybelt" type="gray" ship="true" rank="5" level="7" index="134">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="50" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
<resource name="money" amount="3000" cost="fixed"/>
</spell>
<spell name="create_focus" type="gray" ship="true" rank="5" level="9" index="2">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
<spell name="create_ror" type="gray" ship="true" rank="5" level="9" index="3">
<function name="cast" value="lua_castspell"/>
<resource name="aura" amount="100" cost="fixed"/>
<resource name="permaura" amount="1" cost="fixed"/>
</spell>
</spells>

View File

@ -1,57 +1,57 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<terrains>
<!-- defaults: walk="yes" sail="yes" fly="yes" shallow="yes" swim="no" forest="no" sea="no" land="yes" forbidden="no" arctic="no" cavalry="no" size="0" -->
<terrain name="ocean" size="100" shallow="no" walk="no" swim="yes" land="no" sea="yes" />
<terrain name="plain" size="4000" road="50" shallow="no" forest="yes" cavalry="yes" seed="3">
<resource name="iron" chance="0.1" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.15" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.01" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="swamp" size="1200" road="75" seed="2">
<resource name="iron" chance="0.02" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.02" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.02" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="desert" size="400" road="100" cavalry="yes" seed="2">
<resource name="iron" chance="0.15" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.25" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.025" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="highland" size="2300" road="100" cavalry="yes" seed="2">
<resource name="iron" chance="0.15" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.25" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.025" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="mountain" size="600" road="250" seed="2">
<resource name="iron" chance="1.0" level="1" base="50" div="50" />
<resource name="stone" chance="1.0" level="1" base="100" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="glacier" size="150" road="250" arctic="yes" seed="2">
<resource name="iron" chance="1.0" level="1" base="3" div="50" />
<resource name="stone" chance="1.0" level="1" base="2" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="iceberg_sleep" size="150" road="250" arctic="yes">
<resource name="iron" chance="0.9" level="1" base="3" div="50" />
<resource name="stone" chance="0.9" level="1" base="2" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="iceberg" size="150" arctic="yes">
<resource name="iron" chance="0.9" level="1" base="3" div="50" />
<resource name="stone" chance="0.9" level="1" base="2" div="100" />
</terrain>
<terrain name="firewall" road="250" land="no" walk="no" sail="no" fly="no" forbidden="yes" />
<terrain name="fog" sail="no" land="no" />
<terrain name="thickfog" forbidden="yes" sail="no" walk="no" fly="no" land="no" />
<terrain name="volcano" size="400" road="250" seed="1">
<resource name="iron" chance="0.5" level="1" base="50" div="50" />
<resource name="stone" chance="0.5" level="1" base="100" div="100" />
<resource name="laen" chance="0.075" level="1" base="4" div="100" />
</terrain>
<terrain name="activevolcano" size="400" road="250">
<resource name="iron" chance="0.5" level="1" base="50" div="50" />
<resource name="stone" chance="0.5" level="1" base="100" div="100" />
<resource name="laen" chance="0.075" level="1" base="4" div="100" />
</terrain>
</terrains>
<?xml version="1.0" encoding="ISO-8859-1"?>
<terrains>
<!-- defaults: walk="yes" sail="yes" fly="yes" shallow="yes" swim="no" forest="no" sea="no" land="yes" forbidden="no" arctic="no" cavalry="no" size="0" -->
<terrain name="ocean" size="100" shallow="no" walk="no" swim="yes" land="no" sea="yes" />
<terrain name="plain" size="4000" road="50" shallow="no" forest="yes" cavalry="yes" seed="3">
<resource name="iron" chance="0.1" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.15" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.01" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="swamp" size="1200" road="75" seed="2">
<resource name="iron" chance="0.02" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.02" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.02" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="desert" size="400" road="100" cavalry="yes" seed="2">
<resource name="iron" chance="0.15" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.25" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.025" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="highland" size="2300" road="100" cavalry="yes" seed="2">
<resource name="iron" chance="0.15" level="2d4-1" base="5d8" div="2d20+10" />
<resource name="stone" chance="0.25" level="1d4" base="5d8" div="2d30+20" />
<resource name="laen" chance="0.025" level="1d4" base="1d4" div="2d20+50" />
</terrain>
<terrain name="mountain" size="600" road="250" seed="2">
<resource name="iron" chance="1.0" level="1" base="50" div="50" />
<resource name="stone" chance="1.0" level="1" base="100" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="glacier" size="150" road="250" arctic="yes" seed="2">
<resource name="iron" chance="1.0" level="1" base="3" div="50" />
<resource name="stone" chance="1.0" level="1" base="2" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="iceberg_sleep" size="150" road="250" arctic="yes">
<resource name="iron" chance="0.9" level="1" base="3" div="50" />
<resource name="stone" chance="0.9" level="1" base="2" div="100" />
<resource name="laen" chance="0.05" level="1" base="4" div="100" />
</terrain>
<terrain name="iceberg" size="150" arctic="yes">
<resource name="iron" chance="0.9" level="1" base="3" div="50" />
<resource name="stone" chance="0.9" level="1" base="2" div="100" />
</terrain>
<terrain name="firewall" road="250" land="no" walk="no" sail="no" fly="no" forbidden="yes" />
<terrain name="fog" sail="no" land="no" />
<terrain name="thickfog" forbidden="yes" sail="no" walk="no" fly="no" land="no" />
<terrain name="volcano" size="400" road="250" seed="1">
<resource name="iron" chance="0.5" level="1" base="50" div="50" />
<resource name="stone" chance="0.5" level="1" base="100" div="100" />
<resource name="laen" chance="0.075" level="1" base="4" div="100" />
</terrain>
<terrain name="activevolcano" size="400" road="250">
<resource name="iron" chance="0.5" level="1" base="50" div="50" />
<resource name="stone" chance="0.5" level="1" base="100" div="100" />
<resource name="laen" chance="0.075" level="1" base="4" div="100" />
</terrain>
</terrains>

View File

@ -1,25 +1,25 @@
<?xml version="1.0"?>
<resources xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- this file contains a lot of weapons -->
<xi:include href="eressea:///core/weapons/axe.xml"/>
<xi:include href="eressea:///core/weapons/bow.xml"/>
<xi:include href="eressea:///core/weapons/catapult.xml"/>
<xi:include href="eressea:///core/weapons/crossbow.xml"/>
<xi:include href="eressea:///core/weapons/firesword.xml"/>
<xi:include href="eressea:///core/weapons/greatbow.xml"/>
<xi:include href="eressea:///core/weapons/greatsword.xml"/>
<xi:include href="eressea:///core/weapons/halberd.xml"/>
<xi:include href="eressea:///core/weapons/laensword.xml"/>
<xi:include href="eressea:///core/weapons/lance.xml"/>
<xi:include href="eressea:///core/weapons/mallornbow.xml"/>
<xi:include href="eressea:///core/weapons/mallorncrossbow.xml"/>
<xi:include href="eressea:///core/weapons/mallornlance.xml"/>
<xi:include href="eressea:///core/weapons/mallornspear.xml"/>
<xi:include href="eressea:///core/weapons/runesword.xml"/>
<xi:include href="eressea:///core/weapons/rustyaxe.xml"/>
<xi:include href="eressea:///core/weapons/rustygreatsword.xml"/>
<xi:include href="eressea:///core/weapons/rustyhalberd.xml"/>
<xi:include href="eressea:///core/weapons/rustysword.xml"/>
<xi:include href="eressea:///core/weapons/spear.xml"/>
<xi:include href="eressea:///core/weapons/sword.xml"/>
</resources>
<?xml version="1.0"?>
<resources xmlns:xi="http://www.w3.org/2001/XInclude">
<!-- this file contains a lot of weapons -->
<xi:include href="eressea:///core/weapons/axe.xml"/>
<xi:include href="eressea:///core/weapons/bow.xml"/>
<xi:include href="eressea:///core/weapons/catapult.xml"/>
<xi:include href="eressea:///core/weapons/crossbow.xml"/>
<xi:include href="eressea:///core/weapons/firesword.xml"/>
<xi:include href="eressea:///core/weapons/greatbow.xml"/>
<xi:include href="eressea:///core/weapons/greatsword.xml"/>
<xi:include href="eressea:///core/weapons/halberd.xml"/>
<xi:include href="eressea:///core/weapons/laensword.xml"/>
<xi:include href="eressea:///core/weapons/lance.xml"/>
<xi:include href="eressea:///core/weapons/mallornbow.xml"/>
<xi:include href="eressea:///core/weapons/mallorncrossbow.xml"/>
<xi:include href="eressea:///core/weapons/mallornlance.xml"/>
<xi:include href="eressea:///core/weapons/mallornspear.xml"/>
<xi:include href="eressea:///core/weapons/runesword.xml"/>
<xi:include href="eressea:///core/weapons/rustyaxe.xml"/>
<xi:include href="eressea:///core/weapons/rustygreatsword.xml"/>
<xi:include href="eressea:///core/weapons/rustyhalberd.xml"/>
<xi:include href="eressea:///core/weapons/rustysword.xml"/>
<xi:include href="eressea:///core/weapons/spear.xml"/>
<xi:include href="eressea:///core/weapons/sword.xml"/>
</resources>

View File

@ -1,50 +1,50 @@
-- Enno was here
require "multis"
function process(orders)
local confirmed_multis = { }
local suspected_multis = { }
if open_game(get_turn())~=0 then
print("could not read game")
return -1
end
init_summary()
-- kill multi-players (external script)
kill_multis(confirmed_multis, false)
mark_multis(suspected_multis, false)
-- run the turn:
if read_orders(orders) ~= 0 then
print("could not read " .. orders)
return -1
end
-- plan_monsters()
if nmr_check(config.maxnmrs or 80)~=0 then
return -1
end
process_orders()
-- create new monsters:
spawn_braineaters(0.25)
-- post-turn updates:
update_guards()
update_scores()
local localechange = { de = { "ii" } }
change_locales(localechange)
write_files(config.locales)
file = "" .. get_turn() .. ".dat"
if write_game(file, "binary")~=0 then
print("could not write game")
return -1
end
return 0
end
-- Enno was here
require "multis"
function process(orders)
local confirmed_multis = { }
local suspected_multis = { }
if open_game(get_turn())~=0 then
print("could not read game")
return -1
end
init_summary()
-- kill multi-players (external script)
kill_multis(confirmed_multis, false)
mark_multis(suspected_multis, false)
-- run the turn:
if read_orders(orders) ~= 0 then
print("could not read " .. orders)
return -1
end
-- plan_monsters()
if nmr_check(config.maxnmrs or 80)~=0 then
return -1
end
process_orders()
-- create new monsters:
spawn_braineaters(0.25)
-- post-turn updates:
update_guards()
update_scores()
local localechange = { de = { "ii" } }
change_locales(localechange)
write_files(config.locales)
file = "" .. get_turn() .. ".dat"
if write_game(file, "binary")~=0 then
print("could not write game")
return -1
end
return 0
end

View File

@ -1,6 +1,6 @@
require "example.rules"
local srcpath = config.source_dir
tests = {
srcpath .. '/server/scripts/tests/common.lua',
}
require "example.rules"
local srcpath = config.source_dir
tests = {
srcpath .. '/server/scripts/tests/common.lua',
}

View File

@ -1,8 +1,8 @@
function item_canuse(u, iname)
local race = u.race
if iname=="greatbow" then
-- only elves use greatbow
return race=="elf"
end
return true
end
function item_canuse(u, iname)
local race = u.race
if iname=="greatbow" then
-- only elves use greatbow
return race=="elf"
end
return true
end

View File

@ -1,171 +1,171 @@
/*
Copyright (c) 1998-2010, Enno Rehling <enno@eressea.de>
Katja Zedel <katze@felidae.kn-bremen.de
Christian Schlittchen <corwin@amber.kn-bremen.de>
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
**/
#include <platform.h>
#include <util/log.h>
#include <kernel/types.h>
#include <eressea.h>
#include <gmtool.h>
#include <kernel/config.h>
#include <kernel/save.h>
#include <iniparser/iniparser.h>
#include <assert.h>
#include <locale.h>
#include <wctype.h>
#include <tests.h>
static const char * luafile = "setup.lua";
static const char * entry_point = NULL;
static const char * inifile = "eressea.ini";
static int memdebug = 0;
static void parse_config(const char * filename)
{
dictionary * d = iniparser_new(filename);
if (d) {
load_inifile(d);
memdebug = iniparser_getint(d, "eressea:memcheck", memdebug);
entry_point = iniparser_getstring(d, "eressea:run", entry_point);
luafile = iniparser_getstring(d, "eressea:load", luafile);
/* only one value in the [editor] section */
force_color = iniparser_getint(d, "editor:color", force_color);
}
global.inifile = d;
}
static int
usage(const char * prog, const char * arg)
{
if (arg) {
fprintf(stderr, "unknown argument: %s\n\n", arg);
}
fprintf(stderr, "Usage: %s [options]\n"
"-t <turn> : read this datafile, not the most current one\n"
"-q : be quite (same as -v 0)\n"
"-v <level> : verbosity level\n"
"-C : run in interactive mode\n"
"--color : force curses to use colors even when not detected\n"
"--tests : run test suite\n"
"--help : help\n", prog);
return -1;
}
static int
parse_args(int argc, char **argv, int * exitcode)
{
int i, run_tests = 0;
for (i=1;i!=argc;++i) {
if (argv[i][0]!='-') {
return usage(argv[0], argv[i]);
} else if (argv[i][1]=='-') { /* long format */
if (strcmp(argv[i]+2, "version")==0) {
printf("\n%s PBEM host\n"
"Copyright (C) 1996-2005 C. Schlittchen, K. Zedel, E. Rehling, H. Peters.\n\n"
"Compilation: " __DATE__ " at " __TIME__ "\nVersion: %f\n\n", global.gamename, version());
}
else if (strcmp(argv[i]+2, "color")==0) {
/* force the editor to have colors */
force_color = 1;
}
else if (strcmp(argv[i]+2, "help")==0) {
return usage(argv[0], NULL);
}
else if (strcmp(argv[i]+2, "tests")==0) {
run_tests = 1;
}
else {
return usage(argv[0], argv[i]);
}
} else switch(argv[i][1]) {
case 'C':
entry_point = NULL;
break;
case 'e':
entry_point = argv[++i];
break;
case 't':
turn = atoi(argv[++i]);
break;
case 'q':
verbosity = 0;
break;
case 'v':
verbosity = atoi(argv[++i]);
break;
case 'h':
usage(argv[0], NULL);
return 1;
default:
*exitcode = -1;
usage(argv[0], argv[i]);
return 1;
}
}
if (run_tests) {
*exitcode = RunAllTests();
return 1;
}
return 0;
}
void locale_init(void)
{
setlocale(LC_CTYPE, "");
setlocale(LC_NUMERIC, "C");
assert(towlower(0xC4)==0xE4); /* &Auml; => &auml; */
}
int main(int argc, char ** argv)
{
int err, result = 0;
parse_config(inifile);
log_open("eressea.log");
locale_init();
err = parse_args(argc, argv, &result);
if (err) {
return result;
}
err = eressea_init();
if (err) {
log_error(("initialization failed with code %d\n", err));
return err;
}
err = eressea_run(luafile, entry_point);
if (err) {
log_error(("server execution failed with code %d\n", err));
return err;
}
eressea_done();
log_close();
return 0;
}
/*
Copyright (c) 1998-2010, Enno Rehling <enno@eressea.de>
Katja Zedel <katze@felidae.kn-bremen.de
Christian Schlittchen <corwin@amber.kn-bremen.de>
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
**/
#include <platform.h>
#include <util/log.h>
#include <kernel/types.h>
#include <eressea.h>
#include <gmtool.h>
#include <kernel/config.h>
#include <kernel/save.h>
#include <iniparser/iniparser.h>
#include <assert.h>
#include <locale.h>
#include <wctype.h>
#include <tests.h>
static const char * luafile = "setup.lua";
static const char * entry_point = NULL;
static const char * inifile = "eressea.ini";
static int memdebug = 0;
static void parse_config(const char * filename)
{
dictionary * d = iniparser_new(filename);
if (d) {
load_inifile(d);
memdebug = iniparser_getint(d, "eressea:memcheck", memdebug);
entry_point = iniparser_getstring(d, "eressea:run", entry_point);
luafile = iniparser_getstring(d, "eressea:load", luafile);
/* only one value in the [editor] section */
force_color = iniparser_getint(d, "editor:color", force_color);
}
global.inifile = d;
}
static int
usage(const char * prog, const char * arg)
{
if (arg) {
fprintf(stderr, "unknown argument: %s\n\n", arg);
}
fprintf(stderr, "Usage: %s [options]\n"
"-t <turn> : read this datafile, not the most current one\n"
"-q : be quite (same as -v 0)\n"
"-v <level> : verbosity level\n"
"-C : run in interactive mode\n"
"--color : force curses to use colors even when not detected\n"
"--tests : run test suite\n"
"--help : help\n", prog);
return -1;
}
static int
parse_args(int argc, char **argv, int * exitcode)
{
int i, run_tests = 0;
for (i=1;i!=argc;++i) {
if (argv[i][0]!='-') {
return usage(argv[0], argv[i]);
} else if (argv[i][1]=='-') { /* long format */
if (strcmp(argv[i]+2, "version")==0) {
printf("\n%s PBEM host\n"
"Copyright (C) 1996-2005 C. Schlittchen, K. Zedel, E. Rehling, H. Peters.\n\n"
"Compilation: " __DATE__ " at " __TIME__ "\nVersion: %f\n\n", global.gamename, version());
}
else if (strcmp(argv[i]+2, "color")==0) {
/* force the editor to have colors */
force_color = 1;
}
else if (strcmp(argv[i]+2, "help")==0) {
return usage(argv[0], NULL);
}
else if (strcmp(argv[i]+2, "tests")==0) {
run_tests = 1;
}
else {
return usage(argv[0], argv[i]);
}
} else switch(argv[i][1]) {
case 'C':
entry_point = NULL;
break;
case 'e':
entry_point = argv[++i];
break;
case 't':
turn = atoi(argv[++i]);
break;
case 'q':
verbosity = 0;
break;
case 'v':
verbosity = atoi(argv[++i]);
break;
case 'h':
usage(argv[0], NULL);
return 1;
default:
*exitcode = -1;
usage(argv[0], argv[i]);
return 1;
}
}
if (run_tests) {
*exitcode = RunAllTests();
return 1;
}
return 0;
}
void locale_init(void)
{
setlocale(LC_CTYPE, "");
setlocale(LC_NUMERIC, "C");
assert(towlower(0xC4)==0xE4); /* &Auml; => &auml; */
}
int main(int argc, char ** argv)
{
int err, result = 0;
parse_config(inifile);
log_open("eressea.log");
locale_init();
err = parse_args(argc, argv, &result);
if (err) {
return result;
}
err = eressea_init();
if (err) {
log_error(("initialization failed with code %d\n", err));
return err;
}
err = eressea_run(luafile, entry_point);
if (err) {
log_error(("server execution failed with code %d\n", err));
return err;
}
eressea_done();
log_close();
return 0;
}

View File

@ -1,3 +1,3 @@
#include "stdafx.h"
#include "main.c"
#include "tests.c"
#include "stdafx.h"
#include "main.c"
#include "tests.c"