Author Topic: Color tetris  (Read 37796 times)

0 Members and 1 Guest are viewing this topic.

Offline Stefan Bauwens

  • Creator of Myst 89 - סטיבן
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1799
  • Rating: +162/-24
  • 68k programmer
    • View Profile
    • Portfolio
Re: Color tetris
« Reply #45 on: November 11, 2011, 12:35:30 pm »
i've found a picture on the internet from the android tetris app, and it looks really nice. Should i try to make the graphics more like this one, or is that too riscy for tetris himself to do it? otherwise, i think i would love to, but i don't want to do something completely illegal :) does someone has any idea if it is allowed or not?



for now i'm cleaning up the code, cause that was necessary, so if you'd like i'll post it tonight or tomorrow or something, so you can have a look at it and maybe even try to help the debugging :)

I'm also trying to insert a ghostblock (like i like to call it) the one that shows you where it is gonna fall, but it's kinda hard xs so you'll have to wait a while
btw, you can see one at the picture in the right bottom corner

--edit--
got the code from 15.2 Kb to 13.1 Kb :)
started on the re-designing
Porting tetris in itself might be illegal :P
Besides, I don't think they patented that picture so... go ahead! :P


Very proud Ticalc.org POTY winner (2011 68k) with Myst 89!
Very proud TI-Planet.org DBZ winner(2013)

Interview with me

Offline AzNg0d1030

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 522
  • Rating: +45/-4
  • Hardcore anime watcher.
    • View Profile
Re: Color tetris
« Reply #46 on: November 11, 2011, 06:08:11 pm »
i've found a picture on the internet from the android tetris app, and it looks really nice. Should i try to make the graphics more like this one, or is that too riscy for tetris himself to do it? otherwise, i think i would love to, but i don't want to do something completely illegal :) does someone has any idea if it is allowed or not?

for now i'm cleaning up the code, cause that was necessary, so if you'd like i'll post it tonight or tomorrow or something, so you can have a look at it and maybe even try to help the debugging :)

I'm also trying to insert a ghostblock (like i like to call it) the one that shows you where it is gonna fall, but it's kinda hard xs so you'll have to wait a while
btw, you can see one at the picture in the right bottom corner

--edit--
got the code from 15.2 Kb to 13.1 Kb :)
started on the re-designing
Go ahead!  You don't have to make the ghost colored, it could just be a white outline or something like that :)
If you want me to test again I'm here :D
You just lost the game.



Offline Nick

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1166
  • Rating: +161/-3
  • You just got omnom'd
    • View Profile
    • Nick Steen
Re: Color tetris
« Reply #47 on: November 11, 2011, 08:21:37 pm »
Go ahead!  You don't have to make the ghost colored, it could just be a white outline or something like that :)
If you want me to test again I'm here :D
you like testing, don't you? :)

in fact, that ghost is the frame of the block that is falling, i mean that only the shape is displayed as drawRect, and in the color of the block, i only have to change the code of the instant dropdown button to find the place to display it. until now, it shows one, but on the lowest row...

--edit--
Here's the new up to date tns file, 'totally' new graphics, and some bugfixes.
There's only one remark, play it on the calc, cause if you're playing it on the emlator, the placing of te numbers isn't correct..idk how, but it is true

btw, does anyone know how to anti-alias the sides of a gc:fillPolygon() drawing?
« Last Edit: November 14, 2011, 03:06:38 pm by Nick »

Offline DJ Omnimaga

  • Clacualters are teh gr33t
  • CoT Emeritus
  • LV15 Omnimagician (Next: --)
  • *
  • Posts: 55943
  • Rating: +3154/-232
  • CodeWalrus founder & retired Omnimaga founder
    • View Profile
    • Dream of Omnimaga Music
Re: Color tetris
« Reply #48 on: November 11, 2011, 08:42:25 pm »
Looks nice. I gotta try the tns soon. I hope to see more news soon :)

Offline AzNg0d1030

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 522
  • Rating: +45/-4
  • Hardcore anime watcher.
    • View Profile
Re: Color tetris
« Reply #49 on: November 11, 2011, 10:56:58 pm »
Hoho nice job!  I don't know how to anti-alias :(

Is it possible to make the shadow on top of blocks? Right now it's at the bottom so when there are blocks in the way you can't really see it, but I think you know this... :P
You just lost the game.



Offline Nick

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1166
  • Rating: +161/-3
  • You just got omnom'd
    • View Profile
    • Nick Steen
Re: Color tetris
« Reply #50 on: November 12, 2011, 11:45:47 am »
damned, by implementing some new stuff, i must have changed something so it goes totally wrong, nooooooo xs
i hope i find it, but i have a back-up from about 1 hour ago, so i won't lose that much, but it's so frustrating

--edit--
Problem solved, accidentally removed a boolean value change...
Ghostblock works, only some small problems with the L-blocks, but it's not that bad
redesign complete
highscore exists now of three numbers instead of 1 highscore
« Last Edit: November 14, 2011, 01:31:03 pm by Nick »

Offline Adriweb

  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1708
  • Rating: +229/-17
    • View Profile
    • TI-Planet.org
Re: Color tetris
« Reply #51 on: November 12, 2011, 12:36:50 pm »
This really looks awesome, congratz :)
My calculator programs
TI-Planet.org co-admin.
TI-Nspire Lua programming : Tutorials  |  API Documentation

Offline aeTIos

  • Nonbinary computing specialist
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3915
  • Rating: +184/-32
    • View Profile
    • wank.party
Re: Color tetris
« Reply #52 on: November 12, 2011, 01:07:59 pm »
Awesome? I'd call this epic! Great job!
I'm not a nerd but I pretend:

Offline Nick

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1166
  • Rating: +161/-3
  • You just got omnom'd
    • View Profile
    • Nick Steen
Re: Color tetris
« Reply #53 on: November 12, 2011, 05:38:29 pm »
thanks! that's really nice :) i'll hope i can finish it soon, so i can put it online..

but i have some delay because of a problem i'm encountering in the displaying of the ghostblock.
it all works fine, but with the L blocks it just wont work... here's the code for it

Code: [Select]

--variables:
fallingblock[8]=width of the falling block
fallingblock[6]=y-value of the block
fallingblock[7]==1 or 2 checks of it is an L or reversed L block
ghostblock[6]=y-value of the ghostblock
ghostblock[5]=x-value og the ghostblock
fallingblock[9]=height of the falling block
l and m are just for loop variables

function on.ghostBlock()
highest = 21
for l=1,20 do
for m=1,fallingblock[8] do
if (fallingblock[6]+l)<21 then
if blocks[fallingblock[6]+l][fallingblock[5]+m-1]~=0 then
if (fallingblock[6]+l)<highest then
highest = fallingblock[6]+l
if fallingblock[fallingblock[9]][m]==0 then
highest = highest+1
end
if fallingblock[7]==2 or fallingblock[7]==3 then
if
end
end
end
end
end
end
end
ghostblock[6] = highest-fallingblock[9]
ghostblock[5] = fallingblock[5]
end

it shows the left one, but it has to show the right one
« Last Edit: November 12, 2011, 05:47:27 pm by Nick »

Offline AzNg0d1030

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 522
  • Rating: +45/-4
  • Hardcore anime watcher.
    • View Profile
Re: Color tetris
« Reply #54 on: November 13, 2011, 01:31:07 am »
I didn't dl the newest one yet but did you get around to fixing the speed-not-changing problem?
You just lost the game.



Offline Nick

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1166
  • Rating: +161/-3
  • You just got omnom'd
    • View Profile
    • Nick Steen
Re: Color tetris
« Reply #55 on: November 13, 2011, 02:56:58 am »
oh, the speed was NOT changing? eeeuuuuh, didn't realize, i'll check it

--edit--
i found it, it just didn't refresh the timer.start()...how could i have missed that, it was impossible to speed up without '+'
"40 lines " and "Time trial" added, now i only have 2 smaller bugs: the one with the ghostblock and that it still shows a picture of the fallen block, while it shouldn't be ther when the line gets erased..
« Last Edit: November 13, 2011, 06:11:43 pm by Nick »

Offline AzNg0d1030

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 522
  • Rating: +45/-4
  • Hardcore anime watcher.
    • View Profile
Re: Color tetris
« Reply #56 on: November 13, 2011, 09:05:49 pm »
Update file ? :O

edit: Nick, get on the irc chat -.-
« Last Edit: November 13, 2011, 09:11:24 pm by AzNg0d1030 »
You just lost the game.



Offline Nick

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1166
  • Rating: +161/-3
  • You just got omnom'd
    • View Profile
    • Nick Steen
Re: Color tetris
« Reply #57 on: November 14, 2011, 01:27:55 pm »
Hello, here i am again, but now with the video of the official first ColorTetris!

Finally, it's finished!!  :w00t:



Features:
-3 modes: marathon (survive as long as you can), 40 lines (erase 40 lines as fast as you can) and time trial (race against the clock)

-Every mode has 3 highscores, names included! (at the beginning they're all called "0 - name" (as you can see in the movie), so 9 highscores in total :)

-Ghostblock, only with those L and reversed L blocks there's a small bug that it displays it one block too high.

-Controls with arrows, 4, 8, 6, 2, p(ause), r(estart), enter and tab.

-Instant dropdown (enter)

-FULL COLOR, but it also works for B/W calcs (not cx), with a white background for visibility

except for those 2 small bugs (first one at 0:25 when reaching the upper line, second one at 1:17 with the ghostblock), but i really do not have any clue how to fix them.. they do not disturb anything of the gameplay at all.

as soon as it's uploaded to omnimaga and ticalc i'll post the links here (ColorTetris.tns, screenshots, readme AND source code for those who want to learn to make tetris)
« Last Edit: November 14, 2011, 01:30:48 pm by Nick »

Offline Hayleia

  • Programming Absol
  • Coder Of Tomorrow
  • LV12 Extreme Poster (Next: 5000)
  • ************
  • Posts: 3367
  • Rating: +393/-7
    • View Profile
Re: Color tetris
« Reply #58 on: November 14, 2011, 02:10:05 pm »
:D Me wants !!! Even with the bugs !!!
Post more so I can give you more +1s :P jk
« Last Edit: November 14, 2011, 02:10:09 pm by Hayleia »
I own: 83+ ; 84+SE ; 76.fr ; CX CAS ; Prizm ; 84+CSE
Sorry if I answer with something that seems unrelated, English is not my primary language and I might not have understood well. Sorry if I make English mistakes too.

click here to know where you got your last +1s

Offline Stefan Bauwens

  • Creator of Myst 89 - סטיבן
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1799
  • Rating: +162/-24
  • 68k programmer
    • View Profile
    • Portfolio
Re: Color tetris
« Reply #59 on: November 14, 2011, 02:12:46 pm »
This is totally epic. WOW!
Also, you speak dutch, hmm, and you're Belgian apparently. Do you live In Sint-Niklaas? :D :P


Very proud Ticalc.org POTY winner (2011 68k) with Myst 89!
Very proud TI-Planet.org DBZ winner(2013)

Interview with me