Hello Everyone, I'm new in this forum
I been playing cultris for a while and by far it is simply the BEST tetris game I have ever played.
To be honest, I'm posting here because I have a course project this semester and I have decided to create a basic tetris game.
I'm still a java newbie and I still got much to learn (got an A- last sem in OOP Java -does not qualify me enough to develop games-).
Since I don't have any cutting edge skills, I'd like a developer to help me understand how to move a tetris piece quickly with no long "pause" after the first move on the board. I also need to know how to create the piece shadow that shows where the tetris piece will collide.
I understand that cultris source code is not open to public therefore for educational purposes I will be using the following tutorial that utilizes Java swing for the creation of a tetris clone.
I would be grateful if any person out there could help me understand the concepts or fundamentals of solving the issue I stated above.(and yes I know.....your not my personal army,and no one is forced to help/guide me).
I apologize if my English sounds horrible, I'm a lvl 23 Arabian Human P;
Pause/keys: Instead of the keyPressed event, just handle the keyDown and keyUp events (http://www.java.happycodings.com/Java_AWT/code16.html) and manage the repetitions yourself. Then you're free to use whatever delays you want.
Shadow: Have a look at the dropDown() method. It almost does what you want. By repeatedly calling tryMove you can find out how far the piece can fall.
Other than that:
Thank you very much Simon.
These methods should be sufficient for me.
It's a nice project to learn about threads and swing (and networking if you have a lot of time to make a multiplayer version).
The keyUp/keyDown methods have been deprecated since JDK 1.1. I would use the keyPressed method. It will be called repeatedly if you hold down a key (how often, depends on how it's been configured in the OS).