Results 1 to 2 of 2
- 06-07-2012, 04:24 AM #1
Member
- Join Date
- Jun 2012
- Posts
- 1
- Rep Power
- 0
Need to solve this formula for my project
I'm working on modifying a tetris game for my ISU for grade 11 computer science, and I've been stuck on this one modification. The original game will level up after 20 lines cleared, but i want mine to level up at 5, then 10, 15, etc. right now i have
if (board.hasFullLines ())
{
board.removeFullLines ();
if (level < 9 && board.getRemovedLines () / 5 > level)
{
level = board.getRemovedLines () / 5;
handleLevelModification ();
}
}
This levels up at 8 lines cleared (idk why), then 15, 20, 25, etc. so 8, 7, 5, 5 or something like that. I need to modify this formula so it goes up by 5, the original is here
if (board.hasFullLines()) {
board.removeFullLines();
if (level < 9 && board.getRemovedLines() / 20 > level) {
level = board.getRemovedLines() / 20;
handleLevelModification();
}
} else {
handleFigureStart();
}
if you can post a suggestion i'll try it to see if it works, thanks!
- 06-07-2012, 04:50 AM #2
Re: Need to solve this formula for my project
Why do they call it rush hour when nothing moves? - Robin Williams
Similar Threads
-
Kwadratic formula
By BURNY26 in forum New To JavaReplies: 20Last Post: 03-26-2012, 04:31 PM -
Formula Logic Help
By sehudson in forum New To JavaReplies: 4Last Post: 03-11-2011, 04:17 AM -
Formula class
By imorio in forum New To JavaReplies: 3Last Post: 02-23-2011, 09:38 PM -
What is the formula?
By yuchuang in forum New To JavaReplies: 3Last Post: 04-30-2007, 10:00 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks