kieranhj / pop-beeb Goto Github PK
View Code? Open in Web Editor NEWPrince of Persia port to BBC Master
Prince of Persia port to BBC Master
Player + guard sprites need a palette per bank
Guard colour exists as a concept already
Player colour kind of exists with Shadow player
There is a bug in the original Apple II version that should be fixed in the Beeb port. Details here.
Attract mode - intro sequence, title screen, credits, music, autoplay of demo level - etc. not yet implemented.
Check TurboMMC and MMFS for compatibility.
Ask Stew to check SmartSPI.
Can use Stardot folks to help with this.
On first screen, when the falling floor drops there are a couple of pixels that end up different between the two buffers, so flicker on & off.
Not sure what is causing this as all wipes etc. are supposed to last two frames to cover this. Needs investigating.
Currently double hi-res screens are clipped because there is only 320x192 screen buffer available.
However the original screens are effectively 280x192 which should be scaled up to 320x220 or thereabouts. Also need to decide if the double hi-res screens are going to be MODE 1 or MODE 2 (ask Dethmunk.) Finally need nice horizontal wipe between double hi-res screen as per original.
Opponent's health bar uses MLAY_AND and MLAY_STA variations of sprite plotter to draw energy 'bullets' mirrored. These are not currently implemented on Beeb so are drawn awkwardly in the middle of the screen (to avoid running off the edge unclipped and trampling SWRAM.)
These reduced sprites look a bit crappy anyway and the routine is set up to draw bullet sprites in batches of 1 - 3. Can replace these with something nicer and Beeb specific that is conveniently character column aligned etc.
Also need to decide if these will overlap last row of background or whether there is a separate status bar line.
Specifically unholy, reflection, bonesrise and mouse functions still be to ported.
Should have enough RAM now.
Cutscene system requires overlaying sprite banks
In addition some animation frame data and sequence tables were removed to save memory.
These could either be put back to be resident if there is now RAM otherwise need to be loaded on demand and overlaid with game level data (and restored.)
Once the final module layout has been completed, it is possible to change any function calls that are made between modules in the same swram to be direct rather than being vectored through the DLL stub. This will save ~80c per fn call.
Currently all builds have _DEBUG=TRUE for extra bounds checking etc.
Need to disable this and make sure the game still works!!
Because of memory constraints in the original Apple II version, some functions are located in different modules from where Jordan intended. I would rather co-locate the routines together if possible as this can reduce the DLL stub call overhead.
Also leads to some strange multiple indirections and confusing function names (FUNCTION, function, _function) across different modules.
Current keyboard layout is ZX:/;] Return.
Original Apple II keyboard layout is JLIKUO Apple.
Should there be an option to pick a layout or even define your own keys?
(Could be a config text file?!)
Assuming all goes to plan, the sprite engine should handle any 3 colours from full palette of 16 per sprite. This could look amazing using the NULA to provide 16 distinct colours from a palette of 4096.
Obviously the palette can be altered on a per level / screen basis as well.
Would need to work with Dethmunk to make the palette look amazing!
Search for these tags in the code and check whether they are relevant or need to be addressed.
This is implemented by briefly switching to lo-res screen cleared to a particular colour on Apple II.
For Beeb this will need a new system to handle palette changes at vsync - can just set all colours to flash colour to achieve this effect.
Would be nice to have an automatic versioning system so that for any given ssd I know which build version is on there. This would help keep track of any bug reports and addresses provided for exceptions etc.
The new thin red & white foreground pillars in the Palace levels doesn't seem to mask in front of the player sprite? Not sure what's happening here - need to check the plot mode in code and step through the fn.
The demo level plays itself - might "just work" if the game works but needs testing.
All player sprites were made half vertical resolution to grab enough RAM to finish porting the game.
Once the game is "completed" (but before the sprites are redrawn) must go back over and look closely at memory usage to free up as much as possible. Ideally return as many frames as possible back to full resolution - particularly where they look bad (e.g. static player or lack of detail.)
Currently half resolution to save RAM as part of player sprite bank but look awful.
Need to be put back to full resolution, which means selectively converting these.
The game JMP's directly to the attract mode from the gameplay loop this will likely be leaking the stack.
I imagine if the attract sequence plays for long enough the stack will overflow.
Seem to recall a TXS "patch" relating to the original game - check docs from rebuild/diff repo.
E.g. torches need to have a nice yellow, red, white palette
Ideally come up with a way for this to be specified as part of the art pipeline
Presume this is because of the selective sampling approach used by the autoconversion from Apple II sprites to Beeb MODE 5 format. It was all tuned for level 1, which is blue, so is probably skipping the orange pixels for level 4.
Can't get all the files onto a single DFS disc (31 files max) so need to move some to side 2.
The disksys library doesn't currently support this.
Need some way to play sound FX :)
The game timer is not implemented.
Original Apple II implementation assumes average frame rate of 11fps. Probably need something cleverer for the Beeb - can use OS timer most likely.
Make sure there is nothing missing (or unused / unnecessary) when everything has been ported.
Save game system needs implementing - load & save of game state
How does this work on Beeb disc system?
How do we handle write protected disc error?
Apple II has several hard coded (as sprites) messages for time left, game over etc.
These sprites look a bit crap and were removed to save memory but still need a solution for Beeb.
Can likely use the default Beeb font definition in ANDY (or overwrite it with something nicer.)
Need to figure out screen clear and box design etc.
When the player steps close to the mirror on level 4 sometimes get a vertical bar of white + red stripes. This means the clipping isn't working correctly with a certain set of parameters. Have also seen this when the Shadow player arrives on level 5. Also seen it whilst walking into a room on another level but can't remember exactly where.
Probably done whilst redrawing all of the graphics with Dethmunk but need to pick the right set of colours for all objects in the game and implement these as palette tables.
Think about palette for Dungeon vs Palace levels.
Would be nice to support pressing left & up together rather than having to use left+up key.
Original Apple II preferred joystick control. Implement joystick support for Beeb? If so, what interface?
If there is enough RAM then could add an extra character row to the bottom of the screen for the player & opponent health bars and time left messages etc.
Need extra 640 bytes in each buffer.
The ported control & cheat key system just doesn't work!
The double-buffer implementation isn't quite right.
Can observe tearing in the lower half of the screen when stepping frames occasionally.
Also when switching screens end up with the second to last frame being held during transition (lose last frame.)
Play the game extensively (or ask David the playtester nicely to do so) and record the maximum utilisation of all the image lists so can tune the buffer sizes appropriately. (Keep some spare just in case!)
There are some bespoke (hardcoded) FX (flame, post, hourglass, star twinkle) for the the Princesses room. These may have to be recoded for the Beeb screen.
For both player & enemy
Shadow man not implemented on level 4 (jump through mirror.)
Also check auto-playback of Shadow movement sequence on level 5.
Level 5; The game also crashes when I would drop down to the top of the starting room. (BRK at 203F)
It does not matter which side do I drop or fall down.
This is blowing the image list for bg sprites. Need to increase the buffer.
Not sure what potion FX are missing but obvious one is screen flipped upside down.
On Apple II this is implemented by just reversing the order of entries in the screen scanline look up table.
Unfortunately this isn't going to work on a Beeb because of the character based screen layout.
Might need some cunning approach involving self-mod code to hack the plot functions. :S
To be figured out. :)
When the time comes, ask Dethmunk to redraw all the sprites for MODE 2 resolution and 3 colours per sprite palette restriction.
Will need a simple texture build pipeline as currently working directly from Apple II source data.
Will need a PNG input and conversion.
The Princess & Epilog cutscenes etc. are not yet implemented.
Requires loading of temporary character sprite sets from disc and replacing afterwards.
Also requires loading a hires screen from disc (I think?) that isn't included in the repo (unless this comes from a different level? - need to find out :)
There should be a 'star' (comix) hit FX when player or enemy takes damage.
It is trivial to blow the peel buffers so these need to be enlarged.
Just walk on the two loose floor pieces on the second screen of the second level.
Currently the game won't load from a DataCentre - presumably because I'm trampling all over HAZEL RAM which is meant to be reserved for the FS. Would be nice to take a look at this.
Need a way to play nice music
@simondotm has VGM versions of the PoP tunes and has offered to help porting the music player from our previous demos.
Resource allocation is 3.5K from ANDY RAM (eventually.)
Most of the code uses SWRAM slots 0-3 which are mapped to banks 4-7 in standard Master setup. The DLL system is hard coded to use banks 6 & 7 for banks 2 & 3. Do one or the other, don't mix!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.