BlockLogic
classRuntime state of a placed block
- read-only Assigning to the field raises an error.
Fields
| Name | Type | Description | |
|---|---|---|---|
| map_register | boolean | Whether this block shows up on the map | |
| static_block | StaticBlock | Prototype this block was spawned from | |
| pos | read-only | Vec3i | Cell this block stands in |
| quat | read-only | FQuat | Rotation turning the block's local sides into world sides |
| state | read-only | integer | State shown under the crosshair, one of defines.block_state |
Functions
BlockLogic:find_accessor(name)
Find a registered accessor by name
| name | string | Accessor name |
returns Accessor
BlockLogic:accessors()
Every accessor registered on this block
returns Accessor[] Registered accessors
Standard members (4)
Every class of this kind carries these.
| BlockLogic.cast(object) | Trying to cast Object into BlockLogic |
| BlockLogic.get_class() | Return BlockLogic class object |
| BlockLogic.new(parent, name) | Creates a new BlockLogic instance |
| BlockLogic.new_simple() | Creates a new BlockLogic instance |
Inherited from Instance (1)
- Instance:is_valid() Returns false once the underlying engine object has been destroyed
Inherited from Object (3)
- name read-only Object name
- Object.find(name) Find an already loaded object by name
- Object:get_class() Class of this object
Subclasses
- AbstractCrafter
- AdminElectricGeneratorBlockLogic
- BedBlockLogic
- ComputerBlockLogic
- ConductorBlockLogic
- ConveyorBlockLogic
- DesignableCoverBlockLogic
- DesignableFenceBlockLogic
- DoorBlockLogic
- DrillingMachineBase
- FenceBlockLogic
- GhostBlockLogic
- LandingPadBlockLogic
- LedBlockLogic
- SplitterBlockLogic
- SpotlightBlockLogic
- StorageBlockLogic
Used by
- Accessor.owner field
- BlockActor.logic field
- Dimension.get_block return
- GenContext.spawn_block return