How to use Amoebatime?

Everything about the various Boulder Dash tools, and other stuff created by the fans.

Moderator: Admin

Post Reply
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

How to use Amoebatime?

Post by subotai »

As I'd like to adjust my bd-clone a bit more to the bdcff I wonder how I can use the amoebatime.

That's my code:

Code: Select all

r:=random(Randomnumber);
IF RandomNumber=0 then AmoebaGrowing.
A big Randomnumber causes a slow growing.
But I think this is not how it works.
User avatar
Sendy
Member
Posts: 186
Joined: Sun Jun 17, 2007 10:33 pm
Location: Square Wave Heaven
Contact:

Post by Sendy »

Amoeba has two default growing speeds, slow and fast.

It begins in slow mode, and will enter fast mode after the amoebatime has counted down.

I'm sure one of the more technical minded can say what the probabilities of growth are in both states...
Watcher Kitty is always watching...
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

Thanks for your reply, Sendy!

I found this description:

http://www.elmerproductions.com/sp/pete ... /000A.html

I think (hope) I understood how it works.

The probability of slow growth is 4/128 and of fast growth 4/16.
I will change the probability after the given time has elapsed.

I use this code for each amoeba:

Code: Select all

For i:=0 to Amoeba.Count-1 do
     BEGIN
     r:=random(128);
     IF r<4 then AmoebaGrowing;
     END;
r will be a value between 0 and 3. So I can also use r to determine the direction of growing.

But I wonder why the default value of the amoeba slow growth time is 999. I thougt that the cave time was always a byte value. That means that the maximum cave time can be 255 sec, and a amoeba time bigger than 255 would not have any effect.

subotai
User avatar
cirix
Member
Posts: 284
Joined: Fri Feb 01, 2008 11:00 pm
Contact:

Post by cirix »

subotai wrote:But I wonder why the default value of the amoeba slow growth time is 999. I thougt that the cave time was always a byte value. That means that the maximum cave time can be 255 sec, and a amoeba time bigger than 255 would not have any effect.
In later engines, it was a 3-digit value, so it could be 999 at max.
cirix
User avatar
Sendy
Member
Posts: 186
Joined: Sun Jun 17, 2007 10:33 pm
Location: Square Wave Heaven
Contact:

Post by Sendy »

It just means that the default is that the amoeba never speeds up. Though most caves never use the default setting, as far as I can tell.
Watcher Kitty is always watching...
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

I just asked, because in my cave maps I always stored the "required diamonds" and "cave time" in one byte (0..255). At the moment, I keep it like this, so the maximum amoeba time can be 255 sec and not 999 sec.
Volutar
Member
Posts: 10
Joined: Wed Mar 25, 2009 11:20 am
Location: Nizhnevartovsk, Russia

Post by Volutar »

I never seen fast-growing amoeba in classic BD1-3.
Have I missed something?
User avatar
LogicDeLuxe
Member
Posts: 637
Joined: Sun Jul 15, 2007 12:52 pm
Contact:

Post by LogicDeLuxe »

Volutar wrote:I never seen fast-growing amoeba in classic BD1-3.
Have I missed something?
Try BD3 first Intermission and Caves K and L! You really can't miss it in those.
Volutar
Member
Posts: 10
Joined: Wed Mar 25, 2009 11:20 am
Location: Nizhnevartovsk, Russia

Post by Volutar »

Yep, Intermission1 in BD1 amoeba starts to grow really fast.
I'm playing BD3 on ZX emulator, and magicwall/amoeba bug doesn't work (amoeba doesn't turn into jewels when magic wall is activated).
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

Two more questions about amoeba growing: Does the growing always start before the inbox hatching in all engines? And in which engines the slow growing timer starts after hatching (all engines but bd1)?
User avatar
LogicDeLuxe
Member
Posts: 637
Joined: Sun Jul 15, 2007 12:52 pm
Contact:

Post by LogicDeLuxe »

subotai wrote:Two more questions about amoeba growing: Does the growing always start before the inbox hatching in all engines?
Yes.
And in which engines the slow growing timer starts after hatching (all engines but bd1)?
Timer starts immediately in BD1, BD2 and PLCK. It starts at hatching for 1stB and CrLi. Also keep in mind, that in BD1, the timer also starts while the amoeba is dormant, while in all other engines, the timer does not start before the amoeba is released.
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

Thanks for your reply :D
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

One more interesting point:

If the amoebatime is set to 0, it will never enter fast growing mode in BD1, BD2 & PLCK games. In CrLi games, the fast growing starts immediately at hatching (when the amoeba timer starts). I don't know, how it is in 1stB-Games, but I can imagine that it is the same as in CrLi games.
User avatar
LogicDeLuxe
Member
Posts: 637
Joined: Sun Jul 15, 2007 12:52 pm
Contact:

Post by LogicDeLuxe »

subotai wrote:I don't know, how it is in 1stB-Games, but I can imagine that it is the same as in CrLi games.
Should be, as I didn't touch the timer. The same thing with magic wall time.
Also 1stB and CrLi is synchronous with the cave timer while BD1, BD2 and PLCK are independent. Thus even a 0 second timer can last for a fraction of a second, ie. until the cave timer ticks to the next second. Prof. Knibble probably did this change due to the bug in original BD where the timer is still ticking while in pause mode which can be exploited in some caves (accelerating the amoeba, stopping the magic wall).
subotai
Member
Posts: 251
Joined: Sun Jan 25, 2009 4:19 pm

Post by subotai »

I have two more questions about the amoeba growing.

Is the code for the amoeba the same in all engines?
LogicDeLuxe wrote:Also keep in mind, that in BD1, the timer also starts while the amoeba is dormant
Is this the reason, why an amoeba that is already enclosed before hatching can convert to diamonds?
Post Reply