Jump to content

Just Jeff

Members
  • Posts

    592
  • Joined

  • Last visited

Everything posted by Just Jeff

  1. Good Evening. Could you please elaborate on what these instructions do? macro.h SEG.U VARS Thanks!
  2. Right there on page 41. I can't believe I made basically the same mistake as I did when I tried to ENABL... I checked the HMOVE register over and over, but not HMBL.. Thank you.
  3. Thanks- I like that instruction link a lot... I think I could use some help figuring out why my ball doesn't move. In my start up code, I have: LDA #1 STA CTRLPF STA HMBL ;Ball Speed Then in the main loop I have: LDA #2 STA VSYNC STA WSYNC STA WSYNC STA WSYNC STA HMOVE ;Move Ball and this is in the kernel: CheckBall CPY Ball BNE NoBall LDA #2 STA ENABL NoBall Does anything look wrong? Its an HMOVE immediately after a WSYNC, 1 is a legitimate speed for HMBL. The ball shows up (sort of) but doesn't move.. Thanks!
  4. I started giving it a shot a couple of weeks ago and its not as hard as I thought it would be. Have you tried Kirk Israel's Atari 2600 101 on the programming page? I highly recommend it. He explains just about everything on a very basic level- understandable baby steps. If you've been going through other people's code and getting lost, its good for you as well. He's writing really basic stuff that you can figure out how to alter or add to pretty quick. Also, have you read through the Stella manual or Assembly in One Step?
  5. Thanks! Is it fair to say that the BITabs doesn't really produce anything useful here? The instruction causes consistent cycles, and also performs a mini-branch, but whatever value is the result, is not used- correct?
  6. Good Morning.. Can anyone explain this a little bit? I've never seen the DCP command before (looks like it means decrement and compare but I can't find documentation on it) Also, I have no idea how the .byte even does anything here. I thought .byte just placed data in memory. lda #HUMAN_HEIGHT-1 ; 2 15 - height of the humanoid graphics, subtract 1 due to starting with 0 dcp HumanDraw ; 5 20 - Decrement HumanDraw and compare with height bcs DoDrawGrp0 ; 2 22 - (3 23) if Carry is Set, then humanoid is on current scanline lda #0 ; 2 24 - otherwise use 0 to turn off player0 .byte $2C ; 4 28 - $2C = BIT with absolute addressing, trick that ; causes the lda (HumanPtr),y to be skipped
  7. Awesome. I get it. Thanks! My little games I've been trying to write always run into kernel issues so I'm sure it will come in handy.
  8. Thanks.. Its making some sense but: Are you saying some of the locations the stack pointer runs through are registers for graphics and other stuff? I guess I imagined that it only looks at program code locations. I think I have a good idea of the processor status register, but can't grasp why we would have Z the way we wanted for D1 for ENABL.
  9. Wow- that's really advanced. Pushing processor status on to the stack? I'm not sure why that would work since all I know is the stack keeps track of addresses for subroutines. Now, if I could only figure out why that ball isn't moving...
  10. Ug... Thank you- it works! Looks Like the Stella Programming Guide is wrong; The ball graphics register works just like the missile registers. Writing a “1” to the enable ball register (ENABL) enables the ball graphics until the register is disabled.
  11. Hello Everyone! I'm new to the forum.. It nice to be here. I've been trying to write my first program but ran into a seemingly simple issue that I cannot resolve. I have a playfield and two players that I can move but when I tried to add a ball, it never shows up. Here is the code: ;CheckBall ;CPY Ball ;BNE NoBall LDA #1 STA ENABL ;NoBall I put in the semicolons to rule out the other code as the issue. Shouldn't this code at least produce a vertical line? The Stella debugger does show the that it runs through the code. Elsewhere in the program I tried to get it to move as well: LDA #1 STA CTRLPF STA HMBL ;Ball Speed and... MainLoop LDA #2 STA VSYNC STA WSYNC STA WSYNC STA WSYNC STA HMOVE ;Move Ball Anyone know what I missed? Thanks!
×
×
  • Create New...