Code for brick game