* Fix usages of TryIndex()
Most usages of TryIndex() were using it incorrectly. Checking whether prototype IDs specified in prototypes actually existed before using them. This is not appropriate as it's just hiding bugs that should be getting caught by the YAML linter and other tools. (#39115)
This then resulted in TryIndex() getting modified to log errors (94f98073b0), which is incorrect as it causes false-positive errors in proper uses of the API: external data validation. (#39098)
This commit goes through and checks every call site of TryIndex() to see whether they were correct. Most call sites were replaced with the new Resolve(), which is suitable for these "defensive programming" use cases.
Fixes#39115
Breaking change: while doing this I noticed IdCardComponent and related systems were erroneously using ProtoId<AccessLevelPrototype> for job prototypes. This has been corrected.
* fix tests
---------
Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
* Make NameIdentifier Ids get refreshed after round restarts
Before this commit the existing values would just get shuffled.
This means that eventually the server would run out of ids to give to
new entities for different groups. As a result everything would get id 0
* Comply with what seemingly is the convention for sawmills
* Make it impossible to insert a bounty with a duplicate id
* Reduce duplication
* Remove unused sawmill
* Fix rustbrain and skill issue
* Aaaa
* Apply suggestions from code review
---------
Co-authored-by: Pieter-Jan Briers <pieterjan.briers@gmail.com>
* Replaced uses of Dirty(Component) with Dirty(Uid, Component)
Modified some systems (notably pulling-related) to use uids.
* Missed a few
* Revert changes to pulling
* No
* Laws
* positronic brain and PAI rewrite
* MMI
* MMI pt. 2
* borg brain transfer
* Roleban support, Borg job (WIP), the end of mind shenaniganry
* battery drain, item slot cleanup, alerts
* visuals
* fix this pt1
* fix this pt2
* Modules, Lingering Stacks, Better borg flashlight
* Start on UI, fix battery alerts, expand activation/deactivation, low movement speed on no power.
* sprotes
* no zombie borgs
* oh fuck yeah i love a good relay
* charger
* fix the tiniest of sprite issues
* adjustable names
* a functional UI????
* foobar
* more modules
* this shit for some reason
* upstream
* genericize selectable borg modules
* upstream again
* holy fucking shit
* i love christ
* proper construction
* da job
* AA borgs
* and boom more shit
* admin logs
* laws redux
* ok just do this rq
* oh boy that looks like modules
* oh shit research
* testos passo
* so much shit holy fuck
* fuckit we SHIP
* last minute snags
* should've gotten me on a better day