Data types that can be saved to ClusterScript.state or sent using ItemHandle.send.

Specifically, numbers, strings, booleans, Vector2, Vector3, Quaternion, PlayerHandle, ItemHandle, arrays of the aforementioned types, and objects having keys assigned with strings are Sendable.

Example

$.state.exampleKey1 = 1; // Write a number
$.state.exampleKey2 = "hello"; // Write a string
$.state.exampleKey3 = true; // Write a boolean
$.state.exampleKey4 = { foo: "bar" }; // Write an object
$.state.exampleKey5 = [1, 2, 3]; // Write an array
$.state.exampleKey6 = { // Write a complex object
array: [1, 2, 3],
object: { foo: "bar" },
};

Example

itemHandle.send("message1", 10); // Send a number
itemHandle.send("message2", "hello"); // Send a string
itemHandle.send("message3", true); // Send a boolean
itemHandle.send("message4", { foo: "bar" }); // Send an object
itemHandle.send("message5", [1, 2, 3]); // Send an array
itemHandle.send("message6", { // Send a complex object
array: [1, 2, 3],
object: { foo: "bar" },
});

Generated using TypeDoc