← 返回函数库

assetWidth

File 内置函数 已实现

说明

返回资产图像的宽度(像素)。

语法

assetWidth(assetPath)

示例

attr x = assetWidth(assetPath)

🎨 3D 预览 — 资源宽度

@StartRule
Lot --> primitiveCube(4, 4, 4)
        print(assetWidth("example"))
        color(0.6, 0.7, 0.8)