HP Forums
Radioactive Wastes [UPDATE 2023-11-18 - v1.04] - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: HP Prime (/forum-5.html)
+--- Thread: Radioactive Wastes [UPDATE 2023-11-18 - v1.04] (/thread-4841.html)



Radioactive Wastes [UPDATE 2023-11-18 - v1.04] - komame - 09-30-2015 10:09 PM

Hi,

Radioactive Wastes - my first game for HP PRIME:
http://www.hpmuseum.org/forum/thread-4840.html
...with a bit of animation and the ability to save the state of the game.

Version history:
1.00 (2015-09-30):
- initial release
1.01 (2015-10-01):
- bug fixes, small performance optimization
1.02 (2015-10-03) - 110 downloads:
- additional performance optimizations.
1.03 (2023-08-07):
- adjustments to work on firmware 2.1.14730
- displaying numerical values in a format independent of system settings
- improving the smoothness of the animation by delaying it instead of dropping frames
- minor graphical fixes
1.04 (2023-11-18):
- added touchscreen controls for bulldozer movement (using shortest path method)
- removed the lives limit
- added the option to select a level (from the unlocked ones) on the title screen
- saving the current game state along with the current level layout for later resume (using 'binary asset' resource)
- major performance optimizations - rewritten game logic code
- increased frame rate from 15 to 25 fps
- 3 new levels added
- a smoother level transition effect


RE: My first game: Radioactive Wastes - eried - 10-01-2015 01:12 AM

(09-30-2015 10:09 PM)komame Wrote:  Hi,

Radioactive Wastes - my first game for HP PRIME:
http://www.hpmuseum.org/forum/thread-4840.html
...with a bit of animation and the ability to save the state of the game.

Looks very professional! really impressive


RE: My first game: Radioactive Wastes - John Colvin - 10-01-2015 05:40 AM

I tested the game on my Prime and there is a flaw. When a 'block' is touched by the little 'chip', it continues to move on its own until it hits a wall, making it impossible to complete the level. Otherwise the game graphics are excellent.


RE: My first game: Radioactive Wastes - eried - 10-01-2015 06:06 AM

(10-01-2015 05:40 AM)John Colvin Wrote:  I tested the game on my Prime and there is a flaw. When a 'block' is touched by the little 'chip', it continues to move on its own until it hits a wall, making it impossible to complete the level. Otherwise the game graphics are excellent.

Hahaha (it is a joke, isn't?)


RE: My first game: Radioactive Wastes - xset - 10-01-2015 06:11 AM

I am shocked, it is so colorful ! Very very nice ! Enormous respect !


RE: My first game: Radioactive Wastes - cyrille de brébisson - 10-01-2015 07:03 AM

Superb game!

Now you need to transform it into an app to make it even cleaner.

Cyrille


RE: My first game: Radioactive Wastes - komame - 10-01-2015 08:24 AM

(10-01-2015 05:40 AM)John Colvin Wrote:  I tested the game on my Prime and there is a flaw. When a 'block' is touched by the little 'chip', it continues to move on its own until it hits a wall, making it impossible to complete the level.

Hahah, no! It is not a flaw Smile All levels are posible to complete.

This game needs some speed optimization because these levels where there is 10 or more wastes sometimes work slowly when you hold a cursor keys down long time (while moving bulldozer).
Then you can tap (without holding the key) and then slow down will not be felt. I'm still working on this problem.


RE: My first game: Radioactive Wastes - komame - 10-01-2015 07:17 PM

I just did a small update.
Unfortunately, I can not fix performance problems on some levels, the HP Prime is a little too slow.
Without access to the native programming I can not have the speed, but today I introduced some changes that reduced the sensibility slow down (I am reducing the frame rate when calculating logic takes too long).

Edit:
The problem occurs only when a button is pressed (and held). I wonder if instead use of keyboard I could use the touch screen. Then the problem probably does not occur. Besides, I could implement the shortest path algorithm and a bulldozer could reach the touched field automatically using the shortest possible route.


RE: My first game: Radioactive Wastes - John Colvin - 10-01-2015 07:42 PM

(10-01-2015 08:24 AM)komame Wrote:  
(10-01-2015 05:40 AM)John Colvin Wrote:  I tested the game on my Prime and there is a flaw. When a 'block' is touched by the little 'chip', it continues to move on its own until it hits a wall, making it impossible to complete the level.

Hahah, no! It is not a flaw Smile All levels are posible to complete.

This game needs some speed optimization because these levels where there is 10 or more wastes sometimes work slowly when you hold a cursor keys down long time (while moving bulldozer).
Then you can tap (without holding the key) and then slow down will not be felt. I'm still working on this problem.

The problem I am referring to is not a slowdown. Just tapping the cursor key when the 'bulldozer' makes contact with the radioactive waste causes the object to move continuously until it hits a wall or another object. I am running this on the real Prime, not the emulator


RE: My first game: Radioactive Wastes - komame - 10-01-2015 08:03 PM

(10-01-2015 07:42 PM)John Colvin Wrote:  The problem I am referring to is not a slowdown. Just tapping the cursor key when the 'bulldozer' makes contact with the radioactive waste causes the object to move continuously until it hits a wall or another object. I am running this on the real Prime, not the emulator

Yes, this is ok, cold wastes should roll always continuously.

I also use a real HP Prime...
Do you really not understand the rules of the game yet? I thought you were joking.
This is not a Sokoban. The principles are quite different and here pushed elements may be moved continuously.

Please try again, start from the waste at the top and push it down (roll to the wall). Then push it to the left, push down again and push right... I hope you understood and you can finish the first level.

The performance issues which I wrote start only after completing the first few levels.


RE: My first game: Radioactive Wastes - Han - 10-01-2015 08:08 PM

The bulldozer pushes the waste and the waste rolls until it hits a barrier.


RE: My first game: Radioactive Wastes - John Colvin - 10-01-2015 08:59 PM

Got it. My apologies.


RE: My first game: Radioactive Wastes - Spybot - 10-01-2015 10:25 PM

Very Nice Game! Thank you komame.


RE: My first game: Radioactive Wastes - komame - 10-03-2015 03:08 PM

Thank you all for the good words.
Next version 1.02 is available to download.


RE: My first game: Radioactive Wastes - komame - 09-24-2016 08:22 AM

Hi,

I noticed a significant decrease in performance with the new firmware. My game from this thread was designed for r8151 and there were very minor problems with the performance, which completely disappeared with r10077 (about 20-25% speedup).
Now with the r10637 the speed is worse than in r8151.

I read somewhere that HP Prime CPU speed is modulated by firmware depending on current needs (is it true?). Maybe is it possible to add command that tell what is the current status of CPU speed during the program execution?


RE: My first game: Radioactive Wastes - Tim Wessman - 09-25-2016 05:58 PM

(09-24-2016 08:22 AM)komame Wrote:  I read somewhere that HP Prime CPU speed is modulated by firmware depending on current needs (is it true?). Maybe is it possible to add command that tell what is the current status of CPU speed during the program execution?

There were no changes that would impact this I believe. Unless anyone else reports a similar thing it is probably what I will mention next.

There is a fairly rare thing that can happen where the program execution time for a specific program drops like this. There doesn't seem to be anything you can do to trigger it, but often rebooting and reloading the program, or reinstalling from the connkit can fix it. Our best guess has been that the memory alignment of something in the program might be getting loaded differently on occasion which results in a lot of "out of alignment" accesses at a low level. This can greatly impact speed as data has to be moved around first at every read of each ARM assembly command in order to be read by the processor.

We've tried to ensure this won't happen, but it is possible we are completely wrong here in the assumption. Should someone be able to come up with a repeatable way to do this I'd be super happy to hear about it.

Now it is possible however that there is something that changed. If others report a similar thing with this game I can try to investigate a bit more.


RE: My first game: Radioactive Wastes - chromos - 09-25-2016 06:41 PM

A half of year ago I made program (http://www.hpmuseum.org/forum/thread-5361.html) and its speed depends on how many other programs I have in my Prime (android app). Doesn't matters in which order programs are installed. If I have only that one installed then speed is highest.


RE: My first game: Radioactive Wastes - komame - 08-07-2023 06:43 PM

Update available!

After a few years, I updated my game for HP Prime: Radioactive Wastes.
The new version (v1.03) works correctly with the latest firmware versions and has been slightly improved
https://www.hpmuseum.org/forum/thread-4840.html