kisrael Posted January 24, 2015 Share Posted January 24, 2015 Has bB changed much, in how it handles variable? A long time ago I wrote a tutorial for making music Do Re bB http://www.alienbill.com/2600/basic/music/ - I made a simple little music engine, and then ported my Joust Pong theme music to it. I'm 90% sure I compiled http://www.alienbill.com/2600/basic/music/jpmusic.bas.txt and it made this binary: http://www.alienbill.com/2600/basic/music/jpmusic.bin But now it's different, the timing is off. Is it like the constants or the variables or something? I can't quite figure out why it's broken, even when I simplify for debugging purposes... (As another thing, in trying to hack it back into shape, I did a quick score = musicPointer but for some reason it always displays 61, even though the value of musicPointer is between 0 and 32, more or lessPlease help! I'd love to do a 2600 game for the Global Game Jam but if I can't get my head around this stuff I'll probably have to use something modern and boring! Quote Link to comment Share on other sites More sharing options...
kisrael Posted January 24, 2015 Author Share Posted January 24, 2015 So, I managed to get through my main problem by changing the logic so it didn't rely on having the data pointer be -1, just from 0 to 31 the score thing... is there a way to say "the value at this variable" rather than "the offset this variable is kept at" or am I missing something? Quote Link to comment Share on other sites More sharing options...
RevEng Posted January 24, 2015 Share Posted January 24, 2015 There haven't been any fundamental changes. dasm had an issue with negative numbers that was fixed and regressed at least once in the past. Did you use either the latest version at sourceforge, or the one with the bB version linked from RT's site? I managed to squash a lot of bugs with that release. I compiled the source you posted with that version, and the binary it produced was different than the binary you posted. I suspect the music isn't quite playing right, but I think that may be due to your data being a work-in-progress. Either way, the "mary had a little lamb" example compiled and played correctly for me. On to the score issue - It looks like the score code doesn't like receiving a variable as a direct assignment. (this appears to have always been so. I checked the pre 1.0 version) As a work-around this will add the variable... score=0 score=score+musicPointer ...but the variable should be BCD format, which isn't the case here. Personally I find it easier with this sort of thing to just adjust score at the same time as musicPointer is adjusted. 1 Quote Link to comment Share on other sites More sharing options...
kisrael Posted January 25, 2015 Author Share Posted January 25, 2015 Thanks. Yeah, I realized I was missing the BCD thing entirely - my bad, was trying to do too much too fast (gamejam speed I changed the music engine so it never relies on adding 1 to -1 to get 0 ; it just keeps the offset 0 or above Thanks for all the great work you've been doing on this. After being out of the loop for so long, it's heartening to see where it's gone and how little linkrot there is with your stuff and Random Terrain's... Quote Link to comment Share on other sites More sharing options...
RevEng Posted January 25, 2015 Share Posted January 25, 2015 You're welcome on the help, and no big deal on the work... it was just a matter of paying-it-forward for all of the great work put into bB from batari and early advocates like yourself. 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.