CodeWalrus

Development => Calculators => Calc Projects, Programming & Tutorials => Topic started by: semiprocoder on February 09, 2016, 03:10:40 AM

Title: Ti Nspire Tunnel[nspire][lua]
Post by: semiprocoder on February 09, 2016, 03:10:40 AM
So I know there already exists a tunnel for the nspire, but it is really flashy and annoying and the difficulty doesnt progress(at least not noticeably).
Thus I decided to create my own tunnel game for the nspire. It is made it blocks, with each block being 10 pixels rather than one.
The only real issue I have right now with my game is that the movement is by presses and it isnt smooth. If there is any way to make it so that holding down the key is registered and releasing the key is registered, that would make making movement smooth so much easier, but unfortunately, I do not see any way to do that.
Attached are screenshots and the source.
Title: Re: Ti Nspire Tunnel
Post by: Dream of Omnimaga on February 09, 2016, 06:07:01 AM
Oh wow I remember the other Tunnel O.O, it was kinda cool but yeah the flashiness can be annoying for some people. :P Nice rendition, by the way :)

I don't think holding down keys detection is possible in Lua, though. THis is one annoying Lua limitation on the Nspire (even TI-82/83/84 BASIC has key repeat for arrow keypresses)
Title: Re: Ti Nspire Tunnel
Post by: alexgt on February 09, 2016, 02:22:03 PM
Nice! I really like how it looks ;). I also remember Pixel escape.
Title: Re: Ti Nspire Tunnel[nspire][lua]
Post by: semiprocoder on February 12, 2016, 10:22:47 PM
So I've essentially finished the game. It now includes a readme and saves your highscore(which I am not 100% sure works). These are really the only outward changes.
However, I also added error catching code, and the screenshot below shocases what that looks like(Note: the crash was induced by an extra line of code I added temporarily and now removed).
This error catching should work for all my future games(and walriidts if I feel like reuploading it).
The full file is also attached.
Title: Re: Ti Nspire Tunnel
Post by: Dream of Omnimaga on February 14, 2016, 05:14:29 PM
Nice idea about the error catching code. :D Also I'm glad to see the game finished. You should put a link in the first post and put it on ticalc.org, so it gets listed to the CW downloads section. :3=

Do you plan to add new stuff in the future? Some kind of graphics, such as making the road gray, the borders brown and the rest green with a gradient on the side would look cool I think.

(http://img.codewalr.us/mockuptunnel.png)