mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-14 01:18:40 +01:00
Fix indentations (#17481)
* cbt * AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA * fsadffsda sad * sadfasd * jhn * dsfa * saf * safsad * sda
This commit is contained in:
@@ -7,9 +7,9 @@
|
||||
|
||||
datum/unit_test/template
|
||||
name = "Test Template - Change My name" // If it's a template leave the word "template" in it's name so it's not ran.
|
||||
|
||||
|
||||
async = 1 // Set if we should continue testing elsewhere and come back and check on the results.
|
||||
|
||||
|
||||
|
||||
datum/unit_test/template/start_test()
|
||||
// This must return something, if it's null the unit_test runner will think we runtimed.
|
||||
@@ -29,7 +29,7 @@ datum/unit_test/template/check_result()
|
||||
// Return 0 if we need to come back again and check this.
|
||||
// Return 1 if the test is complete.
|
||||
|
||||
//
|
||||
//
|
||||
|
||||
pass("Winner is you")
|
||||
|
||||
|
||||
@@ -2,34 +2,34 @@
|
||||
name = "GAMEMODE template"
|
||||
|
||||
/datum/unit_test/gamemode/required_enemies_check
|
||||
name = "GAMEMODE: All modes shall have required_players and required_enemies greater than the required number of players for their antagonist types."
|
||||
name = "GAMEMODE: All modes shall have required_players and required_enemies greater than the required number of players for their antagonist types."
|
||||
|
||||
/datum/unit_test/gamemode/required_enemies_check/start_test()
|
||||
var/list/failed = list()
|
||||
var/list/failed = list()
|
||||
|
||||
for(var/mode in subtypesof(/datum/game_mode))
|
||||
var/datum/game_mode/GM = new mode
|
||||
for(var/mode in subtypesof(/datum/game_mode))
|
||||
var/datum/game_mode/GM = new mode
|
||||
|
||||
var/min_antag_count = 0
|
||||
for(var/antag_type in GM.antag_tags)
|
||||
var/datum/antagonist/A = all_antag_types[antag_type]
|
||||
var/min_antag_count = 0
|
||||
for(var/antag_type in GM.antag_tags)
|
||||
var/datum/antagonist/A = all_antag_types[antag_type]
|
||||
|
||||
if(GM.require_all_templates)
|
||||
min_antag_count += A.initial_spawn_req
|
||||
else
|
||||
min_antag_count = max(min_antag_count, A.initial_spawn_req)
|
||||
if(GM.require_all_templates)
|
||||
min_antag_count += A.initial_spawn_req
|
||||
else
|
||||
min_antag_count = max(min_antag_count, A.initial_spawn_req)
|
||||
|
||||
if(min_antag_count != GM.required_enemies)
|
||||
failed += "[GM] ([GM.type]) requires [GM.required_enemies] enemies but its antagonist roles require [min_antag_count] players!"
|
||||
if(min_antag_count > GM.required_players)
|
||||
failed += "[GM] ([GM.type]) requires [GM.required_players] players but its antagonist roles require [min_antag_count] players!"
|
||||
if(min_antag_count != GM.required_enemies)
|
||||
failed += "[GM] ([GM.type]) requires [GM.required_enemies] enemies but its antagonist roles require [min_antag_count] players!"
|
||||
if(min_antag_count > GM.required_players)
|
||||
failed += "[GM] ([GM.type]) requires [GM.required_players] players but its antagonist roles require [min_antag_count] players!"
|
||||
|
||||
|
||||
if(failed.len)
|
||||
TEST_FAIL("Some gamemodes did not have high enough required_enemies or required_players.")
|
||||
for(var/failed_message in failed)
|
||||
TEST_FAIL(failed_message)
|
||||
else
|
||||
TEST_PASS("All gamemodes had suitable required_enemies and required_players.")
|
||||
if(failed.len)
|
||||
TEST_FAIL("Some gamemodes did not have high enough required_enemies or required_players.")
|
||||
for(var/failed_message in failed)
|
||||
TEST_FAIL(failed_message)
|
||||
else
|
||||
TEST_PASS("All gamemodes had suitable required_enemies and required_players.")
|
||||
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -198,8 +198,7 @@
|
||||
|
||||
/datum/unit_test/mob_damage/start_test()
|
||||
var/list/test = create_test_mob_with_mind(null, mob_type)
|
||||
var/damage_amount = 5 // Do not raise, if damage >= 10 there is a % chance to reduce damage by half in /obj/item/organ/external/take_damage()
|
||||
// Which makes checks impossible.
|
||||
var/damage_amount = 5 // Do not raise, if damage >= 10 there is a % chance to reduce damage by half in /obj/item/organ/external/take_damage(), which makes checks impossible.
|
||||
|
||||
if(isnull(test))
|
||||
TEST_FAIL("Check Runtimed in Mob creation")
|
||||
@@ -230,8 +229,7 @@
|
||||
|
||||
H.apply_damage(damage_amount, damagetype, damage_location)
|
||||
|
||||
H.updatehealth() // Just in case, though at this time apply_damage does this for us.
|
||||
// We operate with the assumption that someone might mess with that proc one day.
|
||||
H.updatehealth() // Just in case, though at this time apply_damage does this for us. We operate with the assumption that someone might mess with that proc one day.
|
||||
|
||||
var/ending_damage = damage_check(H, damagetype)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user