Skip to main content

Hologram

The hologram are like Displays but instead of being in 2D, its in 3D. You can show objects in 3D with this.

Functions​


createCube​

Hologram.createCube( position, rotation, scale, color )

Creates a cube object

Arguments:

  • position [ Vec3 ] The position of the object.
  • rotation [ Vec3 ] The rotation of the object.
  • scale [ Vec3 ] The scale of the object.
  • color [ Color|string ] The color of the object.

Returns:

  • [ integer ] The id of the object.

createSphere​

Hologram.createSphere( position, rotation, scale, color )

Creates a sphere object

Arguments:

  • position [ Vec3 ] The position of the object.
  • rotation [ Vec3 ] The rotation of the object.
  • scale [ Vec3 ] The scale of the object.
  • color [ Color|string ] The color of the object.

Returns:

  • [ integer ] The id of the object

createCustomObject​

Hologram.createCustomObject( uuid, position, rotation, scale, color )

Like createCube or createSphere but you can pass any kind of object from whatever loaded mod! (Via UUID).

Arguments:

  • uuid [ Uuid ] The uuid of the object.
  • position [ Vec3 ] The position of the object.
  • rotation [ Vec3 ] The rotation of the object.
  • scale [ Vec3 ] The scale of the object.
  • color [ Color|string ] The color of the object.

Returns:

  • [ integer ] The id of the object.

createBlueprint​

Hologram.createBlueprint( blueprintJson, scale, offsetPosition, offsetRotation )

Creates a hologram of the given blueprint JSON.

Arguments:

  • blueprintJson [ table|string ] The blueprint JSON as a string or a LUA table.
  • scale [ number ] The scale of the blueprint relative to the real size, 1 is 1:1.
  • offsetPosition [ Vec3 ] The offset position from the hologram to place the hologram.
  • offsetRotation [ Quat ] The offset rotation from the hologram to place the hologram.

Returns:

  • [ table ] A table of ids for the effects that the blueprint consists of.

getObject​

Hologram.getObject( index )

Gets the object via Object ID and returns a table containing the data of that object or nil since it doesn't exist.

Arguments:

  • index [ number ] The object you wanna get its data.

Returns:

  • [ HologramObject? ] Either you get a table (so the object exists) or nil (so the object does NOT exist)