forked from github/server
bugfix: schiffsbau mit schaffenstrunk
This commit is contained in:
parent
2edb0c7100
commit
9fbe85c618
|
@ -899,12 +899,13 @@ build_ship(unit * u, ship * sh, int want)
|
|||
{
|
||||
const construction * construction = sh->type->construction;
|
||||
int size = (sh->size * DAMAGE_SCALE - sh->damage) / DAMAGE_SCALE;
|
||||
int can = u->number * effskill(u, SK_SHIPBUILDING) / construction->minskill;
|
||||
int n;
|
||||
|
||||
#if 0
|
||||
int can = u->number * effskill(u, SK_SHIPBUILDING) / construction->minskill;
|
||||
if (want > 0) can = min(want, can);
|
||||
can = min(can, construction->maxsize+sh->damage); /* 100% bauen + 100% reparieren */
|
||||
can = build(u, construction, size, can);
|
||||
#endif
|
||||
int can = build(u, construction, size, want);
|
||||
|
||||
if ((n=construction->maxsize - sh->size)>0 && can>0) {
|
||||
if (can>=n) {
|
||||
|
|
Loading…
Reference in New Issue