I've been playing a lot of clash of clans a lot lately with my friends and one of said that I couldn't make it on the calc... so here I am Very Happy

It is going to be programmed in ICE on-calc (of course) and I figured that since CoC is entirely 2D sprites (besides heros), it i entirely possible to make it on the calc with ICE and keep a good amount of frames. I might even be able to do some snazzy animations.

I don't plan on adding any type of multiplayer support, but mostly just some things to show my friends and spend some free time on.

There are already the fundamentals of loading and storing the maps in appvars, along with the basic printing of grass. I'm still not really sure how I will print sprite bigger than 1x1 (anything other than a mine or wall), but ill figure it out as I go Smile

This project will be going kinda slow because I'm still working on the ICE raycasting program, but I'll make sure to continue development

Edit: this is my 100th post (:
This sounds very interesting! I'm excited to see what you do with it and how it will turn out. Be sure to keep us updated!
CoC wouldn't really work as a single player game, IMO. Having a challenging attacker AI is pretty difficult, so you either get very easy defends, or the difficulty would just be "how many troops can you defend against", which wouldn't scale well, especially on a calculator.
It's not really supposed to be a official CoC remake for the CE, but more of a thing to mess around with and laugh at with my friends. If I even end up making attacking, it will most likely not have an AI attack you, but only you attacking randomized or pre made bases. The one thing I guarantee I will be adding is upgrading, even if the times won't be super accurate.

Also, it will be more of a tilemap game instead of having the isometric view, because first, the CE doesn't have enough pixels to do small, diagonal sprites, and second, it's pretty complicated. I plan on keeping my custom tilemap map printing so if I want, I could take a crack at isometric rendering.
You could have a system where it's like you don't see the battle but it simulates the fight and the “troops” are placed randomly in X areas. Then after a bit it will tell you the stats and the town is recovered. Good luck with the sim because I don't know anything about those. The simulation does not have troop sprites and you can save memory and speed.
This sounds like a great project, where will you be getting your sprites from?
I'll be making them all on the calculator. Even if I would go through the trouble of using a pc to make them then put them on the calc, the base clash of clans sprites are rotated 45 degrees (isometric view/diamonds) while mine are going to be rendered as a regular tile map (squares), so I can't really use them.

So far, just making them on the calc has been going well, so I'll just stick to that Good Idea
Cool concept! How much content from CoC do you plan on adding? Including all the troops and buildings and stuff would be very daunting.
Just the basics: gold and elixir storages/generators, town hall, walls, archers, cannons (maybe more basic defenses) I'm not really sure what the points of defenses would be because there wouldn't be people attacking. I also plan to add upgrading but the sprite most likely wouldn't change at all because of space.
Do you have a GitHub for this?
I haven't done a ton so far, so not yet. I do plan on making one soon though.
I am pausing this project (all of my projects) because of AP testing coming up, I'll be back to full speed if not more in like 2-3 weeks (:
I can't help you if you don't do a GitHub.
I don't need help at the moment, but will ask in the future if I have some problems Smile
I have been working on it a bit during break times and now that my big tests are over, I'll be able to work on it even more Smile
I found out that isometric printing is actually kinda easy and was able to get the beginning of an isometric map print. I'm still working on the math for the other side while making sure its efficient and still layers correctly. I'ts shown in the screenshot below:

(Sorry for the fuzzy irl calc pic) You can also see that there is a selector that is moved with the number pad (1 to 9 with 5 to select) and it still runs at 16 fps (super steady) there isn't really anything to improve about the actual displaying of the map, so I think the only real optimization is if I make it lower resolution sprites. There isn't much to see yet besides the map printing and selector, so I'm not going to post the source or program yet.
What code basically did you use for the FPS counter? I'm familiar with how they work but am curious as to how you did it. Code or something I mean? As I've tried a take at FPS and mine returned 1 constantly lol, because I have no clue what code I could use.
TimmyTurner62 wrote:
What code basically did you use for the FPS counter? I'm familiar with how they work but am curious as to how you did it. Code or something I mean? As I've tried a take at FPS and mine returned 1 constantly 0x5, because I have no clue what code I could use.

Here is the code that I usually use as an fps counter:

det(0     //start graphics
det(9,1     //set draw to invisible screen
startTmr→TIME     //store the current timer in the variable TIME

Repeat getkey(49)     //the main loop (loop until graph is pressed)
//*insert any graphical printing or other main program things*
FRAMES+1→FRAMES     //add 1 to variable frames
det(19,1,1     //set the x,y for the fps to displayed at
If checkTmr(TIME)≥32760     //if a second has passed
det(15,FRAMES,1     //print the current amount of frames that have gone by
FRAMES→PASTFPS     //store the fps in another variable
0→FRAMES     //reset the frames amount
startTmr→TIME     //store the time again
Else     //if it has not been a second since last fps check
det(15,PASTFPS,1     //print the last fps
det(11,1     //switch the invisible screen and shown screen


Here is what it looks like if it is in the other corner. Since it only gets updated every second, its not the best but its pretty good for ice, simplicity, and speed. Something I also do is make the entire bit within the main loop into a label and just call it at the end of the main loop for organization.[quote]
Great work so far! I'm impressed that you managed to get this working so fast. Without knowing your implementation though, 16 FPS still seems a little slow--have you looked into partial redraw at all? I've found it very useful in increasing speed, recently using it for VYSION 2, which reasonably couldn't display the whole background or GUI every frame for speed reasons. You'll likely be in a similar situation eventually once you keep adding things to the program.

Anyway, awesome progress, and I'm looking forward to more updates.
At the moment, the entire screen is getting fully cleared then printed every frame. Later I am going to be making a system that only updates the sprite the cursor is on and the one below it when moved, making it wayyyy faster. I just didn't want to make it yet because I haven't completely finished the map printing Smile
I have made a few improvements:
- a lot faster now with only updating where the cursor is (now a very steady 40fps)
- full map printing
- fixed movement glitches
- added levels (doesn't do anything at the moment)
- added a sort of menu with the level of the object selected
- the beginning of ambient background animation (like a cannon turning)

I am going to be both making a git repo and putting it on cemu for a better screenshot soon; I'll link the GitHub in an edit here once I finish it (like a day).

Here is the Github with both the source and the compiled program. Here is a better quality gif:

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 1 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