Bots and Simulations > DNA - General

Hive coding

<< < (4/6) > >>

Elite:
What are you talking about  :blink:

I'm not calculating in the condition - *.ties is a custom variable.

I store *.numties into .ties if the number of ties > *.ties
And break all ties if *.numties < *.ties

Meaning that as soon as the number of ties decreases the bot severs all ties

PS: Made an error in the code - it should be:


--- Code: ---*.numties .ties store
--- End code ---

not

--- Code: ---*.numties *.ties store
--- End code ---

Ulciscor:
Ahh very clever. Much simpler than what I was thinking, needing to send info and then delete ties; instead using the tie deletion as the wakeup signal. Awesome! :D

Apart from mundane problems this seems like a cool idea. (Mundane being bots dying, decreasing the tie count and waking up all the hibernated wraiths, for example)

Elite:
Bots dying:

A problem but not too unmanageable (if that's even a word). If a bot dies then there should be a good reason for it, and the hive should be woken to check if everything's OK. Bots die of natural causes anyway (pwaste) so there might be a few 'false alarms'. Might have them get the opinion of a Keeper before going on a feeding frenzy.
If the hive is being attacked and bots are dying then the hive should be woken up anyway  :D

You make a great devil's advocate Ulciscor  :evil:
Good for making sure that everything's completely foolproof  B)

Numsgil:

--- Quote ---
--- Quote ---cond
*.numties *.ties >
*.hibernate 1 =
start
*.numties *.ties store
stop

' If the number of ties is decreasing then delete all ties

cond
*.numties *.ties <
*.hibernate 1 =
start
*.tiepres .deltie store
stop
--- End quote ---

This won't work. At least not in 2.36 or earlier.
You CANNOT perform calculations of any type in the condition step of the gene.

Num may have incorporated this ability into 2.4. Not sure though.
--- End quote ---
Yes, that's exactly what I did.

Elite:
Physics in 2.4 seem entirely different too - my bots just seem to slide everywhere and tie to random things for some reason  :wacko:
Maybe it's just me  :D
Sizes have changed - you can get nearly invisibly tiny bots

Anyone have any comments on *.numties method

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version