Skip to main content

uimod3d.attach

Overview

  • Attaches a Cohtml HTML view on a 3D plane mesh to the specified actor. The plane renders the HTML content as a texture in world space.

Metadata

FieldValue
DisplayAttach 3D UI Mod
Categoryuimod3d
AccessPublic
ScopeB1Standalone
Tags
Aliases

Parameters

NameTypeRequiredDefaultDescription
entity_identityIdnoTarget actor entity_id (defaults to possessed Zoi)
urlstringyesCohtml URL to load (e.g. coui://mymod/ui/app/index.html)
widthintno1024Cohtml view width in pixels
heightintno1024Cohtml view height in pixels
offset_xfloatno0X offset from actor origin (cm)
offset_yfloatno0Y offset from actor origin (cm)
offset_zfloatno150Z offset from actor origin (cm)
pitchfloatno0Pitch rotation (degrees)
yawfloatno0Yaw rotation (degrees)
rollfloatno0Roll rotation (degrees)
scale_xfloatno1Scale along X axis
scale_yfloatno1Scale along Y axis
scale_zfloatno1Scale along Z axis
mesh_scalefloatno0.5Base mesh scale (0.5 = 50cm plane)

Returns

  • Return shape is not declared for this command.

Usage

await inzoi.cli.execute('uimod3d.attach', {
entity_id: 0, // optional
url: '',
width: 1024, // optional
height: 1024, // optional
offset_x: 0, // optional
offset_y: 0, // optional
offset_z: 150, // optional
pitch: 0, // optional
yaw: 0, // optional
roll: 0, // optional
scale_x: 1, // optional
scale_y: 1, // optional
scale_z: 1, // optional
mesh_scale: 0.5, // optional
});