cleaned up some js
Added level and some server side code to represent the board with some convienience methods