[MIRROR] some more NEW to init (#10148)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-02-13 03:00:18 -07:00
committed by GitHub
parent a8ea2f9062
commit fe69ddd909
23 changed files with 106 additions and 98 deletions

View File

@@ -71,7 +71,8 @@ obj/item/gun/energy/laser/retro/sc_retro
/obj/item/gun/projectile/silenced/sc_silenced
//Make it so that these guns only spawn with a couple bullets... if any
/obj/item/gun/projectile/silenced/sc_silenced/New()
/obj/item/gun/projectile/silenced/sc_silenced/Initialize(mapload)
. = ..()
for(var/ammo in loaded)
if(prob(95)) //95% chance
loaded -= ammo
@@ -79,7 +80,8 @@ obj/item/gun/energy/laser/retro/sc_retro
//Syndicate sub-machine guns.
/obj/item/gun/projectile/automatic/c20r/sc_c20r
/obj/item/gun/projectile/automatic/c20r/sc_c20r/New()
/obj/item/gun/projectile/automatic/c20r/sc_c20r/Initialize(mapload)
. = ..()
for(var/ammo in loaded)
if(prob(95)) //95% chance
loaded -= ammo
@@ -87,7 +89,8 @@ obj/item/gun/energy/laser/retro/sc_retro
//Barman's shotgun
/obj/item/gun/projectile/shotgun/pump/sc_pump
/obj/item/gun/projectile/shotgun/pump/sc_pump/New()
/obj/item/gun/projectile/shotgun/pump/sc_pump/Initialize(mapload)
. = ..()
for(var/ammo in loaded)
if(prob(95)) //95% chance
loaded -= ammo
@@ -113,12 +116,14 @@ var/sc_safecode5 = "[rand(0,9)]"
/obj/item/paper/sc_safehint_paper_prison
name = "smudged paper"
/obj/item/paper/sc_safehint_paper_prison/New()
/obj/item/paper/sc_safehint_paper_prison/Initialize(mapload, text, title)
. = ..()
info = span_italics("The ink is smudged, you can only make out a couple numbers:") + " '[sc_safecode1]**[sc_safecode4]*'"
/obj/item/paper/sc_safehint_paper_hydro
name = "shredded paper"
/obj/item/paper/sc_safehint_paper_hydro/New()
/obj/item/paper/sc_safehint_paper_hydro/Initialize(mapload, text, title)
. = ..()
info = span_italics("Although the paper is shredded, you can clearly see the number:") + " '[sc_safecode2]'"
/obj/item/paper/sc_safehint_paper_caf
@@ -128,8 +133,10 @@ var/sc_safecode5 = "[rand(0,9)]"
/obj/item/paper/sc_safehint_paper_bible
name = "hidden paper"
/obj/item/paper/sc_safehint_paper_bible/New()
info =span_italics("It would appear that the pen hidden with the paper had leaked ink over the paper. \
/obj/item/paper/sc_safehint_paper_bible/Initialize(mapload, text, title)
. = ..()
info = span_italics("It would appear that the pen hidden with the paper had leaked ink over the paper. \
However you can make out the last three digits:") + "' [sc_safecode3][sc_safecode4][sc_safecode5]'"
/obj/item/paper/sc_safehint_paper_shuttle

View File

@@ -225,28 +225,28 @@
//Teleport to Mine
/obj/effect/step_trigger/teleporter/mine/to_mining/New()
..()
/obj/effect/step_trigger/teleporter/mine/to_mining/Initialize()
. = ..()
teleport_x = src.x
teleport_y = 2
teleport_z = Z_LEVEL_STATION_ONE
/obj/effect/step_trigger/teleporter/mine/from_mining/New()
..()
/obj/effect/step_trigger/teleporter/mine/from_mining/Initialize()
. = ..()
teleport_x = src.x
teleport_y = world.maxy - 1
teleport_z = Z_LEVEL_STATION_TWO
//Teleport to Wild
/obj/effect/step_trigger/teleporter/wild/to_wild/New()
..()
/obj/effect/step_trigger/teleporter/wild/to_wild/Initialize()
. = ..()
teleport_x = src.x
teleport_y = 2
teleport_z = Z_LEVEL_SURFACE_WILD
/obj/effect/step_trigger/teleporter/wild/from_wild/New()
..()
/obj/effect/step_trigger/teleporter/wild/from_wild/Initialize()
. = ..()
teleport_x = src.x
teleport_y = world.maxy - 1
teleport_z = Z_LEVEL_STATION_TWO
@@ -330,4 +330,4 @@
// Putting this here in order to not disrupt existing maps/downstreams.
/turf/simulated/open
dynamic_lighting = TRUE
dynamic_lighting = TRUE

View File

@@ -220,28 +220,28 @@
//Teleport to Mine
/obj/effect/step_trigger/teleporter/mine/to_mining/New()
..()
/obj/effect/step_trigger/teleporter/mine/to_mining/Initialize()
. = ..()
teleport_x = src.x
teleport_y = 2
teleport_z = Z_LEVEL_SURFACE_MINE
/obj/effect/step_trigger/teleporter/mine/from_mining/New()
..()
/obj/effect/step_trigger/teleporter/mine/from_mining/Initialize()
. = ..()
teleport_x = src.x
teleport_y = world.maxy - 1
teleport_z = Z_LEVEL_SURFACE
//Teleport to Wild
/obj/effect/step_trigger/teleporter/wild/to_wild/New()
..()
/obj/effect/step_trigger/teleporter/wild/to_wild/Initialize()
. = ..()
teleport_x = src.x
teleport_y = 2
teleport_z = Z_LEVEL_SURFACE_WILD
/obj/effect/step_trigger/teleporter/wild/from_wild/New()
..()
/obj/effect/step_trigger/teleporter/wild/from_wild/Initialize()
. = ..()
teleport_x = src.x
teleport_y = world.maxy - 1
teleport_z = Z_LEVEL_SURFACE_MINE
@@ -333,4 +333,4 @@
. += "Humanity stands on the precipice of a technological singularity, and the vast majority of the Solar Confederate Government would rather it move firmly away from the edge. <br>"
. += "Though Vir is typically peaceful, the system has seen its fair share of conflict in the face of technological extremists, rogue drone intelligence, and worse.<br>"
. += "As an employee of NanoTrasen, operators of the Southern Cross and one of the galaxy's largest research corporations, you're probably just here to do a job."
return jointext(., "<br>")
return jointext(., "<br>")

View File

@@ -41,8 +41,8 @@
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0) //No armor at all.
canremove = FALSE
/obj/item/clothing/suit/space/changeling/New()
..()
/obj/item/clothing/suit/space/changeling/Initialize()
. = ..()
if(ismob(loc))
loc.visible_message(span_warning("[loc.name]\'s flesh rapidly inflates, forming a bloated mass around their body!"),
span_warning("We inflate our flesh, creating a spaceproof suit!"),
@@ -107,8 +107,8 @@
max_heat_protection_temperature = FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE
slowdown = 1.5
/obj/item/clothing/suit/space/changeling/armored/New()
..()
/obj/item/clothing/suit/space/changeling/armored/Initialize()
. = ..()
if(ismob(loc))
loc.visible_message(span_warning("[loc.name]\'s flesh turns black, quickly transforming into a hard, chitinous mass!"),
span_warning("We harden our flesh, creating a suit of armor!"),

View File

@@ -14,8 +14,8 @@
consume_range = 6
/obj/singularity/narsie/large/exit/New()
..()
/obj/singularity/narsie/large/exit/Initialize(mapload, ...)
. = ..()
START_PROCESSING(SSobj, src)
/obj/singularity/narsie/large/exit/update_icon()

View File

@@ -36,9 +36,9 @@
wearer.custom_pain("Your hands hurt like hell!",1)
wearer = null
/obj/item/clothing/gloves/regen/New()
/obj/item/clothing/gloves/regen/Initialize(mapload)
. = ..()
START_PROCESSING(SSobj, src)
..()
/obj/item/clothing/gloves/regen/Destroy()
wearer = null

View File

@@ -108,7 +108,7 @@
name = "hypo belt"
desc = "A medical belt designed to carry autoinjectors and other medical equipment."
/obj/item/storage/belt/medical/technomancer/New()
/obj/item/storage/belt/medical/technomancer/Initialize(mapload)
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/brute(src)
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/burn(src)
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/toxin(src)
@@ -117,7 +117,7 @@
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/pain(src)
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/organ(src)
new /obj/item/reagent_containers/hypospray/autoinjector/biginjector/combat(src)
..()
. = ..()
/datum/technomancer/equipment/belt_of_holding
name = "Belt of Holding"

View File

@@ -6,8 +6,8 @@
aspect = null
var/glow_color = "#FFFFFF"
/obj/item/spell/aura/New()
..()
/obj/item/spell/aura/Initialize(mapload)
. = ..()
set_light(calculate_spell_power(7), calculate_spell_power(4), l_color = glow_color)
START_PROCESSING(SSobj, src)
log_and_message_admins("has started casting [src].")

View File

@@ -20,8 +20,8 @@
var/list/things_to_siphon = list() //Things which are actually drained as a result of the above not being null.
var/flow_rate = 1000 // Limits how much electricity can be drained per second. Measured by default in god knows what.
/obj/item/spell/energy_siphon/New()
..()
/obj/item/spell/energy_siphon/Initialize(mapload)
. = ..()
START_PROCESSING(SSobj, src)
/obj/item/spell/energy_siphon/Destroy()

View File

@@ -544,15 +544,15 @@
name = "Diskette Box"
icon_state = "disk_kit"
/obj/item/storage/box/disks/New()
..()
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
new /obj/item/disk/data(src)
/obj/item/storage/box/Initialize()
. = ..()
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
new /obj/item/disk/body_record(src)
/*
* Manual -- A big ol' manual.

View File

@@ -21,9 +21,8 @@ Deployable items
var/locked = 0.0
// req_access = list(access_maint_tunnels)
/obj/machinery/deployable/barrier/New()
..()
/obj/machinery/deployable/barrier/Initialize(mapload)
. = ..()
icon_state = "barrier[locked]"
/obj/machinery/deployable/barrier/attackby(obj/item/W as obj, mob/user as mob)

View File

@@ -9,8 +9,8 @@ var/list/doppler_arrays = list()
icon_state = "doppler"
/obj/machinery/doppler_array/New()
..()
/obj/machinery/doppler_array/Initialize(mapload)
. = ..()
doppler_arrays += src
/obj/machinery/doppler_array/Destroy()

View File

@@ -30,8 +30,8 @@
/obj/item/mecha_parts/chassis/ripley
name = "Ripley Chassis"
/obj/item/mecha_parts/chassis/ripley/New()
..()
/obj/item/mecha_parts/chassis/ripley/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/ripley_chassis(src)
/obj/item/mecha_parts/part/ripley_torso
@@ -69,8 +69,8 @@
/obj/item/mecha_parts/chassis/gygax
name = "Gygax Chassis"
/obj/item/mecha_parts/chassis/gygax/New()
..()
/obj/item/mecha_parts/chassis/gygax/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/gygax_chassis(src)
/obj/item/mecha_parts/part/gygax_torso
@@ -117,8 +117,8 @@
/obj/item/mecha_parts/chassis/serenity
name = "Serenity Chassis"
/obj/item/mecha_parts/chassis/serenity/New()
..()
/obj/item/mecha_parts/chassis/serenity/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/serenity_chassis(src)
//////////// Durand
@@ -126,8 +126,8 @@
/obj/item/mecha_parts/chassis/durand
name = "Durand Chassis"
/obj/item/mecha_parts/chassis/durand/New()
..()
/obj/item/mecha_parts/chassis/durand/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/durand_chassis(src)
/obj/item/mecha_parts/part/durand_torso
@@ -172,8 +172,8 @@
/obj/item/mecha_parts/chassis/firefighter
name = "Firefighter Chassis"
/obj/item/mecha_parts/chassis/firefighter/New()
..()
/obj/item/mecha_parts/chassis/firefighter/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/firefighter_chassis(src)
/*
/obj/item/mecha_parts/part/firefighter_torso
@@ -203,8 +203,8 @@
name = "Phazon Chassis"
origin_tech = list(TECH_MATERIAL = 7)
/obj/item/mecha_parts/chassis/phazon/New()
..()
/obj/item/mecha_parts/chassis/phazon/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/phazon_chassis(src)
/obj/item/mecha_parts/part/phazon_torso
@@ -255,8 +255,8 @@
/obj/item/mecha_parts/chassis/odysseus
name = "Odysseus Chassis"
/obj/item/mecha_parts/chassis/odysseus/New()
..()
/obj/item/mecha_parts/chassis/odysseus/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/odysseus_chassis(src)
/obj/item/mecha_parts/part/odysseus_head
@@ -307,8 +307,8 @@
name = "Janus Chassis"
origin_tech = list(TECH_MATERIAL = 7)
/obj/item/mecha_parts/chassis/janus/New()
..()
/obj/item/mecha_parts/chassis/janus/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/janus_chassis(src)
/obj/item/mecha_parts/part/janus_torso
@@ -370,8 +370,8 @@
origin_tech = list(TECH_MATERIAL = 2)
/obj/item/mecha_parts/fighter/chassis/pinnace/New()
..()
/obj/item/mecha_parts/fighter/chassis/pinnace/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/fighter/pinnace_chassis(src)
@@ -418,8 +418,8 @@
origin_tech = list(TECH_MATERIAL = 2)
/obj/item/mecha_parts/fighter/chassis/baron/New()
..()
/obj/item/mecha_parts/fighter/chassis/baron/Initialize(mapload)
. = ..()
construct = new /datum/construction/mecha/fighter/baron_chassis(src)

View File

@@ -20,10 +20,9 @@
icon_scale_x = 1.2
icon_scale_y = 1.2
/obj/mecha/medical/odysseus/New()
..()
/obj/mecha/medical/odysseus/Initialize(mapload)
. = ..()
hud = new /obj/item/clothing/glasses/hud/health/mech(src)
return
/obj/mecha/medical/odysseus/moved_inside(var/mob/living/carbon/human/H as mob)
if(..())

View File

@@ -125,8 +125,8 @@
//Vorestation Edit Start
/obj/mecha/working/ripley/New()
..()
/obj/mecha/working/ripley/Initialize()
. = ..()
orescanner = new /obj/item/mining_scanner
/obj/mecha/working/ripley/verb/detect_ore()

View File

@@ -53,8 +53,8 @@
layer = ABOVE_MOB_LAYER
mouse_opacity = 0
/obj/effect/overlay/wallrot/New()
..()
/obj/effect/overlay/wallrot/Initialize()
. = ..()
pixel_x += rand(-10, 10)
pixel_y += rand(-10, 10)

View File

@@ -17,8 +17,8 @@
pickup_sound = 'sound/items/pickup/device.ogg'
drop_sound = 'sound/items/drop/device.ogg'
/obj/item/nifrepairer/New()
..()
/obj/item/nifrepairer/Initialize(mapload)
. = ..()
supply = new(max = 60, A = src)

View File

@@ -367,9 +367,9 @@
pickup_sound = 'sound/items/pickup/gloves.ogg'
light_system = MOVABLE_LIGHT
/obj/item/flashlight/flare/New()
/obj/item/flashlight/flare/Initialize()
fuel = rand(800, 1000) // Sorry for changing this so much but I keep under-estimating how long X number of ticks last in seconds.
..()
. = ..()
/obj/item/flashlight/flare/process()
var/turf/pos = get_turf(src)
@@ -430,9 +430,9 @@
var/fuel = 0
power_use = 0
/obj/item/flashlight/glowstick/New()
/obj/item/flashlight/glowstick/Initialize()
fuel = rand(1600, 2000)
..()
. = ..()
/obj/item/flashlight/glowstick/process()
fuel = max(fuel - 1, 0)

View File

@@ -17,8 +17,8 @@
drop_sound = 'sound/items/drop/glass.ogg'
pickup_sound = 'sound/items/pickup/glass.ogg'
/obj/item/glass_jar/New()
..()
/obj/item/glass_jar/Initialize(mapload)
. = ..()
update_icon()
/obj/item/glass_jar/afterattack(var/atom/A, var/mob/user, var/proximity)

View File

@@ -53,7 +53,7 @@
/// If you can use this storage while in a pocket
var/pocketable = FALSE
/obj/item/storage/Initialize()
/obj/item/storage/Initialize(mapload)
. = ..()
if(allow_quick_empty)

View File

@@ -21,8 +21,8 @@
drop_sound = 'sound/items/drop/paper.ogg'
pickup_sound = 'sound/items/pickup/paper.ogg'
/obj/item/deck/cards/New()
..()
/obj/item/deck/cards/Initialize(mapload)
. = ..()
var/datum/playingcard/P
for(var/suit in list("spades","clubs","diamonds","hearts"))
@@ -52,7 +52,7 @@
P.card_icon = "joker"
cards += P
/obj/item/deck/attackby(obj/O as obj, mob/user as mob)
/obj/item/deck/attackby(obj/O, mob/user)
if(istype(O,/obj/item/hand))
var/obj/item/hand/H = O
if(H.parentdeck == src)

View File

@@ -248,13 +248,16 @@
/obj/item/organ/external/update_health()
damage = min(max_damage, (brute_dam + burn_dam))
/obj/item/organ/external/New(var/mob/living/carbon/holder)
..(holder, 0)
/obj/item/organ/external/Initialize(mapload, var/internal)
..(mapload, 0)
if(istype(owner))
replaced(owner)
sync_colour_to_human(owner)
spawn(1)
get_icon()
return INITIALIZE_HINT_LATELOAD
/obj/item/organ/external/LateInitialize()
. = ..()
get_icon()
/obj/item/organ/external/replaced(var/mob/living/carbon/human/target)
owner = target

View File

@@ -3,7 +3,7 @@
icon_name = ""
dislocated = -1
/obj/item/organ/external/stump/New(var/mob/living/carbon/holder, var/internal, var/obj/item/organ/external/limb)
/obj/item/organ/external/stump/Initialize(mapload, var/internal, var/obj/item/organ/external/limb)
if(istype(limb))
organ_tag = limb.organ_tag
body_part = limb.body_part
@@ -11,7 +11,7 @@
joint = limb.joint
parent_organ = limb.parent_organ
wounds = limb.wounds
..(holder, internal)
. = ..(mapload, internal)
if(istype(limb))
max_damage = limb.max_damage
if((limb.robotic >= ORGAN_ROBOT) && (!parent || (parent.robotic >= ORGAN_ROBOT)))