First batch commit of Platform functionality; fixed several bugs