branchrust_reboot/main/primitive_gmcancel
152 Commits over 123 Days - 0.05cph!
Fix items showing red (restricted) in F1 menu if they were blocked for crafting/vending but allowed in loot
merge from primitive -> primitive_gm
Apply gamemode convars on server startup instead of when the entity is spawned
- ensures convars are applied when the rest of server config is loaded
Spent a bunch of time trying to ensure that the spawn handler would rebalance the nodes when the server's era is changed and there should be lower % of sulfur nodes
Allow spawn.report command to pass true/false for detailed (to print off number of each prefab it spawns) and also pass a string filter (so you can return only ore populations)
Fix high tier loot spawning in loot containers as the server starts up
- refresh all loot on the server when the era is changed
Spawn 50% of the sulfur nodes in primitive era
Add support for float weights for spawn populations
Add support to give prefabs different weights based on the era of the server
Add `enforce_era_restrictions` command to delete all restricted items that sneak past the existing restrictions
Add `simulate_loot` command to test what loot will come out of a loot container
- picks the closest loot container
- default runs 100 times, can increase to 10k times
Ensure on the server that items can't be crafted in the wrong era
Make pistol ammo loot only as well
merge from main -> primitive_gm
Make chainsaw and jackhammer only available from loot in primitive era
Change era restriction so it's a whitelist of sources you can get it from instead of blacklist of where it's blocked
- unless unassigned then it means nothing
Add support to only block items from certain sources inside an era
- example: making jackhammers available in loot but not available from vending machines
Increase workbench tax in primitive gamemode
T1 0% -> 10%
T2 10% -> 20%
T3 20% -> 40%
Disable bradley & cargo ship
Also block the train tunnel entrances that spawn outside of monuments
merge from main -> primitive_gm
S2P monuments with train tunnel entrances
Add trash pile to ferry terminal train entrances since it's a different prefab
Add trash pile to block train tunnel monument entrances when train tunnels is disabled
Add support for prefabs to be enabled to block the train tunnel entrances when train tunnels is disabled
Disable following monuments in primitive
- nuclear missile silo
- oil rigs
- excavator
- underwater labs
Create ScriptableWorldConfig so we can override terrain generation for each gamemode
- have to use a new object since gamemodes are spawned after the terrain is generated
Re-add molotov as it accidently got removed
Restrict additional items
- mlrs
- 40mm grenade ammo (since MGL was already removed)
- all rocket ammo (since launcher was already removed)
- C4
- HV & incendiary pistol ammo
- homing launcher & ammo
Fix restricted items showing up in quick craft
Fix restricted items showing up when searching crafting menu
Fix favorites in crafting menu being shown when restricted
Fix for RPC not filtering out the sell orders in a different era
Cherrypick CS
110544 compile fix (unsure why it didn't show in this branch originally)
merge from main -> primitive_gm
Try catch convars when setting up gamemode incase one of the convars throws an error upwards
Redo the way server event convars are applied by storing the changes and applying them once the event prefab is loaded
- we need to do this because convars can be ran before the event's scheduling prefab has been loaded on the server
Fix gamemode failing to run startup methods if it was spawned before ServerMgr
Add convar to control if oil rigs should generate on the map
- disable oil rigs in primitive
Fixed static workbenches not having primitive version of tech tree attached to them
Fix T2 and T3 tech tree not marked as available in primitive
Restrict spring since it's only used for restricted weapons
- remove spring from pressure plate in primitive to make it craftable with spring removal
Remove rifle body, SMG body, semi body since they are only used for restricted weapons
Fix metal detector not applying item era restrictions
Restrict access to rifle ammo since no weapons that use rifle ammo are available
Fix advent calendar able to bypass primitive era item restrictions
Remove `npc_junkpile_a_spawn_chance` and `npc_junkpile_g_spawn_chance` convars as no junkpiles in the project actually use the components the convars are referenced in
- replace with the normal convar `npc_junkpilespawn_chance`
Restrict double barrel shotgun
Disable all scientists in primitive mode
Add convars to block NPCs from spawning
- `npc_spawn_on_junkpile` specifically for junkpiles
- `scientist_spawners_enabled` will disable all scientists spawning (peaceful & hostile)