tifreak8x wrote:
Yeah, I might see about implementing the matrix setup. Might eliminate some of the headaches that I've almost got taken care of :p


Also, because Text( fails with backgrounds (Maybe pass that on to TI, about maybe doing better overlaying of characters from the Text( command on backgrounds for the next OS update?), I'm thinking about going with no brackground, and a blue board. What are your all thoughts on this?
Can you be a bit more specific on that failure? You mean that you can't specify the background color of text? No background and a blue board sounds reasonable to me.
Yes, that's the problem. Even when you change the color of Text(, it still has a white background. I can't remember what it was called when overlaying sprites to keep from having that blocky feel, but TI should consider adding that to the Text( command for their next OS update.
They either need to OR the text onto the screen (which would break backwards compatibility, so I don't think that's a good idea), or they need to add a second parameter to TextColor that sets the background color, and default it to white. Maybe also have a new color of TRANSPARENT or something.
To be fair, they break backwards compatibility with a lot of the 84+ OSes they did. They added new functions that doesn't work in previous versions, so you had no choice but to get the newest OS. They did that some with the 83+, mostly after 1.12.

But yes, a background color for the text would be wonderful.


Reverted back to a slightly older file, since I botched up the other I had been working on.

Everything works properly until I get to that last column. I think if I increase the size of the list by 1.. *tries*

So, success in so many ways. Just made it a 43 element list instead of 42, life is good.

And I used Calc Capture to take the screenshot, just for fun, and to see if it'd work (dear lord the set up was a pain), and here is that:

It goes a bit faster than that on calc.

merthsoft thinks I should be rid of the animation of the pieces falling, thoughts?

http://tifreakware.net/tifreak8x/connect4/BA.8xp For those that are awesome and want to give it a quick whirl. Also, the screenshot shows white background, but it's dark grey. Calc Capture's fault.
So yeah, because shaun yelled at me, I updated the above post, yo. Check out them stylin screenshots and such.
The screenshots look good. I still think there might be some way to take advantage of symmetry in drawing the cells.

I also agree that a matrix might be the better way to go for this. Also, the code I gave you for detecting a win is matrix-based. I think it's probably easier that way (but if you find it easier to use lists and it works, it doesn't really matter).
I almost did the matrix setup, but I was determined to make this version work, to make it different from anyone else's Connect 4 clone that gets made in the future, because it's going to happen at some point.

I'll be able to make some of the win detection a bit easier, gave it a lot of thought on the routes today. Can't wait to get started on that Smile

And thank you! Smile
tifreak8x wrote:
And I used Calc Capture to take the screenshot, just for fun, and to see if it'd work (dear lord the set up was a pain), and here is that:

What is this Calc Capture you speak of?
Calc Capture is a program located on ticalc.org, that was used to get animated screenshots from emulators back in the day.
Oh for the good-old days of Calc Capture, huh?
I think you should leave the animation as it is, though pressing enter again during the animation ends the animation prematurely.
Once I see about getting this game playable, then I'll see what I can do for that.

Working on the detection stuff right now, trying to figure out values and such for what needs looked at, which I think I have done, and determine what I need to do from there.
On a side note, I'm wanting to add the following modes to this game once I get it to work properly:

PvAI P-1st
PvAI AI-1st

I actually could pull off both PvAI modes easily, simple matter of changing a While loop value to start somewhere else Smile

And while looking at the code, I'm thinking that I might need to rearrange a few things anyways.. :/
I'm glad to hear that this project is still progressing, tifreak8x. Good luck, and of course don't hesitate to post if you get stuck on any of the algorithmics for this. It sounds like you stuck with the list board storage instead of using a matrix. I was going to suggest some efficient methods to detect a win using matrix manipulation, but that's a moot point if you're using a list. Smile
Yeah, I kept at it with the lists. It seems to work well enough, and I now have win detection confirmed on a few different directions. Going to go through and test the various directions to see if everything works properly, then I might see about adding a small title screen of some form. Though I'm not sure that's necessary. I might just add that to the big empty space on the right and call it a day Smile

I also need to make it clear out the spaces once the game is won, so it can be played again. I should add that real quick so I can keep playing over and over..

So, what I have left to do:

1. Make it so it will clear out the spaces that are used

2. Make it so you keep on playing instead of dropping out of the program

3. Make the tokens fit the holes better

Perhaps add an option to turn the coin-drop animation off? The animation is done really well, but having the option to play faster could appeal to the impatient members of your audience. If you consider that, I'd also consider adding an option to turn full board-rendering off and draw a 6x7 cell box with lines instead. Again, just for those who prefer a speedy game.
Have you thought about using "Text(-1" to erase the coin at the top of the screen when moving it around? It would be much faster than erasing it line by line.
Ashbad: Yeah, I guess I could do that, add something before everything starts. Just trying to keep the size of the program down, it's already up to 1,732 bytes, and I still need to correct the size of the tokens as they sit inside their slots. Which is the only thing I have left to do, I might add.

DJ: I had considered it, but never bothered to try it. Just trying to keep things uniform. And I'm not sure that Text(-1 trick is tall enough to cover the coin. I might look into it, I was just trying to keep it looking the same being deconstructed as it was being constructed to the screen. The thing isn't that slow on calc. Hopefully someone else with an 84+CSE can test it and agree to it :p


There is also the issue with having to keep track of 2 separate coordinates for the coin and clearing the coin. This, surprisingly, used up a lot of variables to make.
So, I came up with the code to build the simple board type, I just have to get it put into the program and test that it will work. I will still need to add in code to remove the animation to place the coin on the next available line, and to use the Goose coin code to better fill in the circles.
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 3
» 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