|
Forum Index : Microcontroller and PC projects : MMBasic: Knightmare Game
| Author | Message | ||||
| homa Guru Joined: 05/11/2021 Location: GermanyPosts: 485 |
Hi LeoNicolas, I saw the two days thing, so I was curious and downloaded it yesterday. Unfortunately, it doesn't respond to any keyboard input?! Matthias |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Can you share the link to the interpreter you are using? I will try to fix the issue. It is working fine on my version, as visible in the video I shared. |
||||
| homa Guru Joined: 05/11/2021 Location: GermanyPosts: 485 |
From your website https://github.com/leonicolas/knightmare-cmm2: MMBasic for Windows The Windows/DOS version of MMBasic was created to make it easy to evaluate MMBasic. It is a single executable that does not need installation, just double-click on the executable and MMBasic will run in a DOS window on Windows (including Windows 10). It also runs in Linux using Wine. The executable and documentation can be downloaded from https://www.thebackshed.com/forum/uploads/matherp/2023-12-24_033644_MMBasic.zip. This link. Matthias |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Matthias I pushed a fix for the issue. Please, let me know if it is working. Thank you for reporting the bug |
||||
| homa Guru Joined: 05/11/2021 Location: GermanyPosts: 485 |
Quickly: Yes, it works ! Thanks for the fix Leo. I'll test it further over the next few days. matthias |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Hello everyone I have finished the stage 8, the final cut scene, and I fixed a ton of bugs. Now the game has beautiful high quality songs written by H0ffman (Thank you man!). There are some minor fixes I need to work on, but I think the game is playable until the end. The easy mode decreases the enemies fire rate and the bosses life in 50%. Please report any bugs to me. I'm preparing myself for a new game port in MMBasic Some tips: - There are weapons more powerful than others, and if you pick up the same weapon twice, it will be stronger - Try to get the Speed up power up multiple times. Each one will increase a little your speed - The shield is an essential power up - There are lives inside some ? boxes and there are invisible boxes. You need to shoot them to reveal - There are some variables you can play with on the km.bas file, line 43 ![]() ![]() ![]() ![]() |
||||
| Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 5464 |
Hi Leo, Congratulations on the final release.!! A true masterpiece. I assume this release is still the PC (MMB4W) version ? Or is this the CMM2 version that you are releasing ? Just curious... Volhout P.S. This H0ffmann is a real genius with MOD files. All that from MODtracker and an ancient Amiga. And any pico can play it. I may try to get a hold of his complete oevre, and play it in a caroussel as background music during work. Edited 2025-11-07 18:19 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
| PilotPirx Senior Member Joined: 03/11/2020 Location: GermanyPosts: 105 |
Hello Leo, looks so great. Put i'm a little bit puzzled. What hardware does this game currently run on? In your GitHub, it's in the "knightmare-cmm2" folder, but unfortunately it doesn't run on my CMM2. What hardware other than a Windows computer can I use? Which controls work? |
||||
| Martin H. Guru Joined: 04/06/2022 Location: GermanyPosts: 1303 |
Hi Leo, that is fantastic, I admire your perseverance with this project. If you tell us where we can download the finnished Versiion, I will test the result thoroughly over the weekend. Cheers Martin Edited 2025-11-07 18:56 by Martin H. 'no comment |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
I have forgotten to mention that The game only was tested on the MMB4W running on my laptop over Wine on Linux. My next step is to make it work on the CMM2 PicoMite VGA machines. I have both CMM2 G1 and G2, and also a PicoMite VGA Please, let me know if it runs in your computers The last version is always the one on the main branch of the repo https://github.com/leonicolas/knightmare-cmm2/ Edited 2025-11-07 19:17 by LeoNicolas |
||||
| Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 5464 |
Hi Leo, I have not studied the core of your game but looking at the screen, and counting the number of objects that move at the same time, I advise you to focus on CMM2. Not that I doubt your skills, but I doubt PicoMite VGA CPU power in MMBasic to run this game without touching/redesigning the core of the game. If at all possible. The Pico is not as powerful as a CMM2, and it does not have as much memory(RAM). The code (.inc and .bas file) in your github is 120kbyte. PicoMiteVGA RAM allows for 75kbyte of code, with poor/no support for .inc files. Having said that, it would be great if picomite can be done, and I am definitely willing to help with the port. But it is going to be hard. Volhout PicomiteVGA PETSCII ROBOTS |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Volhout The code was written to be easy to read, with long function and variable names, and a lot of commentaries. I think I can use MMEditor to shrink the code, which probably will save a lot of bytes. Optimization can be done if required. My next goal is to make it work on the CMM2. Another big memory optimization can be done in the way I'm reading the map. In the current version I'm reading the entire map data from the file and keeping it in memory, which it is not necessary. Can easily read it in chucks and discard old data. |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Hello everyone Today I fixed some minor bugs that were creating issues to run the game on the CMM2 board. Thank you to @PeteCotton for pointing to the lines that needed to be adjusted to fix the issues. I recorded a short video of the game running on the CMM2 G2 board The next iteration will be to test the game on a PicoMite VGA board. Edited 2025-11-10 15:22 by LeoNicolas |
||||
| homa Guru Joined: 05/11/2021 Location: GermanyPosts: 485 |
Hi LeoNicolas, Does the game also support the Wii Classic Controller/Pro on CMM2? Because the game runs with sound for me, but only with the keyboard. Otherwise, really great job! Also, it already runs on the first real hardware. Matthias |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Thank you for the feedback Matthias It supports USB gamepads, but I never tried a Wii Classic Controller/Pro because I don't have one. You can check the code responsible for reading the user input opening the input.inc file. The process_input function uses the read_keyboard% and read_gamepad% functions to read the user input. I think I will need to adjust the read_gamepad% to accept Wii controllers. If you feel comfortable changing the code, you can add the support and submit a pull request to me. As I explained before, I tried to make the code well organized and easy to read, avoiding data statements and crazy optimizations which make the code hard to understand. Edited 2025-11-11 06:29 by LeoNicolas |
||||
| Volhout Guru Joined: 05/03/2018 Location: NetherlandsPosts: 5464 |
@Leo, I cannot vote for CMM2, since I do not have experience with it, but when you use OPTION SYSTEM I2C gpx,gpy (in your case GP26,GP27) then the WII CLASSIC can be opened in the MMBasic program WII CLASSIC OPEN / CLOSE. And the API is very much like the GamePad you already implemented LX% = DEVICE(WII LX) Volhout PicomiteVGA PETSCII ROBOTS |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
I bought a cheap Wii Pro Controller clone, and I’ll add support once it arrives. |
||||
| homa Guru Joined: 05/11/2021 Location: GermanyPosts: 485 |
Hi LeoNicolas, Here are the modified files for playing on cmm2 G2 5.07.02b11 with the WiiClassicController/Pro (=> wcc). input.inc init.inc global.inc wcc.zip However, I'm still having problems with the game crashing after a while with this error?!? "Error in Music.inc line 67: A hard error occurred in the low Level disk I/O layer" I think it's because of the beta version or... I'm still looking into it, but not until the Weekend. Matthias |
||||
| LeoNicolas Guru Joined: 07/10/2020 Location: CanadaPosts: 528 |
Matthias Thank you for contributing with the WII controller support. I pushed the code to the repo. Regarding the music error, maybe we will need Matherp support. I don't think it is related with anything in the basic code. It looks the routine responsible for reading the MOD file from the disk is receiving an exception from the disk I/O layer code. |
||||
| Martin H. Guru Joined: 04/06/2022 Location: GermanyPosts: 1303 |
Hi Leo For implementation on Picomite, as promised, here are the tiles in RGB 121. I chose dark green as transparent because it does not appear in the figures/backgrounds. ![]() tilesP.zip Cheers Martin 'no comment |
||||
| The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |