CodeWalrus

Development => Calculators => Calc Projects, Programming & Tutorials => Topic started by: semiprocoder on September 09, 2015, 01:18:40 AM

Title: Learn to Fly Idle for the Ti Nspire
Post by: semiprocoder on September 09, 2015, 01:18:40 AM
Last weekend I started making a game for the ti nspire based off of learn to fly idle on kongregate. I finished it, except that I only have 3 enemies and my pics are not too good. It will be very easy to add new enemies, I just need good pictures for them. I hope you like this simple game I made.

The rules, the game, and some images are attached.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Dream of Omnimaga on September 09, 2015, 06:59:46 AM
Cool to see it released. Do you have any plans to make it compatible with OS 3.6? IIRC there is a way to set the minimum version lower in Lua when creating TNS files, but I don't know how. Someone else might know if you ask in the help section.EDIT: It appears to run on my calc for some reasons, just not in the Student Software. Oh well, at least now I can play :)


I wonder if adding the original background or something looking similar (maybe just a gradient made of blue rectangles for the sky would slow things down?

EDIT: THere are two bugs: I can shoot about 5-6 bullets at a time from the start, while in the oriignal game it was 1 at once at the beginning. The other bug is when I hold down the mouse click button for a while: Once I release it I continue shooting non-stop (not auto-shoot mode, I literally shoot like if I held the button down). Also you should display the stats such as damage and bullet range on the main screen so it's easier to know what we just upgraded.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: semiprocoder on September 09, 2015, 07:25:47 PM
Yeah sorry I only saved the new file on my calc and didnt notice, because that glitch only happens on the calc, so I thought that everything worked, when in reality, it only worked on my calculator. I'll update the game file.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Unicorn on September 10, 2015, 05:56:09 AM
wow, this looks like it will be a very cool project! To bad I don't have an Nspire... :(
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Dream of Omnimaga on September 10, 2015, 05:57:20 AM
Quote from: semiprocoder on September 09, 2015, 07:25:47 PM
Yeah sorry I only saved the new file on my calc and didnt notice, because that glitch only happens on the calc, so I thought that everything worked, when in reality, it only worked on my calculator. I'll update the game file.
No problem. By the way have you seen my suggestions as well? :)
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: semiprocoder on September 11, 2015, 02:31:04 AM
yeah I did change the cannonball to an arc, but I didn't make it only update part of the cannonballs at a time because the lag isnt too bad, so I don't need to do so right now. Also I don't know how to make it compatible with previous versions, but you said that they work...

By the way a while ago I registered to cemetech and now I want to login, but it doesnt let me, saying that my acount inactive and tells me to ask the forum admin, however I cant find any contact info for said forum admin. Anyone hae any advice?
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Dream of Omnimaga on September 11, 2015, 05:41:47 AM
What surprised me is even though there can be like 20 cannon balls at a time, the game still ran at very reasonable speeds.  And yeah I think the issue is on OS 3.1 mostly, but I just upgraded to 3.6 so it isn't as problematic.


As for Cemetech, you have to contact admin [at] cemetech [dot] net . I'm surprised that such error would appear, but if you e-mail them I am sure they'll fix the situation promptly.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: LD Studios on September 11, 2015, 08:25:16 PM
Quote from: semiprocoder on September 11, 2015, 02:31:04 AM
I don't know how to make it compatible with previous versions, but you said that they work...
At the beginning of your code, set
platform.apilevel = desired apilevel
For OS 3.1 support, your desired apilevel is "1.0"
If I recall correctly, OS 3.2 = "1.2", and OS 3.6 = "2.0", but that might not be right.

Keep in mind though, that if you set your code to an earlier apilevel, you also need to make sure you only use functions available in that apilevel.
I think the one thing you would really need to change for this particular project is image handling to imgstr instead of resources.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: semiprocoder on September 11, 2015, 11:29:13 PM
yeah. I don't know how I would do that as I use images to load the cannon and the end images resources, but in earlier version that wouldn't work. I like the fact that earlier versions had strings, because it leaves everything up to you, instead of leaving it to the compiler, but unfortunately that is only allowed in earlier versions. Are there any ways to set the images as resources if the apilevel was >=2.0 and set them as strings otherwise?
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: LD Studios on September 11, 2015, 11:56:50 PM
I'm pretty sure imgstrs are supported in every apilevel, the only problem is that the newer Student Software doesn't have the button to insert an image that way- which is why I still use Student Software OS 3.2
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: semiprocoder on September 12, 2015, 12:28:59 AM
No litterally I cant use it I tried to play games using the old apis version, and the only thing wrong with them was the string image... Also I tried myself to use image strings, because the tutorial I was taking told me to use images with strings, but it told me that it expected a ti.resorcehandle, which is the new way of changing images. Which is why I might make two separate uploads for the two different api leves, although I am not sure how I would test if the image is correct with the string version.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Dream of Omnimaga on September 13, 2015, 05:47:37 PM
Oh I thought that the minimum version peeople had to set was the OS version, not the API level. Perhaps this could explain why @Strontium games didn't run on OS 3.1, even though he said he made them compatible? (he probably set the API level to 3.1). SOme stuff is not supported in 3.1, though, and images are much slower. If your game doesn't run then I guess as long as it runs on OS 3.2 and higher (or maybe 3.6) it's fine.
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Strontium on September 13, 2015, 07:58:14 PM
I'm pretty sure I set the API level correctly. I cant check, though, since I no longer have access to the student software :/
Title: Re: Learn to Fly Idle for the Ti Nspire
Post by: Dream of Omnimaga on September 17, 2015, 06:38:40 PM
Quote from: Strontium on September 13, 2015, 07:58:14 PM
I'm pretty sure I set the API level correctly. I cant check, though, since I no longer have access to the student software :/
Aren't there alternate development tools for Lua programs, though?