IsSurfaceAbove
From scripting
Revision as of 07:03, 22 April 2017 by Nickpisca (talk | contribs) (Created page with " Function IsSurfaceAbove(BottomObj As Variant, TopObj As Variant) As Boolean If IsUpdatable(BottomObj) = False Or IsUpdatable(TopObj) = False Then IsSurfaceAbove...")
Function IsSurfaceAbove(BottomObj As Variant, TopObj As Variant) As Boolean If IsUpdatable(BottomObj) = False Or IsUpdatable(TopObj) = False Then IsSurfaceAbove = False Exit Function End If Dim BMeas Set BMeas = TheSPAWorkbench.GetMeasurable(BottomObj) Dim TMeas Set TMeas = TheSPAWorkbench.GetMeasurable(TopObj) Dim BCoord(2) Dim TCoord(2) BMeas.GetCOG BCoord TMeas.GetCOG TCoord If BCoord(2) < TCoord(2) Then IsSurfaceAbove = True Else IsSurfaceAbove = False End If End Function