1
0
mirror of https://github.com/moparisthebest/minetest synced 2024-11-17 23:05:07 -05:00

Rollback: Fail on bad precondition instead of causing assertion error

This commit is contained in:
kwolekr 2015-08-15 14:45:44 -04:00
parent 7238df4c59
commit 0ba1cf8203

View File

@ -210,6 +210,7 @@ bool RollbackAction::applyRevert(Map *map, InventoryManager *imgr, IGameDef *gam
<< inventory_index << " too large in " << inventory_index << " too large in "
<< "inventory list \"" << inventory_list << "\" in " << "inventory list \"" << inventory_list << "\" in "
<< inventory_location << std::endl; << inventory_location << std::endl;
return false;
} }
// If item was added, take away item, otherwise add removed item // If item was added, take away item, otherwise add removed item
if (inventory_add) { if (inventory_add) {