LInePick and Child Objects

Blitz3D Forums/Blitz3D Programming/LInePick and Child Objects

I'm having some problems getting my proggie working correctly, but cant yet put it down to a certain bit of code. But.. I think it could be this..

I'm passing an object handle into a function that calculates the correct height, and positions it.

Function fixentity_height#(ent)
Pick=LinePick(EntityX#(ent),EntityY#(ent)+20,EntityZ#(ent),0,-30,0)
PositionEntity ent,EntityX#(ent),PickedY#(),EntityZ#(ent)
End Function


Works fine if its a parent object I'm passing to it, but I'm getting some strange results when I pass a child object.

(and I've defined a global variable when the object was first loaded)

Can anyone help explain why ?