Just Jeff Posted July 24, 2016 Author Share Posted July 24, 2016 Use something other than the PosObject function to set the X positions. They tend to be trickier though, which is why it's easier to move the score to the bottom. See if you can wrap your head around the Early HMOVE demo. OK Thanks.. I looked through it for about 20 or 30 minutes and bits and pieces are making some sense to me, but not enough to even begin asking questions about it- except maybe one. It eliminates the extra scan line? You mention the comb line, but not the extra scan line as far as I saw. I played the demo and it didn't have the issue- so I'm assuming it does. Its pretty amazing. I've heard David Crane and other Atari, Activision programmers say how the comb lines annoyed them that there was nothing they could do about it. Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted July 24, 2016 Author Share Posted July 24, 2016 How are you doing with the two score routine? Well no progress. I haven't even tried beyond contemplating how I would do it. I've been working on more straight forward parts of the kernal- just shrinking the list of outstanding items where I can. Every time I contemplate the score band, I get the feeling that I'll probably go into a dead end, or inefficient direction. Do you know of any well commented source code that might help me figure it out? Quote Link to comment Share on other sites More sharing options...
+SpiceWare Posted July 24, 2016 Share Posted July 24, 2016 It makes it so that repositioning the object takes exactly the same number of scan lines regardless of the X position. That repositioning technique can be done with, or without, the "early HMOVE" trick. The early HMOVE trick is what removes the comb line. Brad Mott (originator of Stella) noticed this trick when he was trying to figure out why the title screen for He-Man didn't display correctly in Stella. Quote Link to comment Share on other sites More sharing options...
Omegamatrix Posted July 24, 2016 Share Posted July 24, 2016 Well no progress. I haven't even tried beyond contemplating how I would do it. I've been working on more straight forward parts of the kernal- just shrinking the list of outstanding items where I can. Every time I contemplate the score band, I get the feeling that I'll probably go into a dead end, or inefficient direction. Do you know of any well commented source code that might help me figure it out? Truthfully I was really excited with anyone having interest in the routine I wrote. What I had posted was more or less a mock up for Darrell, where he filled it in with PFx writes driven by loading with the fast fetch registers available with DPC+, and used the ARM processor to work the logic. When I looked back at what I have left in the other thread I realized it wasn't altogether too useful. So I rewrote it as a working routine that actually displays the digits, and also built the logic to process the playfield masks. I've just done a first pass at this point, and I need to optimize it a little further before I post anything. At this point I do have a working solution though. I was waiting to see if you were going to take a stab at it yourself, and I don't know if you were just looking for a solution or wanting to have a go on your own. Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted July 24, 2016 Author Share Posted July 24, 2016 Thanks.. Well, I would like to give it a shot, to be honest. But to be clear- and I think you can guess- I'm a novice with no programming experience (beyond Basic in high school and a one credit Q-Basic class in college.) So at this point reading someone else's code and over and over until I have a good grasp of it is useful as well- and frees up a lot of time. As you can see above, I'm also dealing with jitter caused by an HMOVE in the kernel. (I should just quarantine that player to the left and move on- but my game idea is so fluid I don't know if that would be ok- I think it would) Maybe I could try it with yours and/or Darrell' guidance? I could spell out what I think needs to be done and you could comment. What do you think- it might be too much to ask. Let me know.. (I hope I'm not being too presumptuous- I have a busy day ahead- just in a rush) Thanks! Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted July 24, 2016 Author Share Posted July 24, 2016 Hey I just read your reply again. If you like the idea of me using what you wrote, It would be silly for me not to. Couple that with the other stuff I said, that I would still get alot out of it just by comprehending it and correcting whatever you say is still outstanding . So I would definitely appreciate if you send me what you have! Thanks! Jeff Quote Link to comment Share on other sites More sharing options...
Omegamatrix Posted July 24, 2016 Share Posted July 24, 2016 Here try this. Two 6 Digit Scores.zip To use this in your program you will have to: 1) Include TwoScores.h underneath include vcs.h in your code. TwoScores.h has all of the code inside of it. 2) Have the Two Score Constants defined in your code. RAM_SCORE_HI_MED_LO, VERT_SEGMENT_HEIGHT, COL_BACKGROUND, COL_DIGITS 3) Have this ram for the scores and playfield designated in your code. pfMasks, leftScore, rightScore. The leftScore and rightScore are the binary coded decimal (BCD) values of your score. 4) Include the Macros for the code, data table, and kernel. TWO_SCORE_KERNEL, LEFT_SCORE_MASK_SUBROUTINE, RIGHT_SCORE_MASK_SUBROUTINE, DRAW_HORIZONTAL_SEGMENT, PF_MASK_TABLES. Make sure you leave some spaces to left of these macros to compile correctly. 5) Call the two subroutines that update the playfield masks. GetScoreLeftPlayfield, GetScoreRightPlayfield Take all that and see if you can get it working. 3 Quote Link to comment Share on other sites More sharing options...
tschak909 Posted July 24, 2016 Share Posted July 24, 2016 That's a nifty little chunk of code I'm gonna save that in my macros. -Thom Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted July 26, 2016 Author Share Posted July 26, 2016 (edited) Here try this. Two 6 Digit Scores.png Two 6 Digit Scores.zip To use this in your program you will have to: 1) Include TwoScores.h underneath include vcs.h in your code. TwoScores.h has all of the code inside of it. 2) Have the Two Score Constants defined in your code. RAM_SCORE_HI_MED_LO, VERT_SEGMENT_HEIGHT, COL_BACKGROUND, COL_DIGITS Thanks! First of many questions.. Could you elaborate on what RAM_SCORE_HI_LO doing? Also it looks like you define it, but don't use it. Edited July 26, 2016 by BNE Jeff Quote Link to comment Share on other sites More sharing options...
Omegamatrix Posted July 27, 2016 Share Posted July 27, 2016 Thanks! First of many questions.. Could you elaborate on what RAM_SCORE_HI_LO doing? Also it looks like you define it, but don't use it. "RAM_SCORE_HI_MED_LO" is used inside of the header (.h) file. Each six digit score uses 3 bytes of ram to hold its value. When I write a program I usually arrange those 3 bytes so that if I open Stella's debugger I can read the score as it appears on the screen. This is what I mean. Here you can see the ram score is orientated the same as it displays on the screen: There is restriction that the score has to be that way in ram. You will sometimes see the MSB and LSB interchanged like the modified screenshot below: Set RAM_SCORE_HI_MED_LO = 1 when the ram score is stored left to right (like the top photo). If you choose to store the ram like the bottom photo, then use RAM_SCORE_HI_MED_LO = 0. The purpose of RAM_SCORE_HI_MED_LO is to allow the user to have the choice between the two styles of ram storage for the score. Quote Link to comment Share on other sites More sharing options...
Omegamatrix Posted July 27, 2016 Share Posted July 27, 2016 Right now I am working on a new version of the routine. The next obvious move to make is to try to combine both the left and right score subroutines into one. I have already done that, but I will tinker around more before release. Right now I build the masks for the leftside and then do an adjustment at the end of the routine if it is meant for the rightside. This leads to a fairly uneven amount of cycles between the two routines. I am going to try to offset the bit patterns so that I can do a simple shift at the end for either left or right playfield masks. But I don't know when I will have time to get all this done. It's not particularly difficult, but I just need the time... Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted July 28, 2016 Author Share Posted July 28, 2016 But I don't know when I will have time to get all this done. It's not particularly difficult, but I just need the time... Take your time.. I can work on other parts of the game. Its starting to look sloppy just like my previous attempts. I have to figure out how to proceed. Quote Link to comment Share on other sites More sharing options...
Omegamatrix Posted August 6, 2016 Share Posted August 6, 2016 I just posted a new version of the twelve digit display here: http://atariage.com/forums/topic/255612-twelve-digit-display/ Quote Link to comment Share on other sites More sharing options...
Just Jeff Posted August 8, 2016 Author Share Posted August 8, 2016 Awesome.. I'm going to finish cleaning up my messy code before I attempt to add it or the program will just get too out of control. Thanks! 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.