Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix wire splicing spawning #1481

Merged
merged 2 commits into from
Sep 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions modular_ss220/wire_splicing/code/wiresplicing.dm
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,18 @@
name = "wiring splicing spawner"
icon = 'modular_ss220/wire_splicing/icons/structures_spawners.dmi'
icon_state = "wire_splicing"
/// From 0 to 100
var/spawn_probability = 100

/obj/effect/spawner/wire_splicing/Initialize()
. = ..()
new /obj/structure/wire_splicing(get_turf(src))
if(prob(spawn_probability))
new /obj/structure/wire_splicing(get_turf(src))
return INITIALIZE_HINT_QDEL

// 70% chance to be nothing
/obj/effect/spawner/wire_splicing/thirty
name = "wiring splicing spawner 30%"

/obj/effect/spawner/wire_splicing/thirty/Initialize(mapload)
. = ..()
if(prob(70))
return INITIALIZE_HINT_QDEL
spawn_probability = 30

/obj/structure/wire_splicing
name = "wire splicing"
Expand Down
Loading