Page 1 of 1

LuaEntity::order_deconstruction() player parameter

Posted: Wed Dec 27, 2017 11:31 am
by mickael9
Currently, we have LuaTile::order_deconstruction(force, player) and LuaEntity::order_deconstruction(force).
Can we have LuaEntity::order_deconstruction(force, player) too so that the player index appears in the generated event?

Re: LuaEntity::order_deconstruction() player parameter

Posted: Wed Dec 27, 2017 9:07 pm
by Rseding91
Ok, I've added it for the next version of 0.16.

Re: LuaEntity::order_deconstruction() player parameter

Posted: Thu Dec 28, 2017 12:51 am
by mickael9
I guess those should be changed too then:
  • LuaSurface::deconstruct_area
  • LuaSurface::cancel_deconstruct_area
  • LuaEntity::cancel_deconstruction
  • LuaTile::cancel_deconstruction
Edit: perhaps the force parameter ought to be passed to the on_marked_for_deconstruction and on_canceled_deconstruction events as well?