Numerical Simulation of Free-Surface Flow with Moving Rigid Bodies