Skip to content

Commit

Permalink
Merge 2409 (#567)
Browse files Browse the repository at this point in the history
* Attempts an optimisation for power_change

- Adds an alternate, hopefully faster list iteration method for machines in power_change
- Removes uses of INVOKE_ASYNC for power_change, since it's slower than normal proc calls and does nothing since it doesn't sleep
TODO: Diagnose what the fuck is making power_change so slow anyway.

* benadryl

* Update severe.dm

nuh uh

* rename icons files

* poosh

* push

* SpookyStation fixes and edits (#16019)

* spooky 2023

* Spooky colormates, better telecomms?

* yes

Co-authored-by: SandPoot <[email protected]>

* yes

Co-authored-by: SandPoot <[email protected]>

* minor pre-merge change

I don't feel like requesting changes for this small of a nitpick so I'll just do it myself & merge.

---------

Co-authored-by: SandPoot <[email protected]>
Co-authored-by: DeltaFire <[email protected]>

* Update lavaland_surface_seed_vault.dmm (#15835)

* no sleep

no sleeping if not using INVOKE_ASYNC

* another layer

* Syndicate Skinned Box Station (#15580)

* Syndicate Skinned Box Station

* Create syndicatestation.json

Okay tHIS FIXED IT I THINK HOLY CRAP THIS WAS AN EXPERIENCE.  HERES THE JSON!

* actually makes this work

* random runtime

we lvoe lesser-used items with runtiming actions

---------

Co-authored-by: DeltaFire <[email protected]>

* Some dynamic midround tweaking (#15841)

* midround wizard, blob

* make dynamic respect midround pref, too

* Makes attempt_replacement not just make traitors

* Tried to make it poll if you wanna be a wizard

* something is going to happen in 1 minutes

* i left it half finished!

* This one seems a bit over the top

---------

Co-authored-by: DeltaFire <[email protected]>

* Bump http-cache-semantics from 4.1.0 to 4.1.1 in /tgui (#15964)

* Bump http-cache-semantics from 4.1.0 to 4.1.1 in /tgui

Bumps [http-cache-semantics](https://github.com/kornelski/http-cache-semantics) from 4.1.0 to 4.1.1.
- [Release notes](https://github.com/kornelski/http-cache-semantics/releases)
- [Commits](kornelski/http-cache-semantics@v4.1.0...v4.1.1)

---
updated-dependencies:
- dependency-name: http-cache-semantics
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>

* resetting CI

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: DeltaFire <[email protected]>

* Bump pillow from 9.3.0 to 10.0.1 in /tools (#16006)

Bumps [pillow](https://github.com/python-pillow/Pillow) from 9.3.0 to 10.0.1.
- [Release notes](https://github.com/python-pillow/Pillow/releases)
- [Changelog](https://github.com/python-pillow/Pillow/blob/main/CHANGES.rst)
- [Commits](python-pillow/Pillow@9.3.0...10.0.1)

---
updated-dependencies:
- dependency-name: pillow
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump postcss from 8.3.6 to 8.4.31 in /tgui (#16009)

Bumps [postcss](https://github.com/postcss/postcss) from 8.3.6 to 8.4.31.
- [Release notes](https://github.com/postcss/postcss/releases)
- [Changelog](https://github.com/postcss/postcss/blob/main/CHANGELOG.md)
- [Commits](postcss/postcss@8.3.6...8.4.31)

---
updated-dependencies:
- dependency-name: postcss
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump axios from 0.21.1 to 1.6.0 in /tgui (#16026)

Bumps [axios](https://github.com/axios/axios) from 0.21.1 to 1.6.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](axios/axios@v0.21.1...v1.6.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump tmpl from 1.0.4 to 1.0.5 in /tgui (#15958)

Bumps [tmpl](https://github.com/daaku/nodejs-tmpl) from 1.0.4 to 1.0.5.
- [Release notes](https://github.com/daaku/nodejs-tmpl/releases)
- [Commits](https://github.com/daaku/nodejs-tmpl/commits/v1.0.5)

---
updated-dependencies:
- dependency-name: tmpl
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump @babel/traverse from 7.15.0 to 7.23.2 in /tgui (#16018)

Bumps [@babel/traverse](https://github.com/babel/babel/tree/HEAD/packages/babel-traverse) from 7.15.0 to 7.23.2.
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.23.2/packages/babel-traverse)

---
updated-dependencies:
- dependency-name: "@babel/traverse"
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump semver from 6.3.0 to 6.3.1 in /tgui (#16029)

Bumps [semver](https://github.com/npm/node-semver) from 6.3.0 to 6.3.1.
- [Release notes](https://github.com/npm/node-semver/releases)
- [Changelog](https://github.com/npm/node-semver/blob/v6.3.1/CHANGELOG.md)
- [Commits](npm/node-semver@v6.3.0...v6.3.1)

---
updated-dependencies:
- dependency-name: semver
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump word-wrap from 1.2.3 to 1.2.5 in /tgui (#16030)

Bumps [word-wrap](https://github.com/jonschlinkert/word-wrap) from 1.2.3 to 1.2.5.
- [Release notes](https://github.com/jonschlinkert/word-wrap/releases)
- [Commits](jonschlinkert/word-wrap@1.2.3...1.2.5)

---
updated-dependencies:
- dependency-name: word-wrap
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump tar from 6.1.8 to 6.2.0 in /tgui (#16031)

Bumps [tar](https://github.com/isaacs/node-tar) from 6.1.8 to 6.2.0.
- [Release notes](https://github.com/isaacs/node-tar/releases)
- [Changelog](https://github.com/isaacs/node-tar/blob/main/CHANGELOG.md)
- [Commits](isaacs/node-tar@v6.1.8...v6.2.0)

---
updated-dependencies:
- dependency-name: tar
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump path-parse from 1.0.6 to 1.0.7 in /tgui (#16032)

Bumps [path-parse](https://github.com/jbgutierrez/path-parse) from 1.0.6 to 1.0.7.
- [Commits](https://github.com/jbgutierrez/path-parse/commits/v1.0.7)

---
updated-dependencies:
- dependency-name: path-parse
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* oops

* purple victorian donator suit

for novalica

* clussy

will it also honk when it lays eggs?

* fixes the negative size bug

lol

* more feet

lol

* Added trencher mask into loadout

Now coat can hold toys/plushies!
Also rewords few trencher/GWTB stuff.

* You know what fudge you

Added glass gas mask into loadout.

* they don't need direction states

was eepy

* Automatic changelog generation for PR #1011 [ci skip]

* Automatic changelog compile [ci skip]

* fix attempt

* attempt at updating

* @babel/helper-split-export-declaration

* globals

* a bunch of dependencies

* idk what I'm doing

lol

* Automatic changelog generation for PR #1012 [ci skip]

* Automatic changelog compile [ci skip]

* Automatic changelog generation for PR #1008 [ci skip]

* Automatic changelog compile [ci skip]

* Automatic changelog generation for PR #916 [ci skip]

* Automatic changelog compile [ci skip]

* +

* +

* +

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: MarinaGryphon <[email protected]>
Co-authored-by: BongaTheProto <[email protected]>
Co-authored-by: KrissKr0ss <[email protected]>
Co-authored-by: SandPoot <[email protected]>
Co-authored-by: BlueWildrose <[email protected]>
Co-authored-by: SandPoot <[email protected]>
Co-authored-by: DeltaFire <[email protected]>
Co-authored-by: shellspeed1 <[email protected]>
Co-authored-by: DJKouta <[email protected]>
Co-authored-by: Putnam3145 <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: silicons <[email protected]>
Co-authored-by: Anonymous <[email protected]>
Co-authored-by: SPLURT Bot <[email protected]>
Co-authored-by: Changelogs <[email protected]>
  • Loading branch information
16 people authored Nov 24, 2023
1 parent fb0ccd5 commit a962190
Show file tree
Hide file tree
Showing 61 changed files with 34,524 additions and 31,805 deletions.
1,041 changes: 594 additions & 447 deletions _maps/RandomRuins/LavaRuins/lavaland_surface_seed_vault.dmm

Large diffs are not rendered by default.

2,925 changes: 1,963 additions & 962 deletions _maps/map_files/SpookyStation/SpookyStation.dmm

Large diffs are not rendered by default.

3,173 changes: 1,722 additions & 1,451 deletions _maps/map_files/debug/runtimestation.dmm

Large diffs are not rendered by default.

54,562 changes: 27,281 additions & 27,281 deletions _maps/map_files/generic/CentCom.dmm

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions code/datums/elements/flavor_text.dm
Original file line number Diff line number Diff line change
Expand Up @@ -196,16 +196,16 @@ GLOBAL_LIST_EMPTY(mobs_with_editable_flavor_text) //et tu, hacky code
/datum/element/flavor_text/proc/borged_update_flavor_text(mob/new_character, client/C)
C = C || GET_CLIENT(new_character)
if(!C)
LAZYREMOVE(texts_by_atom, new_character)
LAZYSET(texts_by_atom, new_character, "")
return
var/datum/preferences/P = C.prefs
if(!P)
LAZYREMOVE(texts_by_atom, new_character)
LAZYSET(texts_by_atom, new_character, "")
return
if(P.custom_names["cyborg"] == new_character.real_name)
LAZYSET(texts_by_atom, new_character, P.features[save_key])
else
LAZYREMOVE(texts_by_atom, new_character)
LAZYSET(texts_by_atom, new_character, "")

//subtypes with additional hooks for DNA and preferences.
/datum/element/flavor_text/carbon
Expand Down
25 changes: 15 additions & 10 deletions code/game/area/areas.dm
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,7 @@ GLOBAL_LIST_EMPTY(teleportlocs)
A.power_light = FALSE
A.power_equip = FALSE
A.power_environ = FALSE
INVOKE_ASYNC(A, .proc/power_change)
A.power_change()
STOP_PROCESSING(SSobj, src)
return ..()

Expand Down Expand Up @@ -594,15 +594,20 @@ GLOBAL_LIST_EMPTY(teleportlocs)
// called when power status changes

/area/proc/power_change()
for(var/obj/machinery/M in src) // for each machine in the area
M.power_change() // reverify power status (to update icons etc.)
if(sub_areas)
for(var/i in sub_areas)
var/area/A = i
A.power_light = power_light
A.power_equip = power_equip
A.power_environ = power_environ
INVOKE_ASYNC(A, .proc/power_change)
SHOULD_NOT_SLEEP(TRUE)
if(contents.len < GLOB.machines.len) // it would be faster to loop over contents
for(var/obj/machinery/M in src) // for each machine in the area
M.power_change() // reverify power status (to update icons etc.)
else // it would be faster to loop over the machines list
for(var/obj/machinery/M as anything in GLOB.machines) // for each machine
if(get_area(M) != src) // in the area
continue
M.power_change() // reverify power status (to update icons etc.)
for(var/area/A as anything in sub_areas)
A.power_light = power_light
A.power_equip = power_equip
A.power_environ = power_environ
A.power_change()
update_appearance()

/area/proc/usage(chan)
Expand Down
99 changes: 79 additions & 20 deletions code/game/gamemodes/dynamic/dynamic_rulesets_midround.dm
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
var/restrict_ghost_roles = TRUE
/// What mob type the ruleset is restricted to.
var/required_type = /mob/living/carbon/human
var/should_use_midround_pref = TRUE
var/list/living_players = list()
var/list/living_antags = list()
var/list/dead_players = list()
Expand All @@ -23,6 +24,7 @@
/datum/dynamic_ruleset/midround/from_ghosts
weight = 0
required_type = /mob/dead/observer
should_use_midround_pref = FALSE
/// Whether the ruleset should call generate_ruleset_body or not.
var/makeBody = TRUE
/// The rule needs this many applicants to be properly executed.
Expand All @@ -43,6 +45,9 @@
if (!M.client) // Are they connected?
trimmed_list.Remove(M)
continue
if(should_use_midround_pref && !(M.client.prefs.toggles & MIDROUND_ANTAG))
trimmed_list.Remove(M)
continue
if(!mode.check_age(M.client, minimum_required_age))
trimmed_list.Remove(M)
continue
Expand Down Expand Up @@ -106,10 +111,10 @@
return
message_admins("Polling [possible_volunteers.len] players to apply for the [name] ruleset.")
log_game("DYNAMIC: Polling [possible_volunteers.len] players to apply for the [name] ruleset.")
var/flag = antag_flag_override ? antag_flag_override : antag_flag
candidates = pollGhostCandidates("The mode is looking for volunteers to become [antag_flag] for [name]", flag, be_special_flag = flag, ignore_category = antag_flag, poll_time = 300)

candidates = pollGhostCandidates("The mode is looking for volunteers to become [antag_flag] for [name]", antag_flag, be_special_flag = antag_flag_override ? antag_flag_override : antag_flag, poll_time = 300)

if(!candidates || candidates.len <= 0)
if(!length(candidates))
mode.dynamic_log("The ruleset [name] received no applications.")
mode.executed_rules -= src
attempt_replacement()
Expand Down Expand Up @@ -164,19 +169,10 @@
/datum/dynamic_ruleset/midround/from_ghosts/proc/setup_role(datum/antagonist/new_role)
return

/// Fired when there are no valid candidates. Will spawn a sleeper agent or latejoin traitor.
/// Fired when there are no valid candidates. Will try to roll again in a minute.
/datum/dynamic_ruleset/midround/from_ghosts/proc/attempt_replacement()
var/datum/dynamic_ruleset/midround/autotraitor/sleeper_agent = new

// Otherwise, it has a chance to fail. We don't want that, since this is already pretty unlikely.
sleeper_agent.has_failure_chance = FALSE

mode.configure_ruleset(sleeper_agent)

if (!mode.picking_specific_rule(sleeper_agent))
return

mode.picking_specific_rule(/datum/dynamic_ruleset/latejoin/infiltrator)
COOLDOWN_START(mode, midround_injection_cooldown, 1 MINUTES)
mode.forced_injection = TRUE

//////////////////////////////////////////////
// //
Expand Down Expand Up @@ -233,9 +229,8 @@
return ..()

/datum/dynamic_ruleset/midround/autotraitor/execute()
var/mob/M = pick(living_players)
var/mob/M = pick_n_take(living_players)
assigned += M
living_players -= M
var/datum/antagonist/traitor/newTraitor = new
M.mind.add_antag_datum(newTraitor)
message_admins("[ADMIN_LOOKUPFLW(M)] was selected by the [name] ruleset and has been made into a midround traitor.")
Expand Down Expand Up @@ -335,7 +330,7 @@
candidates -= player
continue

if(player.mind && (player.mind.special_role || player.mind.antag_datums?.len > 0))
if(player.mind && (player.mind.special_role || length(player.mind.antag_datums)))
candidates -= player

/datum/dynamic_ruleset/midround/malf/execute()
Expand All @@ -354,6 +349,70 @@
M.add_ion_law(generate_ion_law())
return TRUE

//////////////////////////////////////////////
// //
// WIZARD (CREW) //
// //
//////////////////////////////////////////////

/datum/dynamic_ruleset/midround/wizard
name = "Wizard"
antag_datum = /datum/antagonist/wizard
antag_flag = "wizard mid crew"
antag_flag_override = ROLE_WIZARD
protected_roles = list("Prisoner", "Security Officer", "Warden", "Detective", "Head of Security", "Captain", "Chaplain", "Head of Personnel", "Quartermaster", "Chief Engineer", "Chief Medical Officer", "Research Director")
restricted_roles = list("AI", "Cyborg")
enemy_roles = list("Security Officer","Detective","Head of Security", "Captain")
required_enemies = list(0,0,0,0,0,0,0,0,0,0)
weight = 0
cost = 20
requirements = list(101,101,100,60,40,20,20,20,10,10)
repeatable = TRUE
var/datum/mind/wizard

/datum/dynamic_ruleset/midround/wizard/trim_candidates()
..()
candidates = living_players
for(var/mob/living/player as anything in candidates)
var/turf/player_turf = get_turf(player)
if(!player_turf || !is_station_level(player_turf.z))
candidates -= player
continue

if(player.mind && (player.mind.special_role || length(player.mind.antag_datums) > 0))
candidates -= player
candidates = pollCandidates("Do you want to be a wizard?", antag_flag_override, be_special_flag = antag_flag_override, ignore_category = antag_flag_override, poll_time = 300)

/datum/dynamic_ruleset/midround/wizard/ready(forced = FALSE)
if(GLOB.wizardstart.len == 0)
log_admin("Cannot accept Wizard ruleset. Couldn't find any wizard spawn points.")
message_admins("Cannot accept Wizard ruleset. Couldn't find any wizard spawn points.")
return FALSE
return ..()

/datum/dynamic_ruleset/midround/wizard/execute()
var/mob/M = pick_n_take(living_players)
assigned += M
var/datum/antagonist/wizard/on_station/wiz = new
M.mind.add_antag_datum(wiz)
wizard = M.mind
message_admins("[ADMIN_LOOKUPFLW(M)] was selected by the [name] ruleset and has been made into a midround wizard.")
log_game("DYNAMIC: [key_name(M)] was selected by the [name] ruleset and has been made into a midround wizard.")
return TRUE

/datum/dynamic_ruleset/midround/wizard/rule_process()
if(isliving(wizard.current) && wizard.current.stat!=DEAD)
return FALSE
for(var/obj/item/phylactery/P in GLOB.poi_list) //TODO : IsProperlyDead()
if(P.mind && P.mind.has_antag_datum(/datum/antagonist/wizard))
return FALSE

if(SSevents.wizardmode) //If summon events was active, turn it off
SSevents.toggleWizardmode()
SSevents.resetFrequency()

return RULESET_STOP_PROCESSING

//////////////////////////////////////////////
// //
// WIZARD (GHOST) //
Expand Down Expand Up @@ -626,11 +685,11 @@
candidates -= player

/datum/dynamic_ruleset/midround/blob_infection/execute()
if(!candidates || !candidates.len)
if(!length(candidates))
return FALSE
var/mob/living/carbon/human/blob_antag = pick_n_take(candidates)
assigned += blob_antag.mind
blob_antag.mind.special_role = antag_flag
blob_antag.mind.special_role = antag_flag_override
return ..()

//////////////////////////////////////////////
Expand Down
2 changes: 1 addition & 1 deletion code/game/machinery/doors/firedoor.dm
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@
/obj/machinery/door/firedoor/power_change()
if(powered(power_channel))
stat &= ~NOPOWER
latetoggle()
INVOKE_ASYNC(src, .proc/latetoggle)
else
stat |= NOPOWER

Expand Down
28 changes: 24 additions & 4 deletions code/modules/antagonists/wizard/wizard.dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#define WIZARD_DO_NOTHING 0
#define WIZARD_QDEL_INVENTORY 1
#define WIZARD_DROP_INVENTORY 2

/datum/antagonist/wizard
name = "Space Wizard"
roundend_category = "wizards/witches"
Expand All @@ -10,7 +14,8 @@
ui_name = "AntagInfoWizard"
suicide_cry = "FOR THE FEDERATION!!"
var/give_objectives = TRUE
var/strip = TRUE //strip before equipping
var/inventory_mode = WIZARD_QDEL_INVENTORY
var/change_species = TRUE
var/allow_rename = TRUE
var/datum/team/wizard/wiz_team //Only created if wizard summons apprentices
var/move_to_lair = TRUE
Expand Down Expand Up @@ -93,10 +98,14 @@
var/mob/living/carbon/human/H = owner.current
if(!istype(H))
return
if(strip)
H.delete_equipment()
switch(inventory_mode)
if(WIZARD_QDEL_INVENTORY)
H.delete_equipment()
if(WIZARD_DROP_INVENTORY)
H.unequip_everything()
//Wizards are human by default. Use the mirror if you want something else.
H.set_species(/datum/species/human)
if(change_species)
H.set_species(/datum/species/human)
if(H.age < wiz_age)
H.age = wiz_age
H.equipOutfit(outfit_type)
Expand Down Expand Up @@ -256,6 +265,17 @@
new_objective.owner = owner
objectives += new_objective

/datum/antagonist/wizard/on_station
inventory_mode = WIZARD_DROP_INVENTORY
change_species = FALSE

/datum/antagonist/wizard/on_station/on_gain()
var/datum/effect_system/smoke_spread/smoke = new
smoke.start()
smoke.set_up(2, get_turf(owner))
owner.current.visible_message("<span class='danger'>[owner] suddenly disappears in a puff of smoke, leaving [owner.p_their()] clothes behind!</span>", "<span class='userdanger'>You feel yourself being pulled away...</span>")
return ..()

//Solo wizard report
/datum/antagonist/wizard/roundend_report()
var/list/parts = list()
Expand Down
8 changes: 4 additions & 4 deletions code/modules/holiday/halloween/bartholomew.dm
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

/obj/item/barthpot/attackby(obj/item/I, mob/user, params)
if(BallTutorial)
say("Hello and welcome to the annual Citadelstation Spookyball 2021! CENTCOM requisitioned this old hospital as a new colony site two years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
say("Hello and welcome to the annual Citadel Station Spooky Ball [time2text(world.realtime, "YYYY")]! CENTCOM requisitioned this old hospital as a new colony site [text2num(time2text(world.realtime,"YYYY")) - 2019] years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
return
if(!active)
say("Meow!")
Expand All @@ -24,23 +24,23 @@
if(istype(I, I2))
qdel(I)
new /obj/item/reagent_containers/food/snacks/special_candy(loc)
to_chat(user, "<span class='notice'>You add the [I.name] to the pot and watch as it melts into the mixture, a candy crystalising in it's wake.</span>")
to_chat(user, "<span class='notice'>You add the [I.name] to the pot and watch as it melts into the mixture, a candy crystallizing in it's wake.</span>")
say("Hooray! Thank you!")
items_list -= I2
return
say("It doesn't seem like that's magical enough!")

/obj/item/barthpot/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
if(BallTutorial)
say("Hello and welcome to the annual Citadelstation Spookyball 2021! CENTCOM requisitioned this old hospital as a new colony site two years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
say("Hello and welcome to the annual Citadel Station Spooky Ball [time2text(world.realtime, "YYYY")]! CENTCOM requisitioned this old hospital as a new colony site [text2num(time2text(world.realtime,"YYYY")) - 2019] years ago, and we’re back again after a few additions here and there. Next to me you can find all the tools you’ll need to build a nice private house, if you’re here for that kind of thing. The axes will chop trees, and give you wood. Shovels will remove grass and things, which you can use the grass to make beds and backets. The pickaxe will allow you pick out the nearby rocks, if you’re more interested in building a cave dwelling. Finally the umbrella and light sources are because it’s spooky, and it might rain! As for interesting spots; There’s the old abandoned mansion which you can get to by going through the entrance and towards the east. There’s also a mech arena directly south, and a racetrack in the caves to the right of the arena, follow the lanterns. And make sure to explore the caves too! Lots of neat things to find!")
return
if(!active)
say("Meow!")
return
say("Hello there, I'm Bartholomew, Jacqueline's Familiar.")
sleep(20)

say("I'm currently seeking items to put into my pot, if we get the right items, it should crystalise into a magic candy!")
say("I'm currently seeking items to put into my pot, if we get the right items, it should crystalize into a magic candy!")
if(!iscarbon(user))
say("Though... I'm not sure you can help me.")

Expand Down
2 changes: 1 addition & 1 deletion code/modules/power/power.dm
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@
addStaticPower(-value, powerchannel)

/obj/machinery/proc/power_change()
//SIGNAL_HANDLER
SHOULD_NOT_SLEEP(TRUE)
//SHOULD_CALL_PARENT(TRUE)

if(stat & BROKEN)
Expand Down
12 changes: 12 additions & 0 deletions code/modules/projectiles/gun.dm
Original file line number Diff line number Diff line change
Expand Up @@ -807,6 +807,18 @@
icon_icon = 'icons/mob/actions/actions_items.dmi'
button_icon_state = "sniper_zoom"

/datum/action/item_action/toggle_scope_zoom/IsAvailable(silent = FALSE)
. = ..()
if(!. && owner)
var/obj/item/gun/G = target
G.zoom(owner, owner.dir, FALSE)

/datum/action/item_action/toggle_scope_zoom/Trigger()
. = ..()
if(.)
var/obj/item/gun/G = target
G.zoom(owner, owner.dir)

/datum/action/item_action/toggle_scope_zoom/Remove(mob/living/L)
var/obj/item/gun/G = target
G.zoom(L, L.dir, FALSE)
Expand Down
29 changes: 16 additions & 13 deletions code/modules/shuttle/emergency.dm
Original file line number Diff line number Diff line change
Expand Up @@ -583,29 +583,32 @@
dwidth = 1
width = 3
height = 4
var/target_area = list(/area/lavaland/surface/outdoors, /area/icemoon/underground/unexplored/rivers)
/// The area the pod tries to land at
var/target_area = /area/lavaland/surface/outdoors
/// Minimal distance from the map edge, setting this too low can result in shuttle landing on the edge and getting "sliced"
var/edge_distance = 16
// Minimal distance from the map edge, setting this too low can result in shuttle landing on the edge and getting "sliced"

/obj/docking_port/stationary/random/Initialize(mapload)
. = ..()
if(!mapload)
return

var/list/turfs = get_area_turfs(target_area)

if(turfs.len == 0)
return

var/turf/T = pick(turfs)

var/original_len = turfs.len
while(turfs.len)
if(T.x<edge_distance || T.y<edge_distance || (world.maxx+1-T.x)<edge_distance || (world.maxy+1-T.y)<edge_distance)
turfs -= T
T = pick(turfs)
var/turf/picked_turf = pick(turfs)
if(picked_turf.x<edge_distance || picked_turf.y<edge_distance || (world.maxx+1-picked_turf.x)<edge_distance || (world.maxy+1-picked_turf.y)<edge_distance)
turfs -= picked_turf
else
forceMove(T)
break
forceMove(picked_turf)
return

// Fallback: couldn't find anything
WARNING("docking port '[id]' could not be randomly placed in [target_area]: of [original_len] turfs, none were suitable")
return INITIALIZE_HINT_QDEL

/obj/docking_port/stationary/random/icemoon
target_area = /area/icemoon/surface/outdoors

//Pod suits/pickaxes
/obj/item/clothing/head/helmet/space/orange
Expand Down
Loading

0 comments on commit a962190

Please sign in to comment.