relax strict assertion (should be allowed to set ocean to 0 peasants)

This commit is contained in:
Enno Rehling 2016-01-24 14:45:46 +01:00
parent 023686fab2
commit a6b15813ed
1 changed files with 6 additions and 3 deletions

View File

@ -605,9 +605,10 @@ int rpeasants(const region * r)
void rsetpeasants(region * r, int value)
{
assert(r->land);
assert(value >= 0);
r->land->peasants = value;
if (r->land) {
r->land->peasants = value;
}
}
int rmoney(const region * r)
@ -617,9 +618,11 @@ int rmoney(const region * r)
void rsethorses(const region * r, int value)
{
assert(r->land || value==0);
assert(value >= 0);
if (r->land)
if (r->land) {
r->land->horses = value;
}
}
int rhorses(const region * r)