Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Just another update

Sign in to follow this  


Well I've figured out how I'm going to make my tetris clone. .. any comments on the way i've chosen to do everything would be appreciated as this is really just the "first" way that came to mind, and probably not the best.

Basically there will be 2D array of 'squares' that represents the play area, and a 'block' which is the falling bit (made up from a number of squares in a certain arrangement)

collision checking (to work out whether the block has reached the squares at the bottom/sides) will simply involve looking ahead to the position it plans to move to and seeing if anything is already there in the play area.

when the block reaches the bottom, the squares from it will be added to the play area..
then all the rows of the play area will be checked to see if any have been completely filled, at which point they will be removed and any rows above will be moved down.
this will continue until the play area gets filled up to the top row, or the level is completed.

Thats pretty much it! very straightforward.
Sign in to follow this  

1 Comment

Recommended Comments

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!