☁️
DreamTode
  • Introduction
  • Types
  • Primitives
  • Arrays
  • Assignments
  • Objects
  • Parameters
  • Functions
  • Declarations
  • Templates
  • Instances
  • Custom Types
  • Dynamic Arrays
  • Ownership
  • It
  • Examples
Powered by GitBook
On this page

Was this helpful?

Instances

The only mutable thing in DreamTode is an instance. Everything else is constant and unchangeable.

You can make an instance with the new operator.

new [x = 3, y = 2]

Then, you can reassign properties with the . operator followed by an assignment:

let position = new [x = 3, y = 2]
position.(x = 5)
position.y = 4
let scores = 3, 2, 5
scores.0 = 4
PreviousTemplatesNextCustom Types

Last updated 2 years ago

Was this helpful?