# PathFree

Landscape
4.6.5.0 CP
bool
int x1 X coordinate of the start point
int y1 Y coordinate of the start point
int x2 X coordinate of the end point
int y2 Y coordinate of the end point
Determines whether the path from the start point to the end point is free, meaning that no solid material is intersected by a directly line between those points.
All coordinates are global, even in local calls.
protected func ControlSpecial2() { var i, base; while (base=FindBase(GetOwner(), i++)) if (PathFree(GetX(), GetY(), GetX(base), GetY(base))) { Message("Ich sehe meine Basis!"); break; } if (!base) Message("Ich sehe meine Basis nicht :/"); }
Script of a special clonk: with key Special 2 he will tell you whether he can see one of his home bases.
GetMaterial
GBackSolid
GetPathLength
Sven2
2002-08