forked from github/server
no starting equipment.
do not let the addplayer function give equipment. rename equipment for autoseed.
This commit is contained in:
parent
847cfb5425
commit
d3d72d17e8
|
@ -42,7 +42,7 @@
|
||||||
<skill name="perception" level="30"/>
|
<skill name="perception" level="30"/>
|
||||||
<skill name="melee" level="1"/>
|
<skill name="melee" level="1"/>
|
||||||
</set>
|
</set>
|
||||||
<set name="new_faction">
|
<set name="autoseed_faction">
|
||||||
<item name="adamantium" amount="1"/>
|
<item name="adamantium" amount="1"/>
|
||||||
</set>
|
</set>
|
||||||
</equipment>
|
</equipment>
|
||||||
|
|
|
@ -28,14 +28,6 @@
|
||||||
|
|
||||||
<calendar name="thirdage" newyear="month_1" start="1"/>
|
<calendar name="thirdage" newyear="month_1" start="1"/>
|
||||||
|
|
||||||
<equipment>
|
|
||||||
<set name="first_unit">
|
|
||||||
<item name="log" amount="10"/>
|
|
||||||
<item name="stone" amount="10"/>
|
|
||||||
<item name="money" amount="5000"/>
|
|
||||||
</set>
|
|
||||||
</equipment>
|
|
||||||
|
|
||||||
<xi:include href="config://default/names-undead.xml"/>
|
<xi:include href="config://default/names-undead.xml"/>
|
||||||
<xi:include href="config://default/names-skeletons.xml"/>
|
<xi:include href="config://default/names-skeletons.xml"/>
|
||||||
<xi:include href="config://default/names-zombies.xml"/>
|
<xi:include href="config://default/names-zombies.xml"/>
|
||||||
|
|
|
@ -27,15 +27,6 @@
|
||||||
<xi:include href="config://game/resources.xml" />
|
<xi:include href="config://game/resources.xml" />
|
||||||
|
|
||||||
<calendar name="thirdage" newyear="month_1" start="1"/>
|
<calendar name="thirdage" newyear="month_1" start="1"/>
|
||||||
|
|
||||||
<equipment>
|
|
||||||
<set name="first_unit">
|
|
||||||
<item name="log" amount="10"/>
|
|
||||||
<item name="stone" amount="10"/>
|
|
||||||
<item name="money" amount="5000"/>
|
|
||||||
</set>
|
|
||||||
</equipment>
|
|
||||||
|
|
||||||
<xi:include href="config://default/names-undead.xml"/>
|
<xi:include href="config://default/names-undead.xml"/>
|
||||||
<xi:include href="config://default/names-skeletons.xml"/>
|
<xi:include href="config://default/names-skeletons.xml"/>
|
||||||
<xi:include href="config://default/names-zombies.xml"/>
|
<xi:include href="config://default/names-zombies.xml"/>
|
||||||
|
|
|
@ -2,18 +2,18 @@
|
||||||
<equipment>
|
<equipment>
|
||||||
|
|
||||||
<!-- one equipment-set per player-race for the first unit in a faction -->
|
<!-- one equipment-set per player-race for the first unit in a faction -->
|
||||||
<set name="first_dwarf">
|
<set name="autoseed_dwarf">
|
||||||
<item name="axe" amount="1"/>
|
<item name="axe" amount="1"/>
|
||||||
<item name="chainmail" amount="1"/>
|
<item name="chainmail" amount="1"/>
|
||||||
<skill name="melee" level="1"/>
|
<skill name="melee" level="1"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_elf">
|
<set name="autoseed_elf">
|
||||||
<item name="fairyboot" amount="1"/>
|
<item name="fairyboot" amount="1"/>
|
||||||
<callback name="equip_newunits"/>
|
<callback name="equip_newunits"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_orc">
|
<set name="autoseed_orc">
|
||||||
<skill name="polearm" level="4"/>
|
<skill name="polearm" level="4"/>
|
||||||
<skill name="melee" level="4"/>
|
<skill name="melee" level="4"/>
|
||||||
<skill name="crossbow" level="4"/>
|
<skill name="crossbow" level="4"/>
|
||||||
|
@ -21,30 +21,30 @@
|
||||||
<skill name="bow" level="4"/>
|
<skill name="bow" level="4"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_goblin">
|
<set name="autoseed_goblin">
|
||||||
<item name="roi" amount="1"/>
|
<item name="roi" amount="1"/>
|
||||||
<callback name="equip_newunits"/>
|
<callback name="equip_newunits"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_human">
|
<set name="autoseed_human">
|
||||||
<callback name="equip_newunits"/>
|
<callback name="equip_newunits"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_troll">
|
<set name="autoseed_troll">
|
||||||
<skill name="building" level="1"/>
|
<skill name="building" level="1"/>
|
||||||
<skill name="perception" level="3"/>
|
<skill name="perception" level="3"/>
|
||||||
<item name="stone" amount="50"/>
|
<item name="stone" amount="50"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_demon">
|
<set name="autoseed_demon">
|
||||||
<skill name="stamina" level="15"/>
|
<skill name="stamina" level="15"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_insect">
|
<set name="autoseed_insect">
|
||||||
<item name="nestwarmth" amount="9"/>
|
<item name="nestwarmth" amount="9"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_halfling">
|
<set name="autoseed_halfling">
|
||||||
<skill name="trade" level="1"/>
|
<skill name="trade" level="1"/>
|
||||||
<skill name="riding" level="2"/>
|
<skill name="riding" level="2"/>
|
||||||
<item name="horse" amount="2"/>
|
<item name="horse" amount="2"/>
|
||||||
|
@ -58,12 +58,12 @@
|
||||||
<item name="incense" amount="5"/>
|
<item name="incense" amount="5"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_cat">
|
<set name="autoseed_cat">
|
||||||
<item name="roi" amount="1"/>
|
<item name="roi" amount="1"/>
|
||||||
<callback name="equip_newunits"/>
|
<callback name="equip_newunits"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
||||||
<set name="first_aquarian">
|
<set name="autoseed_aquarian">
|
||||||
<skill name="sailing" level="1"/>
|
<skill name="sailing" level="1"/>
|
||||||
<callback name="equip_newunits"/>
|
<callback name="equip_newunits"/>
|
||||||
</set>
|
</set>
|
||||||
|
|
|
@ -64,9 +64,9 @@ local function seed(r, email, race, lang)
|
||||||
assert(f)
|
assert(f)
|
||||||
local u = unit.create(f, r)
|
local u = unit.create(f, r)
|
||||||
assert(u)
|
assert(u)
|
||||||
equip_unit(u, "new_faction")
|
equip_unit(u, "autoseed_faction")
|
||||||
equip_unit(u, "first_unit")
|
equip_unit(u, "autoseed_unit")
|
||||||
equip_unit(u, "first_" .. race, 7) -- disable old callbacks
|
equip_unit(u, "autoseed_" .. race, 7)
|
||||||
unit.create(f, r, 5):set_skill("mining", 30)
|
unit.create(f, r, 5):set_skill("mining", 30)
|
||||||
unit.create(f, r, 5):set_skill("quarrying", 30)
|
unit.create(f, r, 5):set_skill("quarrying", 30)
|
||||||
f:set_origin(r)
|
f:set_origin(r)
|
||||||
|
|
|
@ -22,7 +22,6 @@ OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||||
#include "alliance.h"
|
#include "alliance.h"
|
||||||
#include "ally.h"
|
#include "ally.h"
|
||||||
#include "curse.h"
|
#include "curse.h"
|
||||||
#include "equipment.h"
|
|
||||||
#include "group.h"
|
#include "group.h"
|
||||||
#include "item.h"
|
#include "item.h"
|
||||||
#include "messages.h"
|
#include "messages.h"
|
||||||
|
@ -286,15 +285,10 @@ faction *addfaction(const char *email, const char *password,
|
||||||
unit *addplayer(region * r, faction * f)
|
unit *addplayer(region * r, faction * f)
|
||||||
{
|
{
|
||||||
unit *u;
|
unit *u;
|
||||||
char buffer[32];
|
|
||||||
|
|
||||||
assert(f->units == NULL);
|
assert(f->units == NULL);
|
||||||
faction_setorigin(f, 0, r->x, r->y);
|
faction_setorigin(f, 0, r->x, r->y);
|
||||||
u = create_unit(r, f, 1, f->race, 0, NULL, NULL);
|
u = create_unit(r, f, 1, f->race, 0, NULL, NULL);
|
||||||
equip_items(&u->faction->items, get_equipment("new_faction"));
|
|
||||||
equip_unit(u, get_equipment("first_unit"));
|
|
||||||
sprintf(buffer, "first_%s", u_race(u)->_name);
|
|
||||||
equip_unit(u, get_equipment(buffer));
|
|
||||||
u->hp = unit_max_hp(u) * u->number;
|
u->hp = unit_max_hp(u) * u->number;
|
||||||
fset(u, UFL_ISNEW);
|
fset(u, UFL_ISNEW);
|
||||||
if (f->race == get_race(RC_DAEMON)) {
|
if (f->race == get_race(RC_DAEMON)) {
|
||||||
|
|
Loading…
Reference in New Issue