Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/remapper/src/model.ts>Text

A framework for Beat Saber map scripting.
Latest
class Text
import { Text } from "https://deno.land/x/remapper@3.1.2/src/model.ts";

Constructors

new
Text(input: string | TextObject[])

An interface to generate objects from text. Each object forming a letter in your model should have a track for the letter it's assigned to.

Properties

height: number

The height of the text box.

horizontalAnchor: "Left" | "Center" | "Right"

How the text will be anchored horizontally.

letterSpacing: number

A scalar of the model height which is used to space letters.

model: TextObject[]

The model data of the text.

modelHeight: number

The height of the text model. Generated from input.

position: Vec3 | undefined

The position of the text box.

rotation: Vec3 | undefined

The rotation of the text box.

scale: Vec3 | undefined

The scale of the text box.

verticalAnchor: "Top" | "Center" | "Bottom"

How the text will be anchored vertically.

wordSpacing: number

A scalar of the letter spacing which is used as the width of a space.

Methods

import(input: string | TextObject[])

Import a model for the text.

toObjects(text: string)

Generate an array of objects containing model data for a string of text.

toWalls(
text: string,
start: number,
end: number,
wall?: (wall: Wall) => void,
distribution?,
animFreq?: number,
animOptimizer?,
)

Generate walls from a string of text.