Merge branch 'develop' of github.com:ennorehling/eressea into develop

This commit is contained in:
Enno Rehling 2020-03-28 09:36:48 +01:00
commit edf154f4c7
6 changed files with 13 additions and 6 deletions

2
.gitignore vendored
View File

@ -46,5 +46,5 @@ tests/data/185.dat
/cutest/ /cutest/
/critbit/ /critbit/
*.mo *.mo
/CMakeSettings.json
/.vs /.vs
/CMakeSettings.json

View File

@ -17,8 +17,6 @@ fi
cd "$GAME/reports" || exit cd "$GAME/reports" || exit
for REPORT in *.sh for REPORT in *.sh
do do
echo -n "Sending "
basename "$REPORT" .sh
bash "$REPORT" bash "$REPORT"
done done
cd - || exit cd - || exit

View File

@ -6,6 +6,10 @@ local function equip_first(u)
equip_unit(u, name, 255) equip_unit(u, name, 255)
end end
local function equip_demon(u)
u.race_name = 'human'
end
local mysets = { local mysets = {
['first_unit'] = { ['first_unit'] = {
['items'] = { ['items'] = {
@ -77,7 +81,8 @@ local mysets = {
['seed_demon'] = { ['seed_demon'] = {
['skills'] = { ['skills'] = {
['stamina'] = 15 ['stamina'] = 15
} },
['callback'] = equip_demon
}, },
['seed_insect'] = { ['seed_insect'] = {
['items'] = { ['items'] = {

View File

@ -258,11 +258,14 @@ unit *addplayer(region * r, faction * f)
const char * name; const char * name;
assert(r->land); assert(r->land);
assert(f->units == NULL);
if (rpeasants(r) < PEASANT_MIN) { if (rpeasants(r) < PEASANT_MIN) {
rsetpeasants(r, PEASANT_MIN + rng_int() % (PEASANT_MAX - PEASANT_MIN)); rsetpeasants(r, PEASANT_MIN + rng_int() % (PEASANT_MAX - PEASANT_MIN));
} }
if (rtrees(r, TREE_TREE) < 50) {
rsettrees(r, TREE_TREE, 50);
}
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);
u->status = ST_FLEE; u->status = ST_FLEE;

View File

@ -8,7 +8,7 @@
#ifndef ERESSEA_VERSION #ifndef ERESSEA_VERSION
/* the version number, if it was not passed to make with -D */ /* the version number, if it was not passed to make with -D */
#define ERESSEA_VERSION "3.23.0" #define ERESSEA_VERSION "3.24.0"
#endif #endif
const char *eressea_version(void) { const char *eressea_version(void) {

View File

@ -223,6 +223,7 @@ char *parse_token(const char **str, char *lbuf, size_t buflen)
} }
*cursor = '\0'; *cursor = '\0';
unicode_utf8_trim(lbuf);
*str = ctoken; *str = ctoken;
return lbuf; return lbuf;
} }