![]() |
Forum Index : Microcontroller and PC projects : CMM2: Anyone want to work together to port Elite???
Author | Message | ||||
mkopack73 Senior Member ![]() Joined: 03/07/2020 Location: United StatesPosts: 261 |
Looks like the full source code for the old BBC Micro version of Elite is available and fully commented (literally line by line comments!!) https://www.bbcelite.com Given the horsepower we have at our disposal, the built in drawing commands and such, I would think it should be possible to port this over to the CMM2 with maybe only a few sections of code being done with CSubs - most should be able to be done in BASIC and a lot of the graphics stuff they did should be direct MMBasic graphics calls. It's likely a bit too much for me to take on solo right now given other projects I have going on. But if anyone would like to collaborate together on this, let me know below. We'd need to look through the code and see how it's structured and then come up with a conversion plan... |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 4044 |
Looks like a big job but with the right skills & plenty of time... John |
||||
mkopack73 Senior Member ![]() Joined: 03/07/2020 Location: United StatesPosts: 261 |
Yeah I haven’t had a chance to look through the code yet to see how big it is and what the complexity level is. I believe most of it is written in assembly and if that’s the case the basic implementation should be a lot easier to write... where they needed to make functions to draw points and lines and such we already have functions to do that...etc. |
||||
RetroJoe![]() Senior Member ![]() Joined: 06/08/2020 Location: CanadaPosts: 290 |
I don’t know what scale you are using for “complexity level”, but anecdotally I give it a 9.5/10. A very common thing in the 8-bit era was software piracy, and the biggest thing that jumped out at me was it seems a lot of the Elite 6502 code concerns itself with deliberate obfuscation to throw “crackers” off the trail. In other words, prepare for a lot of detective work! Looks like a great retro game, though, and the source code and “theory of operation” is incredibly well documented. It must have been very popular back in the day (we missed the entire “Beeb Scene” here in North America...), as there is obviously a ton of passion and “labor of love” going on - reminds me of the Maximite community :) Further, I believe many of the Elite coding techniques are worthwhile reading for aspiring CMM2 game developers (like me :) - the same “retro era” challenges exist for us, as Elite was written before the advent of powerful 2D and 3D game engines that do all the heavy lifting for you. To your point, MMBasic does plenty of heavy lifting in its own right, and makes it feasible to port games like this without requiring C or Assembler, but all the game mechanics and perspective rendering of a pseudo-3D arcade game is very much a “DIY” proposition. Good luck! Enjoy Every Sandwich / Joe P. |
||||
JoOngle Regular Member ![]() Joined: 25/07/2020 Location: SwedenPosts: 82 |
Missed the fact that the source was released. Edited 2020-10-02 00:32 by JoOngle |
||||
thwill![]() Guru ![]() Joined: 16/09/2019 Location: United KingdomPosts: 4311 |
I'll pass, my CMM1 and CMM2 already have an OLD friend: ![]() Note that there is an alternative entry point: https://github.com/fesh0r/newkind Tom Edited 2020-10-02 01:12 by thwill MMBasic for Linux, Game*Mite, CMM2 Welcome Tape, Creaky old text adventures |
||||
twofingers![]() Guru ![]() Joined: 02/06/2014 Location: GermanyPosts: 1593 |
More links about E-TNK: https://web.archive.org/web/20140527092439/http://newkind.co.uk/games/ http://wiki.alioth.net/index.php/Elite:_The_New_Kind http://www.new-kind.com/ Michael causality ≠correlation ≠coincidence |
||||
RetroJoe![]() Senior Member ![]() Joined: 06/08/2020 Location: CanadaPosts: 290 |
And what a beautiful friend it is, Tom - I love the design :) Just curious, is the color due to age, or was yellow the original color? The reason I ask is I recently undertook my first Retrobriting project (on an Apple //c...) and it turned out really well. Maybe you prefer to let the old girl age gracefully :) One related anecdote - my 14-year old son’s galactic PC gaming rig that we built together failed to boot up a few months ago. He asked me for advice, and my “sight unseen” diagnosis was “It’s got to be the power supply - I have an Apple II that’s been running FOR 40 YEARS, and the PSU was the only thing that I’ve had to replace”. Remarkably, even the 5.25 disk drives are running great. The disks themselves are another story, though - the failure rate on those are through the roof. Anyway, the longevity and reliability of these old 8-bit beauties, and solid state electronics generally, is nothing short of amazing. There’s even a fringe “prepper” movement I’ve heard of that is intent on keeping their Z-80 machine language coding skills sharp. They did the analysis, and determined the vast majority of microprocessors buried in landfills are Z-80s, so after the Apocalypse, they plan to dig them out and get a jumpstart on rebuilding modern society. I’m not making this up :) Edited 2020-10-02 02:42 by RetroJoe Enjoy Every Sandwich / Joe P. |
||||
PeteCotton![]() Guru ![]() Joined: 13/08/2020 Location: CanadaPosts: 543 |
Lovely. An old BBC Master. That brings me back to my school days. Well they were technically "just" the plain old BBC micros we had - but what a great design. It felt such high quality compared to the world of spectrums and Orics (not knocking either of those - different price range). And Elite - genuinely the first game to make me jealous of my BBC Micro owning buddy - until they finally released an Amstrad version. |
||||
thwill![]() Guru ![]() Joined: 16/09/2019 Location: United KingdomPosts: 4311 |
The BBC Micros (this is one of the last of the line, a BBC Master 128) were originally a yellow off white, though not as bad as this one is now. Life is too short, and the weather too poor for Retrobriting. She has however had a complete service and is tricked out with a Raspberry-Pi co-processor and a compact flash hard-drive. The keyboard is basically indestructible as it was designed for school children to pummel on (the original BBC Micro keyboard is even more robust, they had started cost-cutting by the time some of the Master's were made). Not that she gets much use now, she basically serves as a vaccination against buying any more retro-computers. Yeah ... I think they're nuts. Best wishes, Tom Edited 2020-10-02 03:37 by thwill MMBasic for Linux, Game*Mite, CMM2 Welcome Tape, Creaky old text adventures |
||||
JoOngle Regular Member ![]() Joined: 25/07/2020 Location: SwedenPosts: 82 |
Hah, I don't even know Z80 assembly, but I got shelves full of Z80 processors and its variants (not for sale, sorry future browsing eyes). In fact, I got thousands and thousands of MCU's I've collected from electronics stores that have closed down over the years. |
||||
mkopack73 Senior Member ![]() Joined: 03/07/2020 Location: United StatesPosts: 261 |
So I looked closer through the code last night... It generally falls into several categories: 1) stuff that isn't needed (like the copy protection) 2) stuff that provides VERY low-level functions - like stuff related to calculation SQRT, matrix math, trig functions, etc, stuff to draw points, lines, draw text on the screen, read keyboard input, and so on. Basically a lot of things that are built in functions in MMBasic, so should be relatively easy to directly port over. 3) Stuff related to the ships and such - the various data like hull points, shield strength, etc, and the geometry data for drawing them. This largely should be able to be turned into sequential data files and read into arrays. Should be relatively straightforward to do. 4) higher level game functions and the main loop - these all build on top of the others. I think the biggest headache is going to be figuring out what they're trying to achieve in each of the functions when they're doing all the bit twiddling and A/X/Y registers/stacks in assembly. The comments and the "deep drive" documents will be very helpful in figuring this stuff out. We also don't have to go nuts because we have 32 bit integers where they were dealing with having to do math with low byte, high byte and sign byte breakouts for the numbers. So, yeah there's a good amount of work, but it's not as bad as it would seem at first. I'm betting nearly half of the code is either not needed or is a direct "replace their 10+ line assembly function with a single MMBasic function call" There's also a BUNCH of rendering tricks that they had to do to get decent performance in the graphics (like XOR'ing the previous draw to blank it out before drawing the next frame) etc. Even just drawing circles and arcs was a challenge for them back then. Should be MUCH MUCH easier for us now. My hope is that at least a slow working version of this can be done 100% in BASIC and then portions can be optimized in CSubs if needed to get it working faster. I only ever played the C64 version (and the later Amiga version of Elite Frontier) and it's been a long time. There's a version that plays the BBC Micro version in a web page emulator (-R&c[0=AT1mWTEgLBV9CLfAjirMm62GKWd51PR1vCBCzAL0laS6v7-eT0KvFEG1nRQwfwCSkj7y8OpKnlDW7ORFG3qKyD-sscjPWwIyVIS41AxYq0loE871_t6s2ZNJp6swIOe_aVvunWhMU2cGZEJpziII7vMU0B6Ph-F-RwHere )that I'll have to play a bit to remember what some of the game aspects were so I can understand what they're talking about in the comments. That port for the DOS/Windows machines in C will also probably come in handle as a reference. Once I get a few other projects off my plate I'm probably going to start diving into this hard. Start small, port over all the support functions, the stuff for reading in the ship data, etc. and then build from there... Certainly would love to collaborate with others if anyone is interested... |
||||
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |