StaticPlayer
classWhat a player starts with and crafts in hand; the game reads the one named Player
- load-only Usable only while mods load. The game seals these members once loading finishes, so a call or a write from a running world raises an error.
Fields
| Name | Type | Description | |
|---|---|---|---|
| hand_recipes | load-only | RecipeDictionary | Recipes the player crafts in hand |
| hotbar | load-only | StaticItem[] | Items put on the first hotbar row of a new player |
| tools | load-only | StaticItem[] | Tools always in hand; the three tool keys take the first three |
| light | load-only | StaticItem | Item whose logic lights the empty light slot |
| blueprint_item | load-only | StaticItem | Item that carries a captured blueprint |
| start_inventory | load-only | Inventory | Items a new player receives |
| start_researches | load-only | StaticResearch[] | Researches completed when a world starts |
Standard members (5)
These members are available on all classes of this kind.
| StaticPlayer.cast(object) | Trying to cast Object into StaticPlayer |
| StaticPlayer.get_class() | Return StaticPlayer class object |
| StaticPlayer.find(name) | Looks StaticPlayer up in db, nil when there is none |
| StaticPlayer.get(name) | Takes StaticPlayer from db, reports a miss to the log |
| StaticPlayer.reg(name, spec) load-only | Register a new StaticPlayer static object, or take the registered one of that name |
Inherited from Prototype (2)
- name read-only Object name
- Prototype:is_valid() Returns false once the underlying engine object has been destroyed
Inherited from Object (1)
- Object:get_class() Class of this object