emkay Posted June 13, 2006 Share Posted June 13, 2006 and now I understand why every line will need its own LMS instruction... but .. hmm damn, i need to think on how to implement the march downward now... -Thom Empty Lines (Without DMA)? Adding empty lines on the top and removing them on the bottom looks like vertical scrolling aswell. Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 13, 2006 Author Share Posted June 13, 2006 as for a background, I was... _thinking_ of using the player/missile graphics to do this. to do some simple stuff like a planetoid and some stars....... this will probably completely relegate playfield graphics for the other stuff... but.. oh crap.. the horizontal/vertical smooth scrolling is gonna freak everything out, the bullet is gonna zig zag all over the place... hmm, maybe i could do a correction in the character set to have 8 character states to correct for the .... crap.. that won't take care of the vertical state either.. hmm damn, i am going to have to think about this, because I want to try to implement a working background, and missiles, and falling powerups.. i will probably have to use players in a most creative way..... hummm... Quote Link to comment Share on other sites More sharing options...
emkay Posted June 13, 2006 Share Posted June 13, 2006 but .. hmm damn, i need to think on how to implement the march downward now... -Thom Here you may use the full 48 char-width so you can scroll for an 8 chars width "for free" Quote Link to comment Share on other sites More sharing options...
Rybags Posted June 13, 2006 Share Posted June 13, 2006 Just have a DLIST with LMS for the lines the invaders occupy. Obviously, the H-scroll takes place over a wide range - probably best to seperate each line by 128 bytes. Some wastage occurs, but the advantage is that all you have to do is OR in the low 7 bits of the address to each LMS operand. Playing about with blank lines could be the way to go - alternatively adjusting the LMS addresses acheives the downward march as well. 1 player can double as the ship, and the shot. Leaving 7 other PMs for enemy shots (more than enough). Typically, you'd probably only have 1 powerup visible, so that's one player that gets "re-assigned" usage-wise for a time. For multi-shot, you could just re-use the missile - just have some logic in the code that tells the DLI routine where the H-pos change has to occur. But, you also have to factor in your VScroll value. Probably the best method is to have one DLI routine, have all colour and positional changes stored in tables for the DLI to lookup. Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 13, 2006 Author Share Posted June 13, 2006 am curious, if I am doing development in mac/65 and am loading the result from DOS, do I have to use the memlo as reported by SIZE? or can I actually cram stuff lower in memory? how low can I go? -Thom Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 15, 2006 Author Share Posted June 15, 2006 Working currently on the player graphic. I wanted the player to be able to have a temporary shield, so I designed two definite states, with and without shields, which will be rotated with the character set providing the animation. I am also reorganising the display list to something more proper for horizontal scrolling. I will be adding in the most basic player movement next. -Thom Quote Link to comment Share on other sites More sharing options...
Rybags Posted June 15, 2006 Share Posted June 15, 2006 You're better off using ATASM or one of the PC-based Assemblers, then you don't have to worry about clobbering your source code. Then, just load the resulting XEX from DOS (or run autoexec from the emulator). With MAC/65 you should stay well away from MEMLO. Also, extra memory is used during assembly. Effectively, you are in danger anywhere under about $3000 if using DOS. Page 6 is fine, not that you fit anything significant there. I'm doing my development in stages... just assemble everything to run around $4000-$6000, then do the shuffling about when everythings ready to put together. Re: Display list. Maybe define it like this: nn Blank lines (top of screen) LMS xxxx MODE 2 (score display) nn Blank lines (gap) LMS xxxx MODE 4 HSCROL (UFO) 3 Blank JUMP DLIST nnnn repeat the above sequence 20 or so times. The JUMP operand just points to the next instruction. Then, you just have to store into the JUMP instruction where you want the invaders to start. Invaders DLIST: HSCROL MODE 2 LMS nnnn (repeat xx times) For the remainder of the DLIST, have 4 blank lines with DLI. At this point, the DLI routine checks VCOUNT. When VCOUNT is where the ship should be, load ANTICs DLIST pointer to point to the ship's DLIST entry: HSCROL MODE 4 LMS nnnn JBV nnnn Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 15, 2006 Author Share Posted June 15, 2006 Thanks for the tip on atasm, Rybags! I've been trying all the various combinations of assemblers etc and I think this one will be a perfect fit for me! -Thom Quote Link to comment Share on other sites More sharing options...
Rybags Posted June 15, 2006 Share Posted June 15, 2006 invdlist.zip Sample program in Atari BASIC, with technique I described + DLI. Ignore the jitters, it's just because it's BASIC updating pointers (ie - slow, plus it should be done in VBI). It illustrates the technique I described above. The DLI routine checks VCOUNT and when it's at a certain point, forces the DLIST pointer to display the last line in Mode 2. Yellow lines are just colour change so you can see where the DLIs are being executed. Use a joystick - move left/right to move the central window of the display up and down. Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 15, 2006 Author Share Posted June 15, 2006 Thanks, I am looking at it right now! :-) -Thom Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 21, 2006 Author Share Posted June 21, 2006 Wanted to let you guys know, that I am still working on the game. I've been in the process of re-building it in ATASM on the Linux side, instead of using MAC/65 inside the Atari 800 itself. I got tired of being squinched into 40 columns. My current goal right now, is to refactor and get the invaders display working again, then work on getting the bottom half of the display working, and get player movement working. I have put together a more comprehensive set of system equates, merging information from the Programmers Card on De Re Atari, and the ATARI OS SYSTEM EQUATES file, from an internal Atari document dated March of 1982. I am modifying the memory map chart that I provided earlier, to more accurately reflect what's being used in the zero page, but it is nice to know that the top 128 bytes of page 0 are available "for user programs" I have attached a picture of a crater design that I am working on for the bottom half of the background. Talk to you guys soon, -Thom <-- doing a sketch of the bottom moon graphics Quote Link to comment Share on other sites More sharing options...
tjb Posted June 21, 2006 Share Posted June 21, 2006 <-- doing a sketch of the bottom moon graphics I like it! -tjb Quote Link to comment Share on other sites More sharing options...
tschak909 Posted June 29, 2006 Author Share Posted June 29, 2006 I've done the first little test of some vertical scrolling techniques using a moving ANTIC JMP instruction, so far it works, i just need to alter the counter on the up cycle slightly, but one question.. how do I make the scrolling completely smooth, with no jumps? -Thom Source: t01vscrl.zip ;; TEST PROGRAM TO TRY MY DISPLAY LIST THEORY.; ; NOTES;; 5 INVADERS LINES OF 8 PIXELS HIGH; 2 BLANK LINES BETWEEN EACH SEGMENT;; USING ANTIC MODE 2 TO SEE THE LINE DIVISIONS; .INCLUDE atariequ.asm UPCTRL = $80 ; UP LINE COUNTERUPCTRH = $81 ;DNCTRL = $82 ; DOWN LINE COUNTERDNCTRH = $83 ; UPDOWN = $84 ; GOING UP OR DOWN? *=$2000 JMP START ; ; DISPLAY LIST; DLIST .BYTE $70 ; 3 BLANK 8-LINES .BYTE $70 ; FOR THE .BYTE $70 ; BORDERUPJMP .BYTE $01,<UPBOT,>UPBOTUPBLNK .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINEUPBOT .BYTE $00 ; 1 BLANK LINE .BYTE $55,$00,$49 ; BONUS DISPLAY .BYTE $40 ; 5 BLANK LINES .BYTE $52,$00,$50 ; .BYTE $20 ; 3 BLANK LINES .BYTE $52,$00,$51 ; .BYTE $20 ; .BYTE $52,$00,$52 ; .BYTE $20 ; .BYTE $52,$00,$53 ; .BYTE $20 ; .BYTE $52,$00,$54 ;DNJMP .BYTE $01,<DNTOP,>DNTOP ; JUMP INSTRUCTION FOR MIDDLE OF SCREENDNTOP .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINE .BYTE $00 ; 1 BLANK LINEDNBOT .BYTE $00 ; 1 BLANK LINE .BYTE $41,<DLIST,>DLIST ; JUMP BACK TO BEGINNING OF DLIST AT VBLANK ;; MAIN PROGRAM;START CLDSCTR LDA #<UPBOT ; SET INITIAL COUNTERS STA UPCTRL ; LDA #>UPBOT ; STA UPCTRH ; LDA #<DNTOP ; STA DNCTRL ; LDA #>DNTOP ; STA DNCTRH ; LDA #$01 ; STA UPDOWN ;SDMA LDA #$3D ; STA SDMCTL ; SET UP PLAYFIELDSDLS LDA #<DLIST ; SET UP DISPLAY LIST STA SDLSTL ; LDA #>DLIST ; STA SDLSTL+1 ; SVBI LDA #$06 ; IMMEDIATE VBI LDY #$00 ; LDX #$06 ; JSR SETVBV ; LOOP JMP LOOP ;; VBI ROUTINE; *=$0600VBI TXA ; PUSH EVERYTHING ONTO STACK PHA ; TYA ; PHA ; LDA #67 STA COLOR2 LDA RTCLOK+2 ; GRAB REALTIME CLOCK VAL AND #$0 ; EIGHT VBI BNE VBDON ; SKIP IF THIS ISN'T OUR TIME. LDA #$00 ; ARE WE GOING UP OR DOWN? CMP UPDOWN ; BEQ GOUP ;GODOWN LDA #39 STA 712 DEC UPCTRL ; UPDATE COUNTERS FOR THE MOVE. INC DNCTRL ; LDA UPCTRL ; CLC ; ADC <UPJMP ; ADD THE LO BYTE OFFSET OF THE JMP INSTRUCTION STA UPJMP+1 ; UPDATE THE DLIST LDA DNCTRL ; CLC ; ADC <DNJMP ; AND AGAIN.... STA DNJMP+1 ; UPDATE THE DLIST LDA #$00 ; 124 LINES PASSED? CMP DNCTRL BEQ SETUP ; FLIP THE FLAG TO UP JMP VBDONGOUP LDA #23 STA 712 INC UPCTRL ; DEC DNCTRL ; LDA UPCTRL ; CLC ; ADC <UPJMP ; STA UPJMP+1 ; LDA DNCTRL ; CLC ; ADC <DNJMP ; STA DNJMP+1 ; LDA #$00 ; CMP UPCTRL ; BEQ SETDN ; JMP VBDONSETUP LDA #$00 ; SET FLAG TO UP STA UPDOWN ; JMP VBDON ;SETDN LDA #$01 ; SET FLAG TO DOWN STA UPDOWN ; JMP VBDON ;VBDON PLA ; TAKE EVERYTHING OFF OF STACK TAY ; PLA ; TAX ; JMP SYSVBV ; AND JUMP TO THE DEFERRED VBI VECTOR;; SCREEN MEMORY; *=$4900 .SBYTE " () "; BONUS DISPLAY .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " *=$5000 .SBYTE " !! !! !! !! !! !! !! !! "; INVADERS LINE 1 .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " *=$5100 .SBYTE " @@ @@ @@ @@ @@ @@ @@ @@ "; INVADERS LINE 2 .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " *=$5200 .SBYTE " ## ## ## ## ## ## ## ## "; INVADERS LINE 3 .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " *=$5300 .SBYTE " $$ $$ $$ $$ $$ $$ $$ $$ "; INVADERS LINE 4 .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " *=$5400 .SBYTE " %% %% %% %% %% %% %% %% "; INVADERS LINE 5 .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " " .SBYTE " & Quote Link to comment Share on other sites More sharing options...
Rybags Posted June 29, 2006 Share Posted June 29, 2006 I think the apparent jumpiness is just the emulator... I did another VBI that just did INC $230, LDA $230, AND #$7F, STA $230 and it looked a little stuttered as well. No need to push/restore registers on the stack, it's already being done by the OS. Quote Link to comment Share on other sites More sharing options...
xxl Posted June 29, 2006 Share Posted June 29, 2006 and now I understand why every line will need its own LMS instruction... but .. hmm damn, i need to think on how to implement the march downward now... inser blank lines into dlisplay list if you want 'march downward' then replace 1 blank line into 8 blank lines color will be unchanged if you use dli Quote Link to comment Share on other sites More sharing options...
tschak909 Posted July 2, 2006 Author Share Posted July 2, 2006 (edited) Greetings all, Am nearing the final revision of the playfield layout that I want. I thought I would paste a screenshot so that everyone here could see what I am working on. I have posted two shots, one with NTSC emulation, and one without, it's giving me a reference as to what I need to correct, graphics-wise. (yes, I am aware of the hanging pixel on the bottom invaders, I am using it as a special reference right now for a bounding box). <-- with NTSC emulation. <-- without NTSC emulation. t05scrtest2.zip <-- the screen test source code. Some further notes: I will be using players/missiles from this point on, to provide all the non-scrolling elements (this includes all the background elements, player missiles, the breakout ball, and any additional player missile states not covered here.. I will be needing to do some serious creative thinking to get all this working together.... but knowing that: I need a gun for the player I need a gun for the enemies (maybe a limit of two shooting at once.) I need a player for the breakout ball when it enters breakout mode at the very least, what do i have left over to draw background elements? (thinking) -Thom Edited July 2, 2006 by tschak909 Quote Link to comment Share on other sites More sharing options...
emkay Posted July 3, 2006 Share Posted July 3, 2006 at the very least, what do i have left over to draw background elements? (thinking) What about NOT using the scroll register? You would get the same effect, with the "ROL/ROR" technique on the visual chars. And doing a charmovent at all? One change per charmode line moves all "ships" in the same line. You can set a nice background then, and/or you can do shots via charmovement haveing the PM Fere for an additional underlay.... ... just a suggestion Quote Link to comment Share on other sites More sharing options...
tschak909 Posted July 3, 2006 Author Share Posted July 3, 2006 at the very least, what do i have left over to draw background elements? (thinking) What about NOT using the scroll register? You would get the same effect, with the "ROL/ROR" technique on the visual chars. And doing a charmovent at all? One change per charmode line moves all "ships" in the same line. You can set a nice background then, and/or you can do shots via charmovement haveing the PM Fere for an additional underlay.... ... just a suggestion What do you mean exactly? can you describe the technique to me in more detail? I'm not wanting to sacrifice a smooth scroll, but I don't have all the character set space in the world, either, to draw every concievable smooth scroll position against the background. I guess I just need more clarification on you as to what you mean? -Thom Quote Link to comment Share on other sites More sharing options...
Ghost... Posted July 3, 2006 Share Posted July 3, 2006 at the very least, what do i have left over to draw background elements? (thinking) What about NOT using the scroll register? You would get the same effect, with the "ROL/ROR" technique on the visual chars. And doing a charmovent at all? One change per charmode line moves all "ships" in the same line. You can set a nice background then, and/or you can do shots via charmovement haveing the PM Fere for an additional underlay.... ... just a suggestion What do you mean exactly? can you describe the technique to me in more detail? I'm not wanting to sacrifice a smooth scroll, but I don't have all the character set space in the world, either, to draw every concievable smooth scroll position against the background. I guess I just need more clarification on you as to what you mean? -Thom Lets say your alien consists of 2 chars (XY) on screen. Then spend one more => 3 Chars (XYZ) Preshift the bytes of the chars with ROR ( carry => 7. bit and 0. bit => carry): CLC lda X (byte 1) ROR sta ..memx_animation1 lda Y (byte 1) ROR sta memy_animation1 lda Z (byte 1) ROR sta memz_animation1 lda X (byte 2) ROR ..for all the 8 rows of the char ..8 times graphics 0 or 2*4 times for antic 4 To display a certain animation step copy the pre-shifted chars (animation_n) into the character mem. Quote Link to comment Share on other sites More sharing options...
emkay Posted July 4, 2006 Share Posted July 4, 2006 Lets say your alien consists of 2 chars (XY) on screen. Then spend one more => 3 Chars (XYZ) Preshift the bytes of the chars with ROR ( carry => 7. bit and 0. bit => carry): CLC lda X (byte 1) ROR sta ..memx_animation1 lda Y (byte 1) ROR sta memy_animation1 lda Z (byte 1) ROR sta memz_animation1 lda X (byte 2) ROR ..for all the 8 rows of the char ..8 times graphics 0 or 2*4 times for antic 4 To display a certain animation step copy the pre-shifted chars (animation_n) into the character mem. Exactly. A "faster" way may be to use all different animation steps, inlcuding the "Bit"-offset/vertical movement pre-shifted, to save cpu time with cost of memory. Let's say you want to have a real smooth and independent animation with four steps. You'd need 4 steps * 4 horizontal positions * 3 Chars * 4 different ships * 8 Bytes: It would take 1536 Bytes of Data. Without the scrolling, you may use the "playfied" for shots" and the PMg can be used for some Background graphics. Quote Link to comment Share on other sites More sharing options...
Rybags Posted July 4, 2006 Share Posted July 4, 2006 The approach you take should reflect what you want in the background. If all you want is a couple of dozen single pixel "stars", then the best approach would be to just keep your current scroll technique and split a PMG. If you wanted something more complex (e.g. moon, moving stars etc), then treat the background objects as software sprites. Draw those sprites under the invaders taking into consideration memory offsets and scroll values so that they appear stationary. As such, you would need preshifted definitions (4x) for each background Chr. Have AND masks available for the invader characters. Mix the data together, use pre-reserved characters for the resultant. Have a buffer to restore in between scroll / re-render phase. Quote Link to comment Share on other sites More sharing options...
tschak909 Posted July 10, 2006 Author Share Posted July 10, 2006 Well guys, after a lot of debugging, I have the horizontal scrolling motion working properly.. I have sped it up so that it could be seen. I have attached the code below, but basically my approach is this: * use the main line code to set global states, go left? go right? * use the VBI to update actions that need to happen per frame, update the zero page locations for current HSCROL and LMS positions. * use the DLI to update the HSCROL registers appropriately. it's coming along, bit by bit... now it's time to put in the first bits of player code (and no, this is NOT a final on the motion... I will be tweaking the motions using a lot of hand tables to give the illusion of speeding up and slowing down...) what do you guys think? -Thom T06PLMOT.zip Quote Link to comment Share on other sites More sharing options...
Plastron Posted July 10, 2006 Share Posted July 10, 2006 Hi, For the ground at the bottom if you make the last screen look the same as the first screen when you jump back to the begining it will not jump as it does now. This is how it is done in Plastron and the Metro Cross demo so it looks like continuos scrolling. Andy Quote Link to comment Share on other sites More sharing options...
Heaven/TQA Posted July 10, 2006 Share Posted July 10, 2006 looks good! Quote Link to comment Share on other sites More sharing options...
tschak909 Posted July 11, 2006 Author Share Posted July 11, 2006 muahahahahaha, THEY LIVE! After combining the horizontal and vertical scrolling techniques from the other code tests, I've been able to make smooth scrolling produce a nice silky smooth march both horizontally, and vertically.. the march ends once the invaders have marched all the way to the bottom of the screen..... Next up! Player motion! (the final animated character sets and motion vectors will come later after I have implemented more of the basic stuff.) -Thom T07INVMH.zip 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.