The black void behind Stage 1 in Unreal is gone, and by the end of the day all eight stage backdrops were in. Most of the work was in matching the browser game's light.
Study first, then copy
Each stage's background was first written up in detail: every layer, every moving part, what triggers it, and recorded numbers to check against. The key finding was that a background is fully determined by time, scroll and the mood change that starts with the boss warning. Boss health and attacks never touch the scenery, which is why a faithful copy is possible. The notes also list about 100 small behaviours that are easy to miss, such as one stage's destruction running on its own clock.
Each stage is compared with the browser at the same moments, on a scale of 0 to 255, leaving out the places where enemies and bosses appear. Stage 1 started at 37.4 with the black background and measured 3.3 once the scenery was in.
| stage | scenery only | after the glow rebuild |
|---|---|---|
| 1 | 2.95 | 2.72 |
| 2 | 2.29 | 2.10 |
| 3 | 3.95 | 3.99 |
| 4 | 2.78 | 2.60 |
| 5 | 4.33 | 3.22 |
| 6 | 2.84 | 2.75 |
| 7 | 2.21 | 2.02 |
| 8 | 2.25 | 2.26 |
Stage 3 includes redesigned background robots that no longer match the browser on purpose. The robots now stomp in, sweep beams down a tower, and bring it down block by block, with the same models and colours. The browser game stays as it was.
Lessons in matching light
- Stage 2's arches came out almost black. Switching off one browser feature at a time found the cause: the browser lights every surface with a built-in studio environment, and that soft reflected light is what makes the stone look grey and wet. Rebuilding it, fog included, fixed the arches.
- Stage 5 started at 9.46 and fell to 4.33. The browser draws the sky first and lets the ocean paint over it. Unreal treated the sky as a solid wall, hiding the far sea. Pushing it behind the water brought the horizon back.
- Stage 6's marble sparkled. It has a glossy coat, and in the browser the coat stays smooth while only the stone under it carries the surface relief. Unreal had put the relief on the coat.
- Stage 6's glass tablets showed noise. Hiding materials one at a time traced it to the glass covers. Unreal gives transparent surfaces only one main light, so they missed the light that gives them their sheen. The glass now calculates it itself.
Two bugs in the original turned up too. The browser's snow, ash, ember and dust layers are never drawn, because a small construction bug makes the graphics card skip them, and Stage 2's bubbles and drips are skipped the same way. Unreal keeps those layers but hidden, to match what players see.
The glow
Explosions first looked flat and small next to the browser's. Unreal's built-in glow works differently from the browser's, and no setting matched them, so the browser's glow was rebuilt step by step and Unreal's own switched off. That fixed the explosions and, as the table shows, brought most of the scenery closer too.
The whole particle system now runs in Unreal. Deaths happen in two stages, as in the browser: the blast, then the enemy breaking into its actual model pieces, which tumble away trailing fire and smoke. The game logic already knew where every piece flies, so they land where the browser's do.
The models move
Until that evening, every ship stood still in Unreal. The animation for all 76 models was already proven identical across more than 15 million values, and now it drives every model on screen from the same inputs the browser uses: speed, aim, warning glow, health and broken parts. Torn armour and broken boss limbs now leave the hull as their own pieces. Before, a broken scorpion tail segment was drawn as the scorpion's whole body, a large red wreck the browser never showed.
A brightness limiter
A fully charged shot in the second stage turned the whole Unreal screen white. The shot was correct: it is that big in the browser too, which is why the browser footage used for comparison is captured through a limiter built for trailers. The Unreal game now ships with one always on.
Very large glows are kept to a sensible size, screen flashes are capped at a gentle tint, and every frame is measured as it is drawn. A first full-stage measurement still showed a few white frames per blast, because the measurement happens a little after the frame is drawn. The fix was to predict a blast's brightness from the effects about to be drawn and dim them the same frame, and to dim every glowing effect, not only the large round ones. Across Stage 1, the brightest frame went from 0.94 to 0.45 average brightness, and frames with more than half the screen lit went from 568 to none.
It is not finished. About one frame in a hundred still goes over the stricter targets as a blast starts, and other stages, the player's death and boss deaths have not been measured.
Caveats
Speed is unoptimised: Stage 1 runs at 22 frames per second on integrated graphics and Stage 2 at 37, and the other stages have not been timed. Some pieces also differ from the original: two lanterns in Stage 1's corner are missing, crystals have less contrast, and explosion rings are slightly less crisp. Late in the day a long test run crashed after about a minute, because meshes used for flying wreckage could be cleared from memory while still in use. They are held properly now, and later runs went to the end.
The 72 recorded playthroughs and the full suite of 26,588,329 checks passed during the day. The last small change was not retested, since testing waits until every level is finished.
