This commit is contained in:
Enno Rehling 2014-08-24 17:11:32 +02:00
commit de5ef3f87b
6 changed files with 20 additions and 15 deletions

View File

@ -1,10 +1,6 @@
<?xml version="1.0"?>
<resources>
<resource name="money">
<item weight="1"/>
</resource>
<resource name="ao_healing" appearance="amulet">
<item weight="0" score="6000"/>
</resource>

3
res/items.xml Normal file
View File

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

View File

@ -1,8 +1,9 @@
#!/bin/bash
s/preview build master
s/preview version
[ -z $ERESSEA ] && ERESSEA=$HOME/eressea
SRC=$ERESSEA/git
$SRC/s/preview build master
$SRC/s/preview version
for game in 2 3 4 ; do
s/preview -g $game run && \
s/preview -g $game send
$SRC/s/preview -g $game run && \
$SRC/s/preview -g $game send
done

View File

@ -2766,7 +2766,7 @@ static void breed_cmd(unit * u, struct order *ord)
(void)init_order(ord);
s = getstrtoken();
m = atoi((const char *)s);
m = s ? atoi((const char *)s) : 0;
if (m != 0) {
/* first came a want-paramter */
s = getstrtoken();
@ -2775,7 +2775,7 @@ static void breed_cmd(unit * u, struct order *ord)
m = INT_MAX;
}
if (!s[0]) {
if (!s || !s[0]) {
p = P_ANY;
}
else {

View File

@ -544,7 +544,8 @@ char *write_order(const order * ord, char *buffer, size_t size)
keyword_t kwd = ORD_KEYWORD(ord);
if (kwd == NOKEYWORD) {
const char *text = ORD_STRING(ord);
strlcpy(buffer, (const char *)text, size);
if (text) strlcpy(buffer, (const char *)text, size);
else buffer[0] = 0;
}
else {
get_command(ord, buffer, size);

View File

@ -3923,10 +3923,14 @@ void defaultorders(void)
order *ord = *ordp;
if (getkeyword(ord) == K_DEFAULT) {
char lbuf[8192];
order *new_order;
order *new_order = 0;
const char *s;
init_order(ord);
strcpy(lbuf, getstrtoken());
s = getstrtoken();
if (s) {
strcpy(lbuf, s);
new_order = parse_order(lbuf, u->faction->locale);
}
*ordp = ord->next;
ord->next = NULL;
free_order(ord);