forked from Mirrors/openclonk
butterflies are not attracted to underwater plants
parent
76427c0b82
commit
9a9b7fe8be
|
@ -44,6 +44,8 @@ private func GetAttraction(proplist coordinates)
|
|||
continue;
|
||||
if (plant->GetCon() < 30) // Too small
|
||||
continue;
|
||||
if (plant->GBackSemiSolid()) // Under water or covered with solid material
|
||||
continue;
|
||||
var width = plant->GetObjWidth();
|
||||
var height = plant->GetObjHeight();
|
||||
coordinates.x = plant->GetX() + Random(width) - width / 2;
|
||||
|
|
Loading…
Reference in New Issue