A new numerical code for hierarchical peeling simulations