Skip to content

RecordsRead

class RecordsRead<T : Any>
Example
import rift.ecs.Persist
import rift.ecs.Persistent
@Persistent class Signature(@Persist val text: String = "")
on_world_start {
val read = Game.worldRecords.collection<Signature>().readAll()
Logger.info("${read.records.size} signatures in the guestbook")
read.unrestored.forEach { (key, why) -> Logger.warn("signature $key: $why") }
}
val records: Map<String, T>
val unrestored: Map<String, String>