Subject: Re: [stella] 6502 ASM question... From: Thomas Jentzsch <tjentzsch@xxxxxx> Date: Tue, 10 Jun 2003 20:15:45 +0200 |
Dennis wrote: > I'm looking to implement Thomas' suggestion for Climber (having random > ladder placement) and I've run into a snag. I don't know if I'm > thinking too hard or if I've been looking at this so long that I can't > see a solution. Ah, good news! :-) > Am I making since??? Yes! (at least I think so ;-) (or are there constrains between the rows too?) > Does anyone know of a quick math method that would get this > combination? Right now I'm thinking I'll have to check each bit > individually. How quick do you need it? Do you want to calculate that on the fly? Else a simple loop should do. Here's some pseudo code: x = 18 // 19 not allowed due to reflected PF, right? do if newLadder() // (from random number generator) putLadder() // new ladder at x and x-1 x = x - 4 // skip next 4 positions else x = x - 1 // check next position while x > 2 Plus a check if there is at least one ladder. Have fun! Thomas _______________________________________________________ Thomas Jentzsch | *** Every bit is sacred ! *** tjentzsch at web dot de | ---------------------------------------------------------------------------------------------- Archives (includes files) at http://www.biglist.com/lists/stella/archives/ Unsub & more at http://www.biglist.com/lists/stella/
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [stella] 6502 ASM question..., chris koivu | Thread | Re: Re: [stella] 6502 ASM question., Dennis Debro |
Re: Aw: Aw: Re: [stella] Fwd: Star , Thomas Jentzsch | Date | Re: Re: [stella] 6502 ASM question., Dennis Debro |
Month |