Note to 'self' and all other peeps! Razz

PT_ wrote:
L1(0*3) = first element, L1(1*3) = second, L1(2*3).. and so on


This assumes a 3 in the Copy(...,...,SIZE and Data(3,... function, as shown at the bottom of page 1 by PT_

(SIZE= #elements * ByteSize, in this case, 5*3=15)
So I fixed the stacking bug, but the same bug as seen on the GIF on page 1 still persists: When the column is full and the down arrow is pressed, the color still switches. I've tried a

Code:
If getPixel(X[of the coin to drop],45[iirc, could be 70, this is the Y of the topmost hole's center]=255 / Color switch stuff
...

but it doesn't seem to work. Any suggestions on this and some pseudocode for the winning check? I'll probably upload this to the archives after the color bug is fixed, and state the win detection/ beta stuff in the description.

Edit: 300th post!
You should not use getpixel at any point in this program. Smile
Just check if the top position of that colun is filled or not. Do not use any GetPixel(, but use a list instead.
SM84CE wrote:
Yes, I know there's a TI-BASIC version, as well as a C version, but why not an ICE version? Smile

I haven't started writing Connect4 ICE yet, but I have a few ideas and I'll probably look at the BASIC version and C version to get ideas and how-to's. Currently, it'll have the classic board style, I might add more settings and stuff after I figure out how the heck I'm supposed to read from AppVars. I also will probably have to experiment with GetPixel(, and use that to determine placement of the 'pieces', etc. Feel free to post feedback, suggestions, etc. here. I'll update this thread as I get things going.

To-Do
Main menu
win detection

Done
Draw board and tokens/coins/pieces
move and drop tokens/coins/pieces
stack/ column stuff (see below GIF)

(GIF is old)



Wow you have way too many programs Very Happy
timedia wrote:
SM84CE wrote:
Yes, I know there's a TI-BASIC version, as well as a C version, but why not an ICE version? Smile

I haven't started writing Connect4 ICE yet, but I have a few ideas and I'll probably look at the BASIC version and C version to get ideas and how-to's. Currently, it'll have the classic board style, I might add more settings and stuff after I figure out how the heck I'm supposed to read from AppVars. I also will probably have to experiment with GetPixel(, and use that to determine placement of the 'pieces', etc. Feel free to post feedback, suggestions, etc. here. I'll update this thread as I get things going.

To-Do
Main menu
win detection

Done
Draw board and tokens/coins/pieces
move and drop tokens/coins/pieces
stack/ column stuff (see below GIF)

(GIF is old)



Wow you have way too many programs Very Happy


Don't even get me started.

It takes me almost 3 minutes to scroll through mine.

I've been using the "New..." screen to type in the program name, and it takes you to it.

Anywho, I'm glad to see this is a thing Smile
Yeah, well.... me and my 108 prgms (115 in CEmu, iirc Razz)...

I have been working on this and...:
GitHub Repo is here
The code in the repo is (fairly) up to date, the GIF, hoever, is not. I'm thinking of adding my 'test' programs (copy the current prog and work on the copy on-calc (it's a complex system, but it works for me!))
See, this is why I have a nspire, I can make folders (I dont use them though Very Happy )
This project isn't dead!!

Over break, I plan on working on this, as well as adding lists to the control scheme, and adding comments to my code (I probably haven't/don't know what anything does Razz)

I also got a hang (ish) on AppVars, so expect to see some customizations coming later on!
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 2 of 2
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement