Personal Equipment Question

Place to get help with not working mods / modding interface.
Post Reply
TheSAguy
Smart Inserter
Smart Inserter
Posts: 1449
Joined: Mon Jan 13, 2014 6:17 pm
Contact:

Personal Equipment Question

Post by TheSAguy »

Hi,

Does anyone know if one can create Personal Equipment that does the following:
  • Add resistances
  • Increase Health Gen
  • Increase Damage. (Would it be a global multiplier or a per damage type multiplayer?)
  • Increase players total health
  • Increase players Loot pickup distance
Thanks.

User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2903
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

Re: Personal Equipment Question

Post by darkfrei »

TheSAguy wrote:
Thu May 16, 2019 3:43 pm
Hi,

Does anyone know if one can create Personal Equipment that does the following:
  • Add resistances
  • Increase Health Gen
  • Increase Damage. (Would it be a global multiplier or a per damage type multiplayer?)
  • Increase players total health
  • Increase players Loot pickup distance
Thanks.
1 energy shield
2 or 4 https://lua-api.factorio.com/latest/Lua ... alth_bonus

5 https://lua-api.factorio.com/latest/Lua ... ance_bonus via script

TheSAguy
Smart Inserter
Smart Inserter
Posts: 1449
Joined: Mon Jan 13, 2014 6:17 pm
Contact:

Re: Personal Equipment Question

Post by TheSAguy »

darkfrei wrote:
Fri May 17, 2019 3:06 pm


1 energy shield
So it looks like the Energy Shield only has "max_shield_value", can't add "resistances" to it.
So you can create a "Shield", but not specific to a type of damage via "resistances"

Can someone confirm this?

Thanks.

User avatar
Deadlock989
Smart Inserter
Smart Inserter
Posts: 2528
Joined: Fri Nov 06, 2015 7:41 pm

Re: Personal Equipment Question

Post by Deadlock989 »

TheSAguy wrote:
Mon May 20, 2019 6:52 pm
So it looks like the Energy Shield only has "max_shield_value", can't add "resistances" to it.
So you can create a "Shield", but not specific to a type of damage via "resistances"

Can someone confirm this?

Thanks.
That's right, you can't.

https://wiki.factorio.com/Prototype/Ene ... dEquipment

If a prototype doesn't have a property, and it didn't inherit it from another abstract class, then setting it won't do anything and the engine doesn't support it.
Image

User avatar
darkfrei
Smart Inserter
Smart Inserter
Posts: 2903
Joined: Thu Nov 20, 2014 11:11 pm
Contact:

Re: Personal Equipment Question

Post by darkfrei »

TheSAguy wrote:
Mon May 20, 2019 6:52 pm
So it looks like the Energy Shield only has "max_shield_value", can't add "resistances" to it.
So you can create a "Shield", but not specific to a type of damage via "resistances"
My bad, it's impossible right now.

It could be

Code: Select all

data.raw["energy-shield-equipment"]["energy-shield-equipment"].resistances = {{type = "acid", decrease = 50, percent = 20}}
But it doesn't work.

Post Reply

Return to “Modding help”