// SPDX-License-Identifier: MIT // Copyright (c) 2026 Incoprea // Waterline clearance gauge // Not compiled or tested in-world // Setup: Owner-touch a rezzed prop. Read the two measurements in owner chat. // Stop / restore: Remove/disable; this only reads environment data. // Notes: Measures simulator terrain/water at the object position, not a mesh pool or animated decorative water surface. Negative water depth means terrain is above water. // License: see LICENSE in this distribution. // Original Incoprea. MIT. Not compiled or tested in-world. default { touch_start(integer n) { if(llDetectedKey(0)!=llGetOwner())return; vector p=llGetPos(); float water=llWater(ZERO_VECTOR); float ground=llGround(ZERO_VECTOR); llOwnerSay("Center above water: "+(string)(p.z-water)+" m; water above terrain: "+(string)(water-ground)+" m."); } }