BBC Elite source, now fully documented and explained
Re: BBC Elite source, now fully documented and explained
Interesting stuff, I'm glad the Master version is amenable to a fun strategy at least, I take it the two ships that are worth 5 points are too rare to be worth seeking out? (I'm an elite newbie, that might be a silly question!)
Also curious that Braben and Bell left in what is effectively a cheat code to instantly get to witch space. I imagine with space so tight that was a big decision, presumably that area needed heavy testing.
Also curious that Braben and Bell left in what is effectively a cheat code to instantly get to witch space. I imagine with space so tight that was a big decision, presumably that area needed heavy testing.
Re: BBC Elite source, now fully documented and explained
Yes, the Constrictor only appears in mission 1, so that's once in the entire game, and while the Cougar can appear throughout the game, it is super-rare. This article describes just how rare:
https://www.bbcelite.com/deep_dives/the ... ougar.html
Good luck tracking that down!
True, though the save file does record whether this cheat has ever been used, so you couldn't use it to cheat your way to winning their competition - at least they slammed that door shut. Check out bit 0 of the competition flags in this article for more info:
https://www.bbcelite.com/deep_dives/the ... _code.html
I'm glad they left it in, though, along with the author names on the title screen. I love a good easter egg!
Mark
Re: BBC Elite source, now fully documented and explained
For those following along, I have now released a version of the original 1984 BBC Micro Elite, with flicker-free ships and planets. It runs on a BBC Master, as there just isn't enough memory to squeeze the planet code into the original, but it's still the original, classic Beeb version.
Mark
- Play in your browser: https://bbc.godbolt.org/?model=Master&a ... ee-sth.ssd
- Download from my bbcelite site: https://www.bbcelite.com/hacks/flicker- ... loads.html
Mark
-
- Posts: 101
- Joined: Sun Mar 11, 2018 8:58 am
- Contact:
Re: BBC Elite source, now fully documented and explained
Awesome stuff Mark! Any chance it could work on a Model B with sideways RAM?
Re: BBC Elite source, now fully documented and explained
Oops! I posted this update to the wrong thread, meant to post it to the flicker-free planet one. I guess it works in both places.
Mark
Maybe! I’m thinking of trying to bundle the flicker-free code along with the music in a sideways RAM bonanza BBC Micro version. It should work…strawberrytau wrote: ↑Wed Feb 22, 2023 6:27 pm Awesome stuff Mark! Any chance it could work on a Model B with sideways RAM?
Mark
-
- Posts: 101
- Joined: Sun Mar 11, 2018 8:58 am
- Contact:
Re: BBC Elite source, now fully documented and explained
How hard would it have been to have implented a reward for achieving Elite? After all that was the purpose of the game and also the theme of the novel. Like an upgraded ship or immunity from vipers etc? That would be an incentive to carry on beyond mission 2.
Re: BBC Elite source, now fully documented and explained
It would be pretty easy. This logic only runs the specified code if you are ranked Elite:
Code: Select all
...
LDA TALLY+1
CMP #25
BCC skip
<insert code for Elite-only feature>
.skip
...
Given that the flight code has a few spare bytes, the authors could have wrapped a handful of features in this logic relatively easily, Viper immunity included!
Mark
Re: BBC Elite source, now fully documented and explained
you'd need a double byte for 6400 though?
Re: BBC Elite source, now fully documented and explained
Correct, the kill tally is stored in a double byte at TALLY and TALLY+1, but 6400 = &1900, so you only need to check the high byte in TALLY+1 to see if you are Elite. Same with all four higher ranks - they are all multiples of 256, so the high byte is the only one you need to check - it doesn’t matter what the value of the low byte is for this purpose.
See https://www.bbcelite.com/deep_dives/combat_rank.html for the low-down.
Mark
Re: BBC Elite source, now fully documented and explained
Do the space stations keep a hit tally like the ships?
Also can you jump out of hyperspace or to a new system?
Presumably Angus D. didn't add further missions?
Are there maximums for number of ships in local vicinity? (Apologies if I've missed that on the website).
One other question you might not have considered- how much of the planet names and details are preserved in Arcelite? Any plans to dissect that?
Also can you jump out of hyperspace or to a new system?
Presumably Angus D. didn't add further missions?
Are there maximums for number of ships in local vicinity? (Apologies if I've missed that on the website).
One other question you might not have considered- how much of the planet names and details are preserved in Arcelite? Any plans to dissect that?
Re: BBC Elite source, now fully documented and explained
No, they just have an on/off flag that determines whether or not the station is hostile (in which case it sends out Vipers and closes its docking bay so you can't dock). You can hit the station as many times as you like, but nothing gets through the shields.
You can force a mis-jump during hyperspace as mentioned above, taking you to a random spot in interstellar space, and you can then jump from there to a system, assuming you have enough fuel. Apart from that, you can only jump between systems.
Correct, there are no new missions in Elite-A.
There's always one slot for the planet and one slot for the sun or space station. Then there are 10 more slots for ships, unless you're on the 6502 Second Processor, in which case it's 18 more slots for ships (that's one of the reasons why this version is noticeably harder). See "Max. ships in the local bubble" here:
https://www.bbcelite.com/compare/featur ... rison.html
The exact same algorithm is used, so in theory the systems and details match exactly. This was one of the few things that got copied over from the original versions to the Archimedes version. This Acorn User article by co-author Clive Gringras is a great read if you want to know more:
http://elite.acornarcade.com/archive/inter.htm
I honestly don't understand the bit about having to make a 6502 emulator for the algorithm, as it's easy to replicate the procedural generation in modern languages (I've done it myself in Python, so they could have written it in C). But this is by one of the co-authors, so it's straight from the horse's mouth!
The same article talks about how most of the game is written in C, so I'm not sure I'm that interested in dissecting it. If I were going to jump ship to dissecting ARM code, I think I'd probably start with Lander, as that totally blew my mind, and is purely in ARM1 code...
Mark
Re: BBC Elite source, now fully documented and explained
I meant can you jump out of "witch space" or more unlikely jump from one system to another if done long enough?MarkMoxon wrote: ↑Fri Feb 24, 2023 12:04 pmNo, they just have an on/off flag that determines whether or not the station is hostile (in which case it sends out Vipers and closes its docking bay so you can't dock). You can hit the station as many times as you like, but nothing gets through the shields.
You can force a mis-jump during hyperspace as mentioned above, taking you to a random spot in interstellar space, and you can then jump from there to a system, assuming you have enough fuel. Apart from that, you can only jump between systems.
I did miss it thanks.Correct, there are no new missions in Elite-A.
There's always one slot for the planet and one slot for the sun or space station. Then there are 10 more slots for ships, unless you're on the 6502 Second Processor, in which case it's 18 more slots for ships (that's one of the reasons why this version is noticeably harder). See "Max. ships in the local bubble" here:
https://www.bbcelite.com/compare/featur ... rison.html
I'll have a read thanks, must have read it a long time ago.The exact same algorithm is used, so in theory the systems and details match exactly. This was one of the few things that got copied over from the original versions to the Archimedes version. This Acorn User article by co-author Clive Gringras is a great read if you want to know more:
http://elite.acornarcade.com/archive/inter.htm
I agree 6502 and ARM code are more appealing somehow.I honestly don't understand the bit about having to make a 6502 emulator for the algorithm, as it's easy to replicate the procedural generation in modern languages (I've done it myself in Python, so they could have written it in C). But this is by one of the co-authors, so it's straight from the horse's mouth!
The same article talks about how most of the game is written in C, so I'm not sure I'm that interested in dissecting it. If I were going to jump ship to dissecting ARM code, I think I'd probably start with Lander, as that totally blew my mind, and is purely in ARM1 code...
Mark
One more thing, did the energy unit or naval energy unit actually do anything? I could never tell.
Re: BBC Elite source, now fully documented and explained
What happens to the slots for the planet and sun/station in witchspace? Are they reserved, or do they get used for ships?MarkMoxon wrote: ↑Fri Feb 24, 2023 12:04 pm There's always one slot for the planet and one slot for the sun or space station. Then there are 10 more slots for ships, unless you're on the 6502 Second Processor, in which case it's 18 more slots for ships (that's one of the reasons why this version is noticeably harder). See "Max. ships in the local bubble" here:
https://www.bbcelite.com/compare/featur ... rison.html
An Electron asks because we didn't have witchspace...
Re: BBC Elite source, now fully documented and explained
Not 100% sure what you mean, but there are only two ways of moving between systems.AJW wrote: ↑Fri Feb 24, 2023 9:41 pmI meant can you jump out of "witch space" or more unlikely jump from one system to another if done long enough?
1. Normal hyperspace. You select a destination system, you hyperspace jump, and you arrive there.
2. Mis-jump. Rarely, hyperspace jumps go wrong, and you end up stranded in witchspace with a bunch of Thargoids. There are fewer particles of stardust in witchspace, so it's really obvious when this happens, and on the galactic chart you will find yourself at a random spot between systems, lost in interstellar space. You can escape witchspace by hyperspacing to a nearby system if one is close enough (and assuming the Thargoids don't get you).
That's it for travel between systems. You can also jump within a system, using "J", but you never leave the system that way.
They increase the rate at which your energy banks recharge, which really helps in the heat of battle.
No energy unit = recharge by 1 unit on each iteration of the main loop
Standard energy unit = recharge by 2 units on each iteration
Navy extra energy unit = recharge by 3 units on each iteration
Definitely worth having!
Mark
Re: BBC Elite source, now fully documented and explained
Good question! I had to check, and it turns out they are used to store ships (i.e. Thargoids and Thargoids) instead of the planet and sun.davidb wrote: ↑Fri Feb 24, 2023 10:25 pmWhat happens to the slots for the planet and sun/station in witchspace? Are they reserved, or do they get used for ships?MarkMoxon wrote: ↑Fri Feb 24, 2023 12:04 pm There's always one slot for the planet and one slot for the sun or space station. Then there are 10 more slots for ships, unless you're on the 6502 Second Processor, in which case it's 18 more slots for ships (that's one of the reasons why this version is noticeably harder). See "Max. ships in the local bubble" here:
https://www.bbcelite.com/compare/featur ... rison.html
An Electron asks because we didn't have witchspace...
The routines to spawn the planet and sun, which are normally called on arrival in a new system, are not called on arrival in witchspace, and instead Thargoids are spawned, starting with the first free slot (which is normally used by the planet). You always get four Thargoids and four Thargons on arrival in witchspace, so there is space for each Thargoid to release one more Thargon (which they do when their energy reserves drop, up to a maximum of 6 Thargons dropped by each Thargoid).
In witchspace, there are literally no suns or planets... just aliens.
Mark
Re: BBC Elite source, now fully documented and explained
So, any Space Dregers or Generation Ships ?!
Re: BBC Elite source, now fully documented and explained
That article isn't actually correct. ArcElite uses a C implementation of of the galaxy generation, not the 6502 code running under an emulator. It's also not exactly the same as the BBC code, there are a few minor bits it does differently.MarkMoxon wrote: ↑Fri Feb 24, 2023 12:04 pm
The exact same algorithm is used, so in theory the systems and details match exactly. This was one of the few things that got copied over from the original versions to the Archimedes version. This Acorn User article by co-author Clive Gringras is a great read if you want to know more:
http://elite.acornarcade.com/archive/inter.htm
I honestly don't understand the bit about having to make a 6502 emulator for the algorithm, as it's easy to replicate the procedural generation in modern languages (I've done it myself in Python, so they could have written it in C). But this is by one of the co-authors, so it's straight from the horse's mouth!
Thanks,
Christian.
Re: BBC Elite source, now fully documented and explained
Thank you Christian, that’s interesting. I wonder where Clive got that memory from? Perhaps an early version used the 6502 emulator as part of a simple lift-and-shift of the original source, and later they realised it wasn’t that complex and could be easily recoded in C. Remembering code history from the days before ubiquitous source control is always a tricky business!cjpinder wrote: ↑Sat Feb 25, 2023 12:03 amThat article isn't actually correct. ArcElite uses a C implementation of of the galaxy generation, not the 6502 code running under an emulator. It's also not exactly the same as the BBC code, there are a few minor bits it does differently.MarkMoxon wrote: ↑Fri Feb 24, 2023 12:04 pm
The exact same algorithm is used, so in theory the systems and details match exactly. This was one of the few things that got copied over from the original versions to the Archimedes version. This Acorn User article by co-author Clive Gringras is a great read if you want to know more:
http://elite.acornarcade.com/archive/inter.htm
I honestly don't understand the bit about having to make a 6502 emulator for the algorithm, as it's easy to replicate the procedural generation in modern languages (I've done it myself in Python, so they could have written it in C). But this is by one of the co-authors, so it's straight from the horse's mouth!
Mark
Re: BBC Elite source, now fully documented and explained
And no Raxxla, either. Ah, well…
Mark
Re: BBC Elite source, now fully documented and explained
Is the code for this described anywhere? I had a poke around bbcelite.com and didn't find anything...MarkMoxon wrote: ↑Fri Feb 24, 2023 10:30 pm Rarely, hyperspace jumps go wrong, and you end up stranded in witchspace with a bunch of Thargoids. There are fewer particles of stardust in witchspace, so it's really obvious when this happens, and on the galactic chart you will find yourself at a random spot between systems, lost in interstellar space. You can escape witchspace by hyperspacing to a nearby system if one is close enough (and assuming the Thargoids don't get you).
Re: BBC Elite source, now fully documented and explained
It is - here are the relevant parts of the code.BigEd wrote: ↑Sat Feb 25, 2023 12:19 pmIs the code for this described anywhere? I had a poke around bbcelite.com and didn't find anything...MarkMoxon wrote: ↑Fri Feb 24, 2023 10:30 pm Rarely, hyperspace jumps go wrong, and you end up stranded in witchspace with a bunch of Thargoids. There are fewer particles of stardust in witchspace, so it's really obvious when this happens, and on the galactic chart you will find yourself at a random spot between systems, lost in interstellar space. You can escape witchspace by hyperspacing to a nearby system if one is close enough (and assuming the Thargoids don't get you).
Hyperspace jumps are handled by the TT18 routine, which is called when the hyperspace counter runs down:
https://www.bbcelite.com/cassette/main/ ... /tt18.html
In the middle of this routine you can see a random number check that produces a mis-jump around 1% of the time, in which case the code jumps to MJP to show a second hyperspace tunnel and process a mis-jump into witchspace:
https://www.bbcelite.com/cassette/main/ ... e/mjp.html
It also jumps to MJP if CTRL is held down and the "pause and press X" cheat is enabled, in which case ptg is non-zero.
Hope this helps!
Mark
Re: BBC Elite source, now fully documented and explained
Excellent thanks!
Re: BBC Elite source, now fully documented and explained
Just noticed that you, Mark, were the editor in the Acorn User Elite special from 1995 which I still have. So one more thing to thank you for. It also mentions Starfighter 3000 for the 3D0 which Nathan Atkinson was kind enough to let me do the title screen for when it was later ported for RISC OS.
Re: BBC Elite source, now fully documented and explained
Such happy memories! I was so pleased to be able to put Arc Elite on the cover disc back then; I mean, the cover discs were generally OK, but the full version of Archimedes Elite? That was a real result! I was thrilled. Whoever negotiated that deal deserves an award (I think it came via the ad team - my memory is a bit unreliable here, but I don't think I can take any credit). I insisted on writing the articles about it myself, though; I couldn't believe that this was my job.AJW wrote: ↑Sun Feb 26, 2023 9:02 pm Just noticed that you, Mark, were the editor in the Acorn User Elite special from 1995 which I still have. So one more thing to thank you for. It also mentions Starfighter 3000 for the 3D0 which Nathan Atkinson was kind enough to let me do the title screen for when it was later ported for RISC OS.
And Starfighter 3000 is absolutely another seminal Arc title. Respect is due for the title screen!
Mark
Re: BBC Elite source, now fully documented and explained
It'd be really interesting to add a column in your version features table for ArcElite. Hope I can find time to do some research and fill some of the entries in.
Re: BBC Elite source, now fully documented and explained
Have noticed that Arcelite doesn't seem to go beyond 13 craft maximum in range. Also the space station can be destroyed with cheat module. And there are 25 stated ships I think.
Re: BBC Elite source, now fully documented and explained
I've been wondering how much of the Second Processor version of Elite could run on my Supershadow add-on to a regular Beeb. The add-on provides all the RAM and general environment of the 6502 Second Processor, but without the CPU itself.
So anything constrained by memory would now be unconstrained, but things constrained by CPU power would still need to be limited. I'm interested in where this balance would fall.
It should be possible for example to run in MODE 1/MODE 2 to get the extra colours, so long as its not too expensive in processor time to draw with more colours. More ship blueprints would also fit in memory, but there may not be enough CPU time to animate as many active ships as on the Second Processor.
Recently I saw a comment about flicker-free planet drawing not fitting in a regular Beeb due to lack of memory, so that should also be possible with my add-on.
Do you guys have a general feel for how much the Second Processor version benefits from either the parallelisation of having two CPUs, or the faster speed and instruction set of the 65C02?
So anything constrained by memory would now be unconstrained, but things constrained by CPU power would still need to be limited. I'm interested in where this balance would fall.
It should be possible for example to run in MODE 1/MODE 2 to get the extra colours, so long as its not too expensive in processor time to draw with more colours. More ship blueprints would also fit in memory, but there may not be enough CPU time to animate as many active ships as on the Second Processor.
Recently I saw a comment about flicker-free planet drawing not fitting in a regular Beeb due to lack of memory, so that should also be possible with my add-on.
Do you guys have a general feel for how much the Second Processor version benefits from either the parallelisation of having two CPUs, or the faster speed and instruction set of the 65C02?