peteym5 Posted September 27, 2009 Share Posted September 27, 2009 (edited) One Faster way to clear 2k of memory is to do a partial code unroll, doing multiple stores per loop. Something like this LDA #0 TAY ClearLoop STA $00,Y STA $80,Y STA $0100,Y STA $0180,Y STA $0200,Y STA $0280,Y STA $0300,Y STA $0380,Y STA $0400,Y STA $0480,Y STA $0500,Y STA $0580,Y STA $0600,Y STA $0680,Y STA $0700,Y STA $0780,Y INY BPL ClearLoop I am not sure why you need to keep clearing Pages 0 & 1 during the main game play. Edited September 27, 2009 by peteym5 Quote Link to comment Share on other sites More sharing options...
analmux Posted September 27, 2009 Author Share Posted September 27, 2009 (edited) Some ground could be gained by optimisation of the scrolling. I assume the original doesn't just unpack an entire level into raw character data then just move the window over it? Exactly. It's unpacking the stuff on the fly. After scrolling 16 pixels to the right it starts to unpack new 'metatiles' from AreaData to the metatile buffers at $0500-$069f. I'd call this unpacking stage 1. After that there's another unpack, to explode the metatiles to real charcodes (2*2 chars for every metatile). This is unpacking stage 2. i.e. when you're writing characters to columns greater than 208 or so, also write them into columns starting at zero. When your window origin reaches position 208, set it back to zero. That way, you can have a level which can be infinitely long, and you can do H-Scrolling by rendering new data only and not having to perform any move operations. The MWP scrolling method is also possible in this situation. MWP even supports unlimited 8 dir scrolling, and it takes just one 1kb. Anyway, one idea could be to do the alternating antic 4 mode (13*2 charmode lines), using alternating fonts, and using the same starting address (LMS) for any pair of charmode lines. Then only 512 bytes per screen are needed (at max), and we could do a precompute of both scrolling stages 1 & 2 at once, and prepare 8 screens, to fill up 4 kb. I've never seen a SMB level longer than 16 screens, so it could be easily stage 1&2 unpacked in 2 runs. The first run is before entering the level, the executing of unpacking the 2nd run can be spreaded over many frames from the start. However, we could as well do just stage 1 unpacking and do wrapped scrolling instead, using 1kb (or 512bytes, if the software mode "double antic 4" is used). As far as I can see the stage 1 depack takes the most time of all stages. The NES still needs to do screen update buffer after stage 1 AND 2. So, maybe a nice solution is stage 1 unpacking: 16 screens at max. thus 4 kb of metatiles. These metatiles are needed for the mario - playfield interaction logic. The stage 2 unpacking can still be on the fly. The buffers aren't needed. We can also take advantage (regardless of the mapping method employed) of the fact that we can pre-render to the right of the visible window, doing a small bit each frame. Indeed. Spreading out will help a lot. On NES the code has activity peaks after scrolling 16 pixels, and this could cause flickering as when there's also 5 enemy sprites on screen, 1 vbi will take more than 1 frame of cpu time. So, using some logic, doing some precomputing and spreading the needed action would be the best, I think. The main problem of the software sprite rendering might be solved using some precompute engine, however in many situations the enemies show no regular behaviour. F.e. just one goomba walking left can be precomputed and stuffed in a special / separate font. 2 goombas will get more difficult, as when they encounter obstacles (say a pipe), it'd need to bounce back. The other goomba behind him will now bounce on the first goomba etc. ...we cannot always prepare for the bounce positions, and all the precompute engine can do is computing the rolled gfx for the 'non-overlapping' parts of any sprite. The bouncing parts must be computed in real time. In later levels we have the bouncing / flying turtles, and to precompute them all would be a real challenge. So, these must be rendered in real time. The same applies for enemy sprites falling from a tile boundary. Anyway, font flipping won't work in this case, I'm afraid. However, in totally different cases, font flipping COULD be a solution. But, if we'd take a look at precomputing the stuff, we really need some flexible engine. This is already a real challenge. Another solution could still be to minimize the peaks of the main screen routines, and try to use PM instead. Up till now that would be the easiest. Edited September 27, 2009 by analmux Quote Link to comment Share on other sites More sharing options...
analmux Posted September 27, 2009 Author Share Posted September 27, 2009 I am not sure why you need to keep clearing Pages 0 & 1 during the main game play. It'd only be needed inbetween starting a new level, or initializing the game, or doing a soft-reset. For sure not every frame or during play. Quote Link to comment Share on other sites More sharing options...
DracIsBack Posted September 27, 2009 Share Posted September 27, 2009 (edited) Looks great. One question though: I could have sworn there were earlier attempts to do both Super Mario Bros and Super Mario Bros 3 on the A8 that were eventually abandoned. Anyone else remember these?Maybe some learnings there. Edited September 27, 2009 by DracIsBack Quote Link to comment Share on other sites More sharing options...
TMR Posted September 27, 2009 Share Posted September 27, 2009 But, anyway to clear things up. I'm not sure if I'll spend the time to finish this idea of porting SMB over to A8. So, people please DON'T consider this as a new project for me Aw crap, now you say that! i wrote it up as news for Retro Gamer! Quote Link to comment Share on other sites More sharing options...
analmux Posted September 29, 2009 Author Share Posted September 29, 2009 I removed the files from my ftp space. I temporarily put them there as on PC I couldn't attach the files to a post. On laptop I can attach them, so here are the files of all the 7 smb port tests. Have fun. Quote Link to comment Share on other sites More sharing options...
miker Posted February 5, 2010 Share Posted February 5, 2010 Any progress? Hello! Quote Link to comment Share on other sites More sharing options...
analmux Posted February 5, 2010 Author Share Posted February 5, 2010 (edited) Any progress? Hello! Nope. But did you expect any? See these remarks from the first post: I'm wondering if at least a nice port would be possible But last days I've been thinking of possibilities of porting, and I'm interested in others' views. It could be a subtle difference, but these two sentences, i.e. the main idea of this thread, do NOT mean that "I AM GOING TO PORT SMB TO A8". What I was mainly interested in is whether others are interested in this idea, and if they have some ideas of how to solve some of the bigger problems.....or in other words, and maybe the question was a bit unclear, whether we could start some open-source project or at least a community project. But, the only reaction, be it rather indirect, was another thread about a PM multiplexer. You might remember a demo with a Mario-sprite and some enemies (SMB level 1-1). Edited February 5, 2010 by analmux Quote Link to comment Share on other sites More sharing options...
miker Posted February 5, 2010 Share Posted February 5, 2010 Ah, I see... Quote Link to comment Share on other sites More sharing options...
fibrewire Posted May 28, 2011 Share Posted May 28, 2011 Analmux: Any chance you can make your most recent .ATR of this + your modified source available? All the other links are dead now... All I could find is this This is FANTASTIC! Quote Link to comment Share on other sites More sharing options...
analmux Posted May 30, 2011 Author Share Posted May 30, 2011 Analmux: Any chance you can make your most recent .ATR of this + your modified source available? All the other links are dead now... All I could find is this This is FANTASTIC! Here you are...latest version (5) BTW, I feel a bit confused as I know my stuff was downloaded more than 66 times. No one else was helping you in the meantime. Quote Link to comment Share on other sites More sharing options...
fibrewire Posted May 30, 2011 Share Posted May 30, 2011 Thanks, I read your SMB threads several times - I'm guessing this is the post where I should have seen a download link... Quote Link to comment Share on other sites More sharing options...
fibrewire Posted May 30, 2011 Share Posted May 30, 2011 WOW! That really is a thing of beauty to behold on the Atari 800!!! Excellent work! Quote Link to comment Share on other sites More sharing options...
fibrewire Posted August 10, 2011 Share Posted August 10, 2011 either analmux is deleting his own links, or there are higher powers at work. I totally depend on AA to store all important things Atari. It's not hard to imagine Al getting hate mail from Nintendo's lawyers analmux: please post one more time so I can make the file STICK! Quote Link to comment Share on other sites More sharing options...
Allas Posted August 11, 2011 Share Posted August 11, 2011 smb3_finished.zip Quote Link to comment Share on other sites More sharing options...
fibrewire Posted August 11, 2011 Share Posted August 11, 2011 I'm looking for the SMB that looks like the top of page 2 of this thread... Quote Link to comment Share on other sites More sharing options...
Fres Posted August 11, 2011 Share Posted August 11, 2011 HAHAHA! Yeah, right. Quote Link to comment Share on other sites More sharing options...
BrianC Posted August 12, 2011 Share Posted August 12, 2011 ugh, I got off the iPad and went on the PC just to download that file only to find Bros. Quote Link to comment Share on other sites More sharing options...
fibrewire Posted August 13, 2011 Share Posted August 13, 2011 Source & Demo builds Look in the 'Uploads' directory for playable .ATRs SMB Hack.zip Quote Link to comment Share on other sites More sharing options...
Deteacher Posted August 13, 2011 Share Posted August 13, 2011 Can't seem to get it to run in Altirra. Can anyone help with correct settings please? Thanks in advance. Quote Link to comment Share on other sites More sharing options...
fibrewire Posted August 13, 2011 Share Posted August 13, 2011 Can't seem to get it to run in Altirra. Can anyone help with correct settings please? Thanks in advance. Setup as 64K 800XL System > Hardware > 800XL System > Firmware > 600XL/800XL System > Memory Size > 64K (800XL/1200XL) 1 Quote Link to comment Share on other sites More sharing options...
peteym5 Posted August 13, 2011 Share Posted August 13, 2011 (edited) I have been checking progress on this thing for years. I believe the only good way is to use a multicolor multiplexer. I have done some recent experiments and managed to animate 10 multicolor sprites that are 20 pixels high x 8 wide. I don't have time to get involved with this mario project. This is all done in VBI & DLIs. I am not sure how many sprites Mario had on the screen at once. mc_spritedemo.zip Edited August 13, 2011 by peteym5 Quote Link to comment Share on other sites More sharing options...
Deteacher Posted August 13, 2011 Share Posted August 13, 2011 Can't seem to get it to run in Altirra. Can anyone help with correct settings please? Thanks in advance. Setup as 64K 800XL System > Hardware > 800XL System > Firmware > 600XL/800XL System > Memory Size > 64K (800XL/1200XL) That did the trick! +1 rep for you! Wow! Very impressive, I must say. Keep up the great work! Another +1! Quote Link to comment Share on other sites More sharing options...
fibrewire Posted May 13, 2012 Share Posted May 13, 2012 (edited) I needed a smile today, so I necrobumped this after making it completely through the first level !!! I had someone play the real thing on an emulator next to me so I could see what to do. It would be cool if i could get the nes emulator synced with Altirra so the keyboard would be read at the same rate on both emulators. Good times on the A8 Edited May 13, 2012 by fibrewire Quote Link to comment Share on other sites More sharing options...
fibrewire Posted May 17, 2013 Share Posted May 17, 2013 This is really Super Mario Brothers for the Atari 8-bit computer. Someday it will be great, but until that day here is another yearly necrobump. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.