mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-10 08:54:15 +00:00
## About The Pull Request https://github.com/tgstation/tgstation/pull/74985#issuecomment-1523773626 Tests that all jobs that have `spawn_position > 0` at roundstart have a location to spawn at. Also changes the failure message for `get_default_roundstart_spawn_point` to send to `log_mapping` rather than `log_world`, as it is a map error and log world doesn't really help anyone. This would've been sufficient for the existing unit test `log_mapping`, but that unit test expects that the log has an areacoord supplied, which we can't really do, given we're reporting a _lack_ of something. ## Why It's Good For The Game Stops maps from regressing and dumping people on the latejoin shuttle roundstart. ## Changelog ~~Not necessary unless I find a map which forgot a landmark~~ 🆑 Melbert fix: Tramstation Robotics and RD now spawn in their departments roundstart fix: Birdboat detective now spawns in their office /🆑
13 lines
557 B
Plaintext
13 lines
557 B
Plaintext
/// Tests that [/datum/job/proc/get_default_roundstart_spawn_point] returns a landmark from all joinable jobs.
|
|
/datum/unit_test/job_roundstart_spawnpoints
|
|
|
|
/datum/unit_test/job_roundstart_spawnpoints/Run()
|
|
for(var/datum/job/job as anything in SSjob.joinable_occupations)
|
|
if(job.spawn_positions <= 0)
|
|
// Zero spawn positions means we don't need to care if they don't have a roundstart landmark
|
|
continue
|
|
if(job.get_default_roundstart_spawn_point())
|
|
continue
|
|
|
|
TEST_FAIL("Job [job.title] ([job.type]) has no default roundstart spawn landmark.")
|