Skip to content

Commit

Permalink
Runtimes Fun Around (BlueMoon-Labs#981)
Browse files Browse the repository at this point in the history
* some runtimes

* better

* admin panel fix

* some more fun around

* microwave moment (byond moment)

* упс

* nuh uh

---------

Co-authored-by: BlackCrystalic <[email protected]>
Co-authored-by: Марк <[email protected]>
  • Loading branch information
3 people authored May 6, 2024
1 parent 1deb7ef commit 06300b0
Show file tree
Hide file tree
Showing 17 changed files with 31 additions and 28 deletions.
3 changes: 3 additions & 0 deletions code/_onclick/hud/hud.dm
Original file line number Diff line number Diff line change
Expand Up @@ -626,6 +626,9 @@ GLOBAL_LIST_INIT(available_ui_styles, list(
palette.set_expanded(FALSE)

/datum/action_group/palette/refresh_actions()
if(!owner)
return

var/atom/movable/screen/button_palette/palette = owner.toggle_palette
var/atom/movable/screen/palette_scroll/scroll_down = owner.palette_down
var/atom/movable/screen/palette_scroll/scroll_up = owner.palette_up
Expand Down
2 changes: 1 addition & 1 deletion code/datums/action.dm
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@
if(action == src) // This could be us, which is dumb
continue
var/atom/movable/screen/movable/action_button/button = action.viewers[owner.hud_used]
if(action.name == name && button.id)
if(action.name == name && button?.id)
bitfield |= button.id

bitfield = ~bitfield // Flip our possible ids, so we can check if we've found a unique one
Expand Down
2 changes: 1 addition & 1 deletion code/datums/traits/_quirk.dm
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
/// A lazylist of items people can receive from mail who have this quirk enabled
/// The base weight for the each quirk's mail goodies list to be selected is 5
/// then the item selected is determined by pick(selected_quirk.mail_goodies)
var/list/mail_goodies
var/list/mail_goodies = list()

/datum/quirk/New(mob/living/quirk_mob, spawn_effects)
if(!quirk_mob || (human_only && !ishuman(quirk_mob)) || quirk_mob.has_quirk(type))
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items.dm
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ GLOBAL_VAR_INIT(embedpocalypse, FALSE) // if true, all items will be able to emb
dat += "[src] is also capable of automatically blocking damage, if you are facing the right direction (usually towards your attacker)!"
if(item_flags & ITEM_CAN_PARRY)
dat += "[src] can be used to parry damage using active parry. Pressed your active parry keybind to initiate a timed parry sequence."
if(data.parry_automatic_enabled)
if(data?.parry_automatic_enabled)
dat += "[src] is also capable of automatically parrying an incoming attack, if your mouse is over your attacker at the time if you being hit in a direct, melee attack."
dat += "Examine [src] to get a full readout of its block/parry stats."
to_chat(user, dat.Join("<br>"))
Expand Down
2 changes: 1 addition & 1 deletion code/modules/admin/DB_ban/functions.dm
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@
for(var/j in list(ROLE_TRAITOR, ROLE_CHANGELING, ROLE_OPERATIVE, ROLE_REV, ROLE_CULTIST, ROLE_WIZARD, ROLE_HERETIC))
output += "<option value='[j]'>[j]</option>"
output += "</select></td></tr></table>"
output += "<b>Reason:<br></b><textarea name='dbbanreason' cols='50'></textarea><br>"
output += "<b>Reason:<br></b><textarea name='dbbanreason' charset='UTF-8' cols='50'></textarea><br>"
output += "<input type='submit' value='Add ban'>"
output += "</form>"

Expand Down
2 changes: 1 addition & 1 deletion code/modules/ambitions/ambition_objective.dm
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
var/list/players = list()
for(var/i in GLOB.joined_player_list) // BLUEMOON EDIT - было for(var/mob/living/carbon/human/player in GLOB.player_list)
var/mob/player = get_mob_by_ckey(i) // BLUEMOON ADD
if(!player || !player.mind || player.mind.assigned_role == player.mind.special_role || player.client.inactivity > 10 MINUTES || player.mind == owner) //BLUEMOON ADD рантаймы с нулями без !players
if(!player || !player.client || !player.mind || player.mind.assigned_role == player.mind.special_role || player.client.inactivity > 10 MINUTES || player.mind == owner) //BLUEMOON ADD рантаймы с нулями без !players или без !player.client
continue
players += player.real_name
var/random_player = "Капитан"
Expand Down
1 change: 1 addition & 0 deletions code/modules/awaymissions/corpse.dm
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@
if(ishuman(M) && load_character)
var/mob/living/carbon/human/H = M
var/mob/grab = get_mob_by_ckey(ckey)
grab.mind.transfer_to(H)
H.load_client_appearance(grab.client)
equip(M, load_character)

Expand Down
3 changes: 2 additions & 1 deletion code/modules/clothing/under/accessories.dm
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,8 @@
if(detached_pockets && detached_pockets.parent == U)
TakeComponent(detached_pockets)

U.armor = U.armor.detachArmor(armor)
if(U.armor && armor)
U.armor = U.armor.detachArmor(armor)
//SANDSTORM EDIT
current_uniform = null
//SANDSTORM EDIT END
Expand Down
4 changes: 4 additions & 0 deletions code/modules/food_and_drinks/kitchen_machinery/microwave.dm
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,10 @@
var/ingredient_count = 0

for (var/atom/movable/ingredient as anything in ingredients)
//BLUEMOON FIX
if(ingredient_count > 90)// don't fuck around with byond overlays for too long, or byond overlays fuck you around.
break
//BLUEMOON FIX
var/image/ingredient_overlay = image(ingredient, src)

var/icon/ingredient_icon = icon(ingredient.icon, ingredient.icon_state)
Expand Down
2 changes: 1 addition & 1 deletion code/modules/holiday/holidays.dm
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
var/obj/item/drone_hat //If this is defined, drones without a default hat will spawn with this one during the holiday; check drones_as_items.dm to see this used

// Special things to be given during this!
var/list/mail_goodies
var/list/mail_goodies = list()

// This proc gets run before the game starts when the holiday is activated. Do festive shit here.
/datum/holiday/proc/celebrate()
Expand Down
2 changes: 1 addition & 1 deletion code/modules/mob/living/carbon/human/human_defense.dm
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
continue
if(istype(bp, /obj/item/clothing))
var/obj/item/clothing/C = bp
if(C.body_parts_covered & def_zone.body_part)
if(C.body_parts_covered & def_zone.body_part && C.armor)
protection += C.armor.getRating(d_type)
protection += physiology.armor.getRating(d_type)
return protection
Expand Down
8 changes: 4 additions & 4 deletions code/modules/surgery/bodyparts/_bodyparts.dm
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@
for(var/i in clothing)
var/obj/item/clothing/clothes_check = i
// unlike normal armor checks, we tabluate these piece-by-piece manually so we can also pass on appropriate damage the clothing's limbs if necessary
if(clothes_check.armor.getRating(WOUND))
if(clothes_check.armor?.getRating(WOUND))
bare_wound_bonus = 0
break

Expand Down Expand Up @@ -469,10 +469,10 @@
if(owner && ishuman(owner))
var/mob/living/carbon/human/H = owner
var/list/clothing = H.clothingonpart(src)
for(var/c in clothing)
var/obj/item/clothing/C = c
for(var/obj/item/clothing/C as anything in clothing)
// unlike normal armor checks, we tabluate these piece-by-piece manually so we can also pass on appropriate damage the clothing's limbs if necessary
armor_ablation += C.armor.getRating(WOUND)
if(C.armor)
armor_ablation += C.armor.getRating(WOUND)
if(wounding_type == WOUND_SLASH)
C.take_damage_zone(body_zone, damage, BRUTE, armour_penetration)
else if(wounding_type == WOUND_BURN && damage >= 10) // lazy way to block freezing from shredding clothes without adding another var onto apply_damage()
Expand Down
13 changes: 1 addition & 12 deletions config/entries/dbconfig.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
## MySQL Connection Configuration
## This is used for stats, feedback gathering,
## administration, and the in game library.

## Should SQL be enabled? Uncomment to enable
Expand Down Expand Up @@ -33,16 +31,7 @@ FEEDBACK_PASSWORD password
## Set to 0 for infinite
ASYNC_QUERY_TIMEOUT 10

## Time in seconds for blocking queries to execute before slow query timeout
## Time in seconds for blocking queries to execute before slow query timeout
## Set to 0 for infinite
## Must be less than or equal to ASYNC_QUERY_TIMEOUT
BLOCKING_QUERY_TIMEOUT 5

## The maximum number of additional threads BSQL is allowed to run at once
BSQL_THREAD_LIMIT 50

## Uncomment to enable verbose BSQL communication logs
#BSQL_DEBUG

## Time to wait before considering a query as lingering too long
@QUERY_DEBUG_LOG_TIMEOUT 70
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
if(player_client.prefs.silicon_lawset)
var/list/laws = CONFIG_GET(keyed_list/choosable_laws)
var/law_path = text2path(laws[player_client.prefs.silicon_lawset])
var/obj/item/ai_module/chosenboard = new law_path
chosenboard.install(R.laws, usr)
qdel(chosenboard)
if(ispath(law_path))
var/obj/item/ai_module/chosenboard = new law_path
chosenboard.install(R.laws, usr)
qdel(chosenboard)
3 changes: 2 additions & 1 deletion modular_bluemoon/shower_trait/shower_trait.dm
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@
// забираем способность изменения оверлея вони
var/mob/living/carbon/human/H = quirk_holder
var/datum/action/cooldown/change_stink_overlay/C = locate() in H.actions
C.Remove(H)
if(C)
C.Remove(H)

quirk_holder.cut_overlay(stink_overlay) // удаляем оверлей вони с игрока

Expand Down
3 changes: 3 additions & 0 deletions strings/ambitions/security.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,5 +106,8 @@
"Преступник может быть полезен для станции. Организовать рабочее место для преступников, которые будут отрабатывать принесенные расходы на их содержание - неплохая идея.",
"У меня есть 9-миллиметровые пальцы-пистолеты. Устрою с мимом перестрелку.",
"На все дела беру с собой служебного пса."
],
"Internal Affairs Agent": [
"SET ME"
]
}
Binary file not shown.

0 comments on commit 06300b0

Please sign in to comment.