Skip to content

Function: add

The add() function performs addition, adding one number to another.

  • If both numbers are integers, the result will be an integer.
  • If either number is a float, the result will be a float.

Syntax:

<number>.add(<number>)

Example:

var.test_value = 5
var.new_value = var.test_value.add(6)

case true:
    // Render as: "New value: 11"
    return DEBUG, "New value: @var.new_value"