-
Notifications
You must be signed in to change notification settings - Fork 1
Adding texts
Oğuzhan edited this page Oct 3, 2021
·
1 revision
const text = new Entity(
new EntityData()
.setX(30)
.setY(30)
.setModel(
new TextModel(10, 10) // width, height
.setText("Hello World!") // text of model
.setFont("Impact") // font of text
.setColor("rgba(0, 255, 0, 0.5)") // color of text
.setPixels(16) // size of the text
.setMaxWidth(100) // maximum size of the text
)
); scene.addEntity(text); text.model.setText("Bye World!");