#DynamicLoot - Minimal setup/maintenance loot spawning system

1 messages · Page 1 of 1 (latest)

regal rapids
#

https://reforger.armaplatform.com/workshop/66B2F0B008DC590F-DynamicLoot

ℹ️ About

Arma Reforger loot system that dynamically reads loot items from EntityCatalogs and bases their rarity weighting on an inverse of supply cost, so cheaper items are more common and more expensive items are rarer automatically.

Any modded gear correctly added to EntityCatalogs of factions in the scenario's FactionManager will be available automatically.

Arma Reforger

Utility for dynamically spawning loot based on entity catalogs.
Does nothing on its own.

regal rapids
#

DynamicLoot - Minimal setup/maintenance loot spawning system

winged spade
#

Ohh nice, great work.

fallen plover
#

Nice. I will try this out!

winged spade
#

@regal rapids What does your mod reference to place the loot down?

regal rapids
# winged spade <@148624052641071104> What does your mod reference to place the loot down?

It works like this:
DL_LootSpawnComponent is added to prefab for "destructible multiphase props" which almost every prop in the game inherits from:
https://github.com/wyqydsyq/DynamicLoot/blob/main/Prefabs/Props/Core/DestructibleMultiPhase_Props_Base.et

In the system's OnUpdate it iterates through all registered DL_LootSpawnComponent instances, checking their owner entity's resource name against the following whitelist/blacklist
https://github.com/wyqydsyq/DynamicLoot/blob/main/scripts/Game/Systems/DL_LootSystem.c#L31

Prefabs that match the whitelist + are not blacklisted have a DL_LootContainerTrigger entity created as a child which then spawns the actual loot container when a player gets close by, loot items are generated by the server upon player requesting to open a loot container

I'll be making the whitelist+blacklist tweakable from the system config a future update, in the meantime if you want to change them feel free to just override the arrays directly

Loot items themselves are read from the EntityCatalogs of every faction in the world's FactionManager, so any vanilla or modded gear properly registered to them and accessible via Arsenal will be available as loot automatically

regal rapids
#

A recent update changed how loot weighting works, if you have an override for the system config Scarcity Multiplier setting you'll probably want to increase your value by 10-20x otherwise high-value items might become too common

regal rapids
#

Just doing finishing touches on this update which makes a ton more stuff customizable from system config + adds loot spawner categorisation based on proximity to map markers (like DayZ you'll find more medical stuff near hospitals, military stuff near bases etc). Planning to release it later this week

Little sneak-peek of the new config attached

regal rapids
#

New update is out, system config is expanded even more from the screenshot above, DL now automatically categorizes loot and spawners based on proximity to category "providers" (generally entities with map descriptors) and there's a similar system for rarity where you can now place rarity providers in the scenario that will multiply max loot container value for loot spawners in proximity, if the world has no rarity providers it will fallback to treating centre of world as one with 20x mult

regal rapids
#

example showing difference in loot categories between a shop in a city (urban+commercial) and police station (urban+police)