sm.terrainHarvestable
Associated object type: Harvestable
Functions:
sm.terrainHarvestable.calculateInitialHash(uuid, world, position, rotation)
Calculates the initial hash of a kinematic. The initial hash identifies the kinematic by its initial world position, uuid and world id.
This hash will be unsalted. Usually kinematics created from script rather than from cell loading have their hashes salted with random numbers.
Parameters:
| Type | Name | Description |
|---|---|---|
| Uuid | uuid | The kinematic uuid. |
| World | world | The world the kinematic is in. |
| Vec3 | position | The initial position of the kinematic in world space. |
| Quat | rotation | The initial rotation of the kinematic. |
Returns:
| Type | Description |
|---|---|
| number | The calculated unsalted initial hash. |