object.anchorSegments

类型 布尔值
对象 线对象
display.*
版本 2024.3703 版
关键字 线、线段、锚
另请参阅 display.newLine()

概述

此布尔值属性控制 线对象 是否考虑 anchorXanchorY。此值默认为 false

示例

local star = display.newLine( 200,90, 227,165, 305,165, 243,216, 265,290, 200,245, 135,290, 157,215, 95,165, 173,165, 200,90 )

star.x = display.contentWidth * 0.5
star.y = display.contentHeight * 0.5

star.anchorSegments = true
star.anchorX = 0.75
star.anchorY = 0.25