Skip to content

ServerStorage

Server-only storage: objects here are never sent to players.

  • Inherits: Service → Instance
  • Creatable: No. It’s created with the game; use ServerStorage (import { ServerStorage } from '@rally/sdk').
  • Replication: Server only: it, and everything inside it, is never sent to clients.

Keep templates you clone into the world later, and anything players mustn’t see before it appears, in ServerStorage. Nothing here is simulated or drawn, and scripts inside it don’t run.

Inherited from Instance: name, archivable, id, className, parent, destroyed

Inherited from Instance: getPropertyChangedSignal, setAttribute, getAttribute, getAttributes, getAttributeChangedSignal, getChildren, getDescendants, findFirstChild, findFirstChildOfClass, findFirstChildWhichIsA, findFirstAncestor, findFirstAncestorWhichIsA, waitForChild, isA, isDescendantOf, isAncestorOf, getFullName, clearAllChildren, destroy, clone, toString

Inherited from Instance: changed, childAdded, childRemoved, descendantAdded, descendantRemoving, ancestryChanged, destroying, attributeChanged

import { Part, ServerStorage, Vector3, getChild, workspace } from '@rally/sdk';
const coinTemplate = getChild(ServerStorage, 'Coin', Part);
function spawnCoin(at: Vector3) {
const coin = coinTemplate.clone();
coin.position = at;
coin.parent = workspace; // players receive it now
return coin;
}
spawnCoin(new Vector3(0, 3, 10));