Skip to content
Work in progress. These docs describe Spawnite at launch, and some parts are still being built.

readResourceAmount

readResourceAmount(entity, handle): number

What entity has of the resource now, as a number: 0 where it has none. A read of one entity’s own trait, so it takes no world; a view reads it with useResource.

Parameter Type
entity Entity
handle ResourceHandle

number