The code for Swapshire 2.0