get/set force and player modifiers + defines
Posted: Tue May 11, 2021 1:32 pm
For discussion / observation:
1. some other modifiers, such as turrets, have an interface get/set function
2. Force and Character bonuses/modifiers are scattered in the API with no list in the api (Concepts#Modifier is a collection, kind of)
Cons:
Breaking change if existing LuaForce / LuaPlayer RW values are removed
Pros:
common interface for all modifiers (in one or two defines tables)
all modifiers together
e.g.
Ammo_damage, gun_speed, or turret_attack for force, are modifiers but not really the same as mining, running, etc modifiers. Could be included.
1. some other modifiers, such as turrets, have an interface get/set function
2. Force and Character bonuses/modifiers are scattered in the API with no list in the api (Concepts#Modifier is a collection, kind of)
Cons:
Breaking change if existing LuaForce / LuaPlayer RW values are removed
Pros:
common interface for all modifiers (in one or two defines tables)
all modifiers together
e.g.
Code: Select all
defines.force_modifiers = {
["manual_mining_speed_modifier"] = 1,
...
}