SourceData
classResource deposit placed on the map
Fields
| Name | Type | Description | |
|---|---|---|---|
| position | Vec2i | Source position in block coordinates | |
| item | StaticItem | Item to mine | |
| active_miners | integer | Number of miners currently extracting | |
| infinite_ore | boolean | Deposit never depletes | |
Functions
SourceData:get_yield_per_miner()
Average yield per miner currently on this deposit, 0 if no miners
returns integer
SourceData:get_estimated_yield_for_new_miner()
Yield a new miner would get if placed on this deposit, for build preview
returns integer
Standard members (4)
Every class of this kind carries these.
| SourceData.cast(object) | Trying to cast Object into SourceData |
| SourceData.get_class() | Return SourceData class object |
| SourceData.new(parent, name) | Creates a new SourceData instance |
| SourceData.new_simple() | Creates a new SourceData 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
Used by
- DrillingMachineBase.get_source return
- DrillingRig.source field
- Pumpjack.source field
- Region.add_source param