This is a place where you can post your small hp prime projects!
Here is Air Hockey my first game!
Ooh I'll have to try this when I get a chance. Do you have screenshots? :)
I will have screen shots but is there any way to record your calc's screen because you have to use touch and it is hard in the PC?
I use the HP Prime emulator. Make sure that you slow down the game to run at the same speed as the calc, though. And to record the screen you must use Camstudio.
EDIT: The game looks really fun to play. It just needs some slow downs on the emulator so that the game score doesn't end up being 576 - 395 after a single minute of play O.O. The idea is really awesome though, seriously. Because you hold the thing to hit the puck and drag it around the screen like with the real game. :)
Yeah I just spent hours tinkering with MOUSE() command and I found out that it uses two lists one for each finger so all I had to do was detect which list went to each side like this
If MOUSE(0)>160 Then
//Put list one for right side of the table
//Put list two for left side
Else
//Put list one for left side
//Put list two for right side
END;
The MOUSE() command outputs lists like this:
MOUSE(0) = X pos
MOUSE(1) = Y pos
MOUSE(2) = Original X
MOUSE(3) = Original Y
MOUSE(4) = Type of gesture (I ignore this most of the time because I just want the mouse position )
The second list is the same thing exept it starts at MOUSE(5) through MOUSE(9) :)
EDIT: About the score if you put the paddle where the puck spawns when you score you can create an infinite loop
(I am on my laptop so I cant record right now but do you have to use camstudio I would use OBS)
Ooh, pretty clever. I always forget that the Prime supports double finger gesturea.
I will need to study the command for when I do my Walrii catching game (I'll need to use pxl-test too)
You are making a Walrii catching game I will have to play that!
Walrii tycoon? Anyways does HP prime have its own proprietary language ( like how ti has ti-basic )?
Yes it does. It looks a bit like Basic and pascal and is compiled on-calc and it actually runs faster than some Nspire Lua or even ASM.
So does it compile like Axe where its only when you want it to or does it compiled at run time?
It compiles when you leave the program editor.
I will have a gif of my games soon (I am converting a MP4 of minecraft right now and I don't have much time on the CPU)
It compiles when exiting the program editor, as alex says. I can't wait for the screenie :D
Oh, cool. I wish that ti had that (like Axe but the one program for both the executable and the source). Anyway I can't wait for the screenshot.
[spoiler](http://i.imgur.com/MN3j6OI.gif)[/spoiler]
Sorry the GIF is a little choppy I recorded to a MP4 Format than converted it to a GIF and then the quality was dampened :(.
DJ does CamStudio record strait to GIF format? That will be much easier in the future!
The Minecraft conversion failed so I am trying that again (It has a large size).
Thanks :) !
Nope Camstudios only does AVI. Looks nice by the way. You should make thecolors like ice hockey rinks :)
Yeah, I was modeling after my own Air Hockey table but you are right the actual field should be white.
Also there are rings that appear on all four corners but for some reason they don't show up on the emulated version :(
Aah that is strange. I wonder if it could be an issue with the program code? Sometimes, when the code has errors, the emulator behaves differently than the calc and has much higher chances to crash. By the way, backup often when developing HP Prime games. Sometimes, the emulator resets itself.
Well since I am at school all the time I code on my IRL calc and record my emulator so that is not a big deal.
And the few time it has crashed I haven't lost anything so but I use the versions I upload here as a buffer :)
In my case the issue was that in some rare cases, usually when it started crashing more often than usual, a new folder would be created on my computer and in even rarer cases, the crash would actually trigger the reset option.
On the emulator?
Yes. I never had a data wipe on the real calc. Even on the emulator it's pretty rare, though. Usually it's just the folder location being suddenly changed so I can easily copy/paste the files. But yeah I did have data loss before.
A crash triggering the reset option... that must have been one heavy crash o.o
Yeah, the emu was really unstable when your code had errors. Unlike the calc, this is what you sometimes got instead of error check.
Yeah the most minor IRL calc crash I have had is when a I stopped a program and it turned off all I had to do was turn it on again, the most major one reset the calc but there were no data losses only a line in a program that I was working on was missing.
Also watch out HP Prime users be careful with the notes section it is very unstable I use it with school and that crashes the most so what I do is use features like font color and font size sparingly other wise it goes :blah:
Ouch! Sounds like you should report the bug to Tim Wessman.
Where could I contact him? And it is mostly I found when you go to the font color menu, change color, then go to the back round color and it doesn't like it very much :-(
He has an account on Omnimaga, CodeWalrus and HP Museum, but due to spambot protection he probably cannot reply to private messages on CodeWalrus, since it requires 5 posts to do it.
I am going to remake the Air hockey game with no flickering and stuff then post it on the downloads section :)
Cool. You should make graphics like ice hockey
I look forward to playing this if I get a prime.
I'll look forward to playing this, and many other things if I get a prime. :P also, if you are going to include teams, be sure to make them acurate,and name the game with 2015 in it or something.
Quote from: DJ Omnimaga on June 07, 2015, 11:58:40 PM
Cool. You should make graphics like ice hockey
Do you mean with actual people sprites and stuff that could work but I would have to implement them facing the puck and that would be hard I would think :(
Quote from: Unicorn on June 08, 2015, 07:53:10 AM
I'll look forward to playing this, and many other things if I get a prime. :P also, if you are going to include teams, be sure to make them acurate,and name the game with 2015 in it or something.
Thanks, as teams do you mean more than one player per side? That wouldn't work because the Prime can only handle two MOUSE() events at a time sadly :-|
Well no, I guess Iwas thinking of an AI, and then choosing an actual team in theNHL to play as. But, The ai part would be pretty hard to code
Yeah, I think I will stick to regular Air Hockey and just make a really refined version :). But in the future we could make a foosball game.
(http://www.foosballtablesdirect.com/ageanfrescofoosball.jpg)
Quote from: alexgt on June 08, 2015, 12:43:07 PM
Quote from: DJ Omnimaga on June 07, 2015, 11:58:40 PM
Cool. You should make graphics like ice hockey
Do you mean with actual people sprites and stuff that could work but I would have to implement them facing the puck and that would be hard I would think :(
Quote from: Unicorn on June 08, 2015, 07:53:10 AM
I'll look forward to playing this, and many other things if I get a prime. :P also, if you are going to include teams, be sure to make them acurate,and name the game with 2015 in it or something.
Thanks, as teams do you mean more than one player per side? That wouldn't work because the Prime can only handle two MOUSE() events at a time sadly :-|
Not necessarily player sprites, but at least make the ice white or light blue and the goals red, like in real life.
Quote from: alexgt on June 08, 2015, 08:18:53 PM
Yeah, I think I will stick to regular Air Hockey and just make a really refined version :). But in the future we could make a foosball game.
(http://www.foosballtablesdirect.com/ageanfrescofoosball.jpg)
That might be hard to play on a touchscreen or keypad, though O.O
Quote from: alexgt on April 24, 2015, 08:45:47 PM
Where could I contact him? And it is mostly I found when you go to the font color menu, change color, then go to the back round color and it doesn't like it very much :-(
timwessman at hp com for email.
Would definitely be interested. I have a hard time following here since I just don't understand the layout of things basically. Must be too old at 32. :banghead:
Anyway, had fun playing your game and showed it to my old boss. She is a huge air hockey aficionado (though I would win about 75% of the time any time we played) :-)
Quote from: timwessman on June 12, 2015, 02:53:31 PM
Quote from: alexgt on April 24, 2015, 08:45:47 PM
Where could I contact him? And it is mostly I found when you go to the font color menu, change color, then go to the back round color and it doesn't like it very much :-(
timwessman at hp com for email.
Ok thanks :)
Quote from: timwessman on June 12, 2015, 02:53:31 PM
Would definitely be interested. I have a hard time following here since I just don't understand the layout of things basically. Must be too old at 32. :banghead:
Anyway, had fun playing your game and showed it to my old boss. She is a huge air hockey aficionado (though I would win about 75% of the time any time we played) :-)
Awesome! Glad you like it :). After I get back next week I will start on the new Air Hockey game!
Quote from: DJ Omnimaga on June 11, 2015, 07:54:32 PM
Quote from: alexgt on June 08, 2015, 12:43:07 PM
Quote from: DJ Omnimaga on June 07, 2015, 11:58:40 PM
Cool. You should make graphics like ice hockey
Do you mean with actual people sprites and stuff that could work but I would have to implement them facing the puck and that would be hard I would think :(
Quote from: Unicorn on June 08, 2015, 07:53:10 AM
I'll look forward to playing this, and many other things if I get a prime. :P also, if you are going to include teams, be sure to make them acurate,and name the game with 2015 in it or something.
Thanks, as teams do you mean more than one player per side? That wouldn't work because the Prime can only handle two MOUSE() events at a time sadly :-|
Not necessarily player sprites, but at least make the ice white or light blue and the goals red, like in real life.
Quote from: alexgt on June 08, 2015, 08:18:53 PM
Yeah, I think I will stick to regular Air Hockey and just make a really refined version :). But in the future we could make a foosball game.
That might be hard to play on a touchscreen or keypad, though O.O
Yeah I made this when I only had my broken calc so I had no intentions of releasing it but that is why I am making a new one (Good luck to me if I tried to understand my code :P)
And I think if foosball was made I think it would have to be a mini version with four paddle stick things instead of eight in total :-|
Also all the downloads here I will put on the first post for ease of access :)
Quote from: timwessman on June 12, 2015, 02:53:31 PM
Quote from: alexgt on April 24, 2015, 08:45:47 PM
Where could I contact him? And it is mostly I found when you go to the font color menu, change color, then go to the back round color and it doesn't like it very much :-(
Would definitely be interested. I have a hard time following here since I just don't understand the layout of things basically. Must be too old at 32. :banghead:
Sorry to hear. It might be due to how back in the days you were probably used to messageboards that showed up in threaded view with minimal design. I'm just 4 years younger than you, though O.O
Quote from: alexgt on June 12, 2015, 08:25:24 PM
Also all the downloads here I will put on the first post for ease of access :)
Good idea. You could also put them in the site's download section. :P
Also a football game would be quite ambitious. Maybe it would be better to make a hockey game similar to Ice Hockey on the NES at first or just like air hockey, because football has like 11 players on each side. The AI would still be a mess to code, though, especially if you implement hits and passes.
Yeah It would be pretty difficult to program *.*!!!
I will put them into the downloads section also (should they go in one topic or what?)
Each game should have separate topic, I think, so they have more visibility.
Ok :)
I need to get back into z80 programming so I can finish JarvAXE 5.0 <_<
^This, but I am cool with more HP Prime games and cool programs too :)
Yeah I still mainly will develop with HP PPL but I don't want to have a large undone project :-\
Yeah i hate it when that happens. After a few monbths you are just tired of a project and want to do something else <_<
It is not that but I have two extremely similar projects and one (SIFS) is over shadowing JarvAXE 5.0 <_< (Not that I don't like either project tho)
Quote from: Cumred_Snektron on June 26, 2015, 02:41:26 PM
Yeah i hate it when that happens. After a few monbths you are just tired of a project and want to do something else <_<
Yeah I had that happen sometimes too. Especially when I worked on Illusiat series. I would end up rushing the ending as a result to start a new game faster. But the rushed endings were also partly due to lack of RAM.
Maybe you could work on Minecraft :)
A super long rpg with a great storyline then boom! It ends without an explanation :P
It's more like once the final battle is over, it literally says "The End" instantly, or at the very best with 1 screen of text. Some games have better endings but the Illusiat endings and especially the Mana Force 2002 ending are particularly bad.
Yeah I am focusing on MinePrime now (I have to look into the AI system learning and stuff, also I am dreading the program editor O.O) Does anybody know a way of detecting a new line in a string?
A:=1; //this is fine just look for the semicolon
If A==1 then //look for then
A:=2 //this doesn't need a semicolon to compile corectly so I can't detect when to make a new line :(
end; //this line and the previous line will get smooshed together because of the lack of the semi colon
Maybe
@timwessman might know which character it is?
It is the return character but I have no idea which one it is in the char menu <_<
Have you found some sort of arrow that is shaped like a L rotated 90° counter clockwise with an arrow to the left? Or maybe the carriage return symbol that looks a bit like a musical note backwards?
This is what I mean when I copy a program and open the paste menu
(http://i.imgur.com/3Lcr0TM.png)
That character shows up when I press enter on my Casio in the program editor... weird.
What I am saying is that they appear there but they aren't there when I copy it to a string :-\
Ah that's strange. Maybe HP decided to disable parsing them?
I think what I can do is just look for the new line part by making a new line in the source but this is not tested:
//Code
Looks for this: "
" //there is a new line in between the quotation marks
//Code
The problem is that if those characters are not detectable, then the code above won't work either, right?
Also IIRC most calcs will think of line breaks as different lines of code.
The compiler looks for the semicolon so I think it will work but I have yet to try it out xD
Wait, it treats line breaks as semicolons? If it wasn't for certain lines of code not using a semi-colon at the end (eg IF instructions), then you could have made your program add line breaks at the end of semicolons.
Also, for your hockey game, something I thought that would be cool is if you tried making an actual hockey game but with 2 players on each side, one controled by the AI unless you switch to it. You could also make the field of play 3D mode-7-like like in Mac Bernicks's Trailblazer game.
Quote from: DJ Omnimaga on July 30, 2015, 04:20:36 PM
Wait, it treats line breaks as semicolons? If it wasn't for certain lines of code not using a semi-colon at the end (eg IF instructions), then you could have made your program add line breaks at the end of semicolons.
Also, for your hockey game, something I thought that would be cool is if you tried making an actual hockey game but with 2 players on each side, one controled by the AI unless you switch to it. You could also make the field of play 3D mode-7-like like in Mac Bernicks's Trailblazer game.
That could work.
But to clarify the semicolon thing (I think but do not know) but the only time you don't need a semicolon is before the final END; statement in the loop, if branch, function, ect. :)
Wait, do you mean the last command before an END doesn't need a semi-colon? That would be a bit inconsistent.
Quote from: alexgt on July 05, 2015, 02:59:54 PM
Yeah I am focusing on MinePrime now (I have to look into the AI system learning and stuff, also I am dreading the program editor O.O) Does anybody know a way of detecting a new line in a string?
A:=1; //this is fine just look for the semicolon
If A==1 then //look for then
A:=2 //this doesn't need a semicolon to compile corectly so I can't detect when to make a new line :(
end; //this line and the previous line will get smooshed together because of the lack of the semi colon
The general ascii code for the newline character is byte 10 ('\n'). I don't know if the prime honours the ascii standard though :P
Doesn't the prime use Unicode?
Unicode - also known as unicorn-code :P
Quote from: DJ Omnimaga on August 15, 2015, 07:13:21 PM
Doesn't the prime use Unicode?
I think the first 256 characters of unicode are the same as the ascii characters.
Quote from: Cumred_Snektron on August 16, 2015, 10:17:25 AM
Quote from: DJ Omnimaga on August 15, 2015, 07:13:21 PM
Doesn't the prime use Unicode?
I think the first 256 characters of unicode are the same as the ascii characters.
Yes, or more technically: The first 256 characters of Unicode are the same as the 256 characters in ISO-8859-1, and the first 128 characters of ISO-8859-1 are the same as the 128 characters in ASCII.
Ah, right. Thanks for the info. Are those first characters as large as the rest of the unicode characters when in unicode mode?
Quote from: DJ Omnimaga on August 12, 2015, 05:09:48 PM
Wait, do you mean the last command before an END doesn't need a semi-colon? That would be a bit inconsistent.
Yup, but I only exclude it on mock up test programs
I would recommend including it in public program releases anyway, in case future OS updates patch this.
That is what I do but I don't think it is a bug that necessarily needs patching
Quote from: DJ Omnimaga on August 17, 2015, 06:24:59 PM
I would recommend including it in public program releases anyway, in case future OS updates patch this.
the ; is probably only there as a marker that the expressoin has ended. Since an 'END' token is not allowed in a mathematical expression, the compiler knows the expression has ended anyway.
^ That is probably how it works
Quote from: alexgt on August 17, 2015, 06:35:22 PM
That is what I do but I don't think it is a bug that necessarily needs patching
Indeed. I'm just suggesting as a precaution, in case HP does it anyway, because it would suck if your games stopped working completely just because of a missing semicolon at the very end of the code. Thanks Cumred for explaining by the way :)
I could make it part of the SIFS program editor that when you exit it inserts semi colons where it is needed :).
You can try, but that probably requires quite complex matching. You'll probably be even better of making your own language :P
Quote from: alexgt on August 19, 2015, 11:53:28 AM
I could make it part of the SIFS program editor that when you exit it inserts semi colons where it is needed :).
That could work too. Just make sure it won't insert them when unwanted, though, such as after sprite data.
^Yeah it is more complex than it seems, I will probably start on the editor next week then I will definitly see how hard it will be O.O
Good luck theb. Hopefully it won't be too hard. >.<
That reminds me, would syntax coloring be too slow?
Not to slow the only problem I am facing is how to figure out where to place the cursor with touch gestures <_<
Great to see progress on sifs, hopefully it won't be toooo hard to get working :)
It will definitly be a great challenge I just hope I am not to stupid when I try and squish bugs xD
What kind of bugs? Moths? :trollface:
Probably radioactive croaches O.O
What?And about the touch, maybe make is very presice when holding it down?
Quote from: alexgt on August 23, 2015, 11:44:52 PM
Not to slow the only problem I am facing is how to figure out where to place the cursor with touch gestures <_<
You could simply divide the clicked location by the amount of pixels in height that each line of text takes? Basically, if the editor shows 16 lines of text at once then divide the touchscreen gesture value by 16. That way it will place the cursor where you want.
Quote from: alexgt on August 27, 2015, 02:43:02 PM
Probably radioactive croaches O.O
There's actually a movie involving radioactive croaches :P
Quote from: DJ Omnimaga on September 01, 2015, 02:29:48 AM
Quote from: alexgt on August 23, 2015, 11:44:52 PM
Not to slow the only problem I am facing is how to figure out where to place the cursor with touch gestures <_<
You could simply divide the clicked location by the amount of pixels in height that each line of text takes? Basically, if the editor shows 16 lines of text at once then divide the touchscreen gesture value by 16. That way it will place the cursor where you want.
Quote from: alexgt on August 27, 2015, 02:43:02 PM
Probably radioactive cowroaches O.O
There's actually a movie involving radioactive cowroaches :P
Positioning the cursor onscreen isn't really the biggest challenge it is when I need to edit the string of code which is on one line there fore I would have to find how many extra characters I skipped forward or back.
also what did those roaches look like?!?!?!
Oh I see now. I hope you can find a workaround.
And the croaches in the movie looked similar but ate human flesh.
Yeah, I have an Idea but it is not the most efficient <_<