forked from github/server
parent
5a01eae522
commit
c276b5a43c
|
@ -26,7 +26,7 @@ function test_goblins()
|
|||
for k, v in ipairs(restricted) do
|
||||
u1:add_item(v, 1)
|
||||
u2:add_item(v, 1)
|
||||
u2:add_item(v, 1)
|
||||
u3:add_item(v, 1)
|
||||
end
|
||||
|
||||
u1:add_order("ATTACKIERE " .. itoa36(u2.id))
|
||||
|
|
|
@ -580,7 +580,12 @@ static bool i_canuse(const unit * u, const item_type * itype)
|
|||
if (itype->canuse) {
|
||||
result = itype->canuse(u, itype);
|
||||
}
|
||||
assert(result==rc_can_use(u_race(u), itype));
|
||||
if (result!=rc_can_use(u_race(u), itype)) {
|
||||
log_error("conversion error: %s should be %s to use %s",
|
||||
u->_race->_name,
|
||||
result ? "allowed" : "forbidden",
|
||||
itype->rtype->_name);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue