// SPDX-License-Identifier: MIT // Copyright (c) 2026 Incoprea // Unroll a cone into a sector // Not compiled or tested in-world // Setup: Place in a spare prim. Set base radius and vertical height. Owner touch prints results without altering the scene. // Stop / restore: Disable or remove. No prim properties are changed. // Notes: Excludes the base disk and material thickness. Useful for texture/layout reasoning, not manufacturing certification. // License: see LICENSE in this distribution. // Original Incoprea. MIT. Owner-only calculation. float RADIUS=2.0; float HEIGHT=5.0; default { touch_start(integer detectedCount) { if (llDetectedKey(0)!=llGetOwner()) return; if(RADIUS<=0.0||HEIGHT<=0.0) { llOwnerSay("Positive radius and height required."); return; } float slant=llSqrt(RADIUS*RADIUS+HEIGHT*HEIGHT); llOwnerSay("Sector radius="+(string)slant+"; sector degrees="+(string)(360.0*RADIUS/slant)+"; lateral area="+(string)(PI*RADIUS*slant)); } }