Lunar Lander – PiTrex / VecSim
In the light of a new Controller, conceived an realized by Sean Ferigan (Facebook group Vectrex Fans Unite), I started updating the Lunar Lander emulation used in PiTrex (based on Vec Sim).

Photo stolen from FB post – forgive me!
Following the original post I made on Facebook:
I just thought some “inner” workings might be interesting to more than only two people.
I’m trying to optimize the Vectrex output of Lunar Lander – and I’m actually succeeding.
As Graham suggested (and as I had already tried before reading his message), I’m trying to figure out which “landing” platforms are drawn and when.
The platforms are actually drawn twice: once as part of the landscape (one giant vector list from left to right), and separately, including the “x2”, “x3”, “x4”, or “x5” markers.
Since the separate drawings are done individually and not within the giant vector list, the display appears to be “off.”
It’s actually the giant list that is drifting slowly…
The current accuracy trick is that I do a Zero
before each horizontal line. Then all platforms align.
But regardless of what Graham says, within the landscape there are always about 20 places with horizontal lines – which means I zero 20 times instead of the needed 4.
Which, in terms of Vectrex timing, is a huge waste of time.
I haven’t been able to figure out a good way to reduce these.
Because:
a) The platforms (as they blink) are always present/not present for 16 cycles, so I have no good way to compare vectors.
b) The landscape can scroll and zoom – so the coordinates aren’t fixed.
(And some other stuff I’m not mentioning.)
The display now wobbles more than I’d like, and I’m looking for ways to speed things up.
Since the whole emulation is based on VecSim 0.8, I tried something this package is also “famous” for: SBT.
The idea is: well, if I can’t draw fast enough, maybe I can emulate faster and catch up on my missing cycles that way.
I got the (very basic) SBT version in VecSim to run – but it makes no real difference speed-wise.
So for the moment, I’m not pursuing it further – and I’m also not currently willing to invest more time into the SBT code generation.
But I know Graham has an ongoing project in that regard, so – who knows what will be next?
Instruction:
- Button #4 + #1
Enter Dip Switch Settings - Button #4 + #2
Self Test mode (not available) - Button #4 + #3
“Slam” - Button #4
Left coin - Button #3
Right coin - Button #2
Start and Abort - Button #1
Start - X-Axis
Rotate - Y-Axis
Propulsion
Video #1:
Video #2: