Page 1 of 1
Bd1 games and custom elements
Posted: Sat Apr 23, 2011 5:50 am
by subotai
Morning
I'm looking for bd1 engine games with custom elements. I know that there should exist games with growing walls, slime and acid. I also know that there are some games with "non-rounded" brick walls. I can't find any game, that supports the growing wall and I can't find any that supports the slime. Maybe somebody can help me. And do you know any other custom elements or effects for bd1 games?
Thanks in advance.
subotai
Posted: Sat Apr 23, 2011 11:10 am
by LogicDeLuxe
I first coded the acid in Crazy Dream 3 and later moved it to other engines. Crazy Dream 3 also supports slime, growing walls and the dirt mod. There are also voodoo dolls, but they are not coded very efficiently.
For the non-rounded bricks, they are like explodible steelwall and non-eatable dirt. Those are basically exploiting the unused elements of the BD1 engine, which do nothing. The only difference is, that the author of the game adjusted the graphics pointer to their needs. No One did this occasionally. No One Boulder 31 is one of them using non-eatable dirt.
Posted: Sun Apr 24, 2011 1:28 am
by subotai
Thanks for your reply

! Do you know if there are any other bd1 engine games that use the growing walls? And are there different settings for the slime permeability, or can I always set it to "0"?
Please, can you explain, how acid works? I read in the gdash-thread how I can get the speed of acid and the element that is eaten. But I don't know how to use this knowledge. Seems for me that acid spreads randomly.
Posted: Sun Apr 24, 2011 9:30 am
by LogicDeLuxe
subotai wrote:Thanks for your reply

! Do you know if there are any other bd1 engine games that use the growing walls?
I'm not aware of any.
And are there different settings for the slime permeability, or can I always set it to "0"?
I don't remember every detail about it. Permeability might well be fixed to 0 here.
Please, can you explain, how acid works? I read in the gdash-thread how I can get the speed of acid and the element that is eaten. But I don't know how to use this knowledge. Seems for me that acid spreads randomly.
It's really just a check against an unpredictable random number. Nothing special.
Posted: Mon Apr 25, 2011 3:07 pm
by subotai
Ok, the spreading of acid is really simple. But I'm not sure about the acid speed. In the CrLi-Tools I found out that if the acid speed is set to "0", the acid seems not to grow at all, and if it is set to "255", it seems to grow in every scan. So I would implement it like this:
Code: Select all
IF Acid_Speed > 0 then
BEGIN
IF random(256-Acid_Speed)=0 then
ACID_SPREAD;
END;
Sorry if this is a bit off topic.
Posted: Mon Apr 25, 2011 6:10 pm
by LogicDeLuxe
The code looks like this (from a disassembly not optimized for readability):
Code: Select all
T_2600 jsr P_2500 ; $2600 , $2500
cmp $03A8
bcs B_264E
At 2500, a random number is generated. 03a8 is the acid speed and right after the bcs is the spreading code, which ends at 264e.
So it's more like:
Code: Select all
IF random(256) - Acid_Speed < 0 then
ACID_SPEAD;
At maximum speed, a 1 out of 256 chance remains for each acid piece not to spread.
Posted: Mon Apr 25, 2011 6:34 pm
by subotai
Thanks a lot
You are good. I couldn't make it this far in my remake without your help. But, you know that

Posted: Wed May 04, 2011 8:04 pm
by subotai
Ok, the slime permeability in CrazyDream 03 is stored at offset $16 of the cave data. It uses a predictable random number. Using the value $00 for both starting seeds instead of $1E and $00 for PLCK games seems to work approximately fine, but I'm not sure about this.
Unfortunately, I can't check the code because I have no skills in assembly
subotai
Posted: Wed May 04, 2011 11:14 pm
by LogicDeLuxe
It should behave like BD2, iIrc, ie. the seed remains at whatever it is after the random placement.