Plant Sensors

In my lispgamejam game I am programming right now, plants are propagating/spreading out, but they will be being eaten by insects, so a plant might live longer if it runs-away-from other plants which might be a source of insects. Relating to Braitenberg’s Vehicles agents’ sensors.

The way I am thinking about this is, like Ksaj pointed out, like Conway’s game of life (game? lispgames?). But where Conway’s game of life has one thing, and considers its eight-connected neighborhood, I want my plant agents to “use sensors” intelligently.

The setup for the software-individuals stuff I use relates to my second devlog if you are wondering how to get started.

Sensors that count other agents in regions

I think the simplest-ish choice for sensor regions is like this

b
b
aabcc
aabcc
ddddeeee
ffghh
ffghh
g
g
where each letter is one masked sensor region. I chose to preserve area of the mask, resulting in straight line views being twice as long as the corner regions. It is pretty arbitrary. I kind of like the idea that there is some kind of weaker long range decision-making effect.

Adding a plant thingtype to game-kb board

put plant type thingtype

Qualitatively best directions

So imagine a, b, d and g sensors found the least other-plants.

b
b
aab
aab
dddd
g
g
g
g
Then, I guess the plant propagates to one of these uniform-randomly is a simple mechanism. I guess I will call these masks characteristic range 2 (instead of 4) so that the different ranges are just counting numbers.
put plant attributes {sensor-range}

Separating sensors from movement

I had the idea that the sensor-range and propagation-range (and any other range we come up with), while they must correspond could be different. ( say, a slow, continuously-growing plant might only propagate in this window:

ab
d
g
addmember (get plant attributes) propagation-range

Add success rates

I want to have a knob I can turn that can either slow down or speed up plant growth, so I guess there will be a successful propagation ratio: Maybe everything can be random like that

addmember (get plant attributes) propagation-success
addmember (get board contents) plant
writefil board

Future insects and birds

I expect insects and birds to use exactly the same mechanism.

Insects

I figure insects will basically propagate/spread out like plants, rather than migrate as a unit. As well as spreading, insects will eat plants (with some rate of killing the plant) or starve (with some rate of dying when they don’t eat) as well as having some rate of propagating towards plants. I guess they have a distinct eating-range.

put insect type thingtype
put insect attributes {sensor-range, propagation-range, eating-range, eating-morbidity, starvation-morbidity}
addmember (get board contents) insect
writefil board
loadk board

Birds

I have the idea that birds would have three advanced characteristics: Choosing between seeking to eat and seeking to sleep based on relative hunger/tiredness but this might be adding too much. Further, using the same dynamic, my idea is to include the feeling of moving by normally removing the old location after they propagate, or with a low probability, leaving it behind (a new juvenile bird).

put bird type thingtype
put bird attributes {sensor-range, propagation-range, eating-range, eating-morbidity, hunger-morbidity, nest-natality, hunger, fatigue, fatigue-morbidity}
addmember (get board contents) bird
writefil board
loadk board

Just tabling them so I’m not just saying things:

sensor-rangesquare root of the sensor area
propagation-rangehow far the next bird appears
eating-rangehow far away insects can be eaten
eating-morbiditywhether all the insects are gone
hunger-morbiditychance of dying from hunger
nest-natalitychance of leaving behind a new bird
hungeramount of hunger (?)
fatigueamount of tiredness (?)
fatigue-morbiditychance of dying from tiredness

See you at the show / gamejam / Mastodon

No, I don’t know what’s going on with the markdown tables.