Desynced

Desynced

Not enough ratings
Get Component Definitions
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
4.465 KB
8 Oct, 2023 @ 1:21pm
16 Aug, 2024 @ 1:03am
4 Change Notes ( view )

Subscribe to download
Get Component Definitions

In 1 collection by sacroimper
Sacroimper's Desynced mods
11 items
Description
This mod adds an instruction that returns any value you may need from a component definition.

All information avaliable:
- Range
- Damage
- Damage/sec
- Charge Duration (ticks)
- Shoot Speed (ticks)
- Splash Range
- Power Production
- Power Usage
- Power Storage
- Drain Rate
- Drain Time (ticks)
- Charge Rate
- Charge Time (ticks)
- Damage/Power Ratio
- Damage absorption capacity
- Bandwidth
- Boost
- Socket Size
- Storage Slots
- Gas Slots
- Garage Slots
- Drone Slots
- Flyer Slots
- Satellite Slots
- Research
- Race
- Producer/Time (ticks)
- Extracts/Time (ticks)
- Recycle Time (ticks)
- Consume/Time (ticks)
- Repair
- Repair/sec
- Registers Amount
- Ingredients Total Amount


----------------------------------------------------------------------------


For modders:

If any modder wants to add a custom stat to this instruction it can be done with a simple method in the package:post_init(). Example:

function package:post_init() local get_component_def = data.instructions.get_component_def if get_component_def and get_component_def.AddOption then get_component_def:AddOption("extraction_time", "Extracts/Time (ticks)", "Extraction product and time", function (compDef) return compDef.extraction_time and {id = compDef.extracts, num = compDef.extraction_time} end) end end
1 Comments
PathoNomadic 9 Dec, 2023 @ 12:23pm 
This absolutely needs to be incorporated into the main game. Thanks!