Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into ContainerTypeRefactor

This commit is contained in:
variableundefined
2018-10-13 19:16:41 +08:00
21 changed files with 168 additions and 81 deletions
@@ -24,35 +24,31 @@ Bonus
level = 5
severity = 0
/datum/symptom/sensory_restoration/proc/check_and_add(reagent, check, add, mob/living/M)
if(M.reagents.get_reagent_amount(reagent) < check)
M.reagents.add_reagent(reagent, add)
return 1
/datum/symptom/sensory_restoration/Activate(var/datum/disease/advance/A)
..()
if(prob(SYMPTOM_ACTIVATION_PROB * 3))
var/mob/living/M = A.affected_mob
var/datum/reagents/RD = M.reagents
switch(A.stage)
if(2)
if(check_and_add("oculine", 10, 10, M))
if(RD.check_and_add("oculine", 10, 10))
to_chat(M, "<span class='notice'>Your hearing feels clearer and crisp.</span>")
if(3)
if(check_and_add("antihol", 10, 10, M))
if(RD.check_and_add("antihol", 10, 10))
to_chat(M, "<span class='notice'>You feel sober.</span>")
check_and_add("oculine", 10, 10, M)
RD.check_and_add("oculine", 10, 10)
if(4)
if(check_and_add("synaphydramine", 10, 5, M))
if(RD.check_and_add("synaphydramine", 10, 5))
to_chat(M, "<span class='notice'>You feel focused.</span>")
check_and_add("antihol", 10, 10, M)
check_and_add("oculine", 10, 10, M)
RD.check_and_add("antihol", 10, 10)
RD.check_and_add("oculine", 10, 10)
if(5)
if(check_and_add("mannitol", 10, 10, M))
if(RD.check_and_add("mannitol", 10, 10))
to_chat(M, "<span class='notice'>Your mind feels relaxed.</span>")
check_and_add("synaphydramine", 10, 5, M)
check_and_add("antihol", 10, 10, M)
check_and_add("oculine", 10, 10, M)
RD.check_and_add("synaphydramine", 10, 5)
RD.check_and_add("antihol", 10, 10)
RD.check_and_add("oculine", 10, 10)
return
@@ -736,6 +736,8 @@ Congratulations! You are now trained for invasive xenobiology research!"}
icon_state = "bed"
no_icon_updates = 1 //no icon updates for this; it's static.
injected_reagents = list("corazone","spaceacillin")
reagent_target_amount = 31 //the patient needs at least 30u of spaceacillin to prevent necrotization.
inject_amount = 10
/obj/structure/closet/abductor
name = "alien locker"
+4 -2
View File
@@ -15,6 +15,8 @@
buckle_lying = 90
var/no_icon_updates = 0 //set this to 1 if you don't want the icons ever changing
var/list/injected_reagents = list()
var/reagent_target_amount = 1
var/inject_amount = 1
/obj/machinery/optable/New()
..()
@@ -106,9 +108,9 @@
check_victim()
if(LAZYLEN(injected_reagents))
for(var/mob/living/carbon/C in get_turf(src))
var/datum/reagents/R = C.reagents
for(var/chemical in injected_reagents)
if(C.reagents.get_reagent_amount(chemical) < 1)
C.reagents.add_reagent(chemical, 1)
R.check_and_add(chemical,reagent_target_amount,inject_amount)
/obj/machinery/optable/proc/take_victim(mob/living/carbon/C, mob/living/carbon/user as mob)
if(C == user)
+8 -2
View File
@@ -241,8 +241,12 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
data["censored"] = viewing_channel.censored
var/list/messages = list()
data["messages"] = messages
var/message_number = 0
for(var/datum/feed_message/M in viewing_channel.messages)
messages[++messages.len] = list("title" = M.title, "body" = M.body, "img" = M.img ? icon2base64(M.img) : null, "message_type" = M.message_type, "author" = M.author, "view_count" = M.view_count)
if(M.img)
user << browse_rsc(M.img, "tmp_photo[message_number].png")
messages[++messages.len] = list("title" = M.title, "body" = M.body, "img" = M.img ? M.img : null, "message_type" = M.message_type, "author" = M.author, "view_count" = M.view_count, "message_number" = message_number)
message_number += 1
if(8, 9)
data["channel_name"] = viewing_channel.channel_name
data["ref"] = "\ref[viewing_channel]"
@@ -273,7 +277,9 @@ var/list/obj/machinery/newscaster/allCasters = list() //Global list that will co
data["author"] = news_network.wanted_issue.backup_author
data["criminal"] = news_network.wanted_issue.author
data["description"] = news_network.wanted_issue.body
data["photo"] = news_network.wanted_issue.img ? icon2base64(news_network.wanted_issue.img) : 0
if(news_network.wanted_issue.img)
user << browse_rsc(news_network.wanted_issue.img, "tmp_photow.png")
data["photo"] = news_network.wanted_issue.img ? news_network.wanted_issue.img : 0
if(12)
var/list/jobs = list()
data["jobs"] = jobs
+1 -1
View File
@@ -70,7 +70,7 @@
/obj/item/assembly/voice/noise/hear_talk(mob/living/M as mob, msg)
return
/obj/item/assembly/voice/hear_message(mob/living/M as mob, msg)
/obj/item/assembly/voice/noise/hear_message(mob/living/M as mob, msg)
pulse(0)
var/turf/T = get_turf(src) //otherwise it won't work in hand
T.visible_message("<span class='warning'>[bicon(src)] beeps!</span>")
+3 -3
View File
@@ -14,12 +14,12 @@
A.do_attack_animation(D, ATTACK_EFFECT_PUNCH)
var/atk_verb = pick("left hook","right hook","straight punch")
var/damage = rand(5, 8) + A.dna.species.punchdamagelow
if(!damage)
playsound(D.loc, 'sound/weapons/punchmiss.ogg', 25, 1, -1)
D.visible_message("<span class='warning'>[A] has attempted to hit [D] with a [atk_verb]!</span>")
add_attack_logs(A, D, "Melee attacked with [src] (miss/block)")
add_attack_logs(A, D, "Melee attacked with [src] (miss/block)", ATKLOG_ALL)
return 0
@@ -32,7 +32,7 @@
"<span class='userdanger'>[A] has hit [D] with a [atk_verb]!</span>")
D.apply_damage(damage, STAMINA, affecting, armor_block)
add_attack_logs(A, D, "Melee attacked with [src]")
add_attack_logs(A, D, "Melee attacked with [src]", ATKLOG_ALL)
if(D.getStaminaLoss() > 50)
var/knockout_prob = D.getStaminaLoss() + rand(-15,15)
if((D.stat != DEAD) && prob(knockout_prob))
+1 -1
View File
@@ -1019,7 +1019,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
return 1
/mob/living/carbon/proc/forceFedAttackLog(var/obj/item/reagent_containers/food/toEat, mob/user)
add_attack_logs(user, src, "Fed [toEat]. Reagents: [toEat.reagents.log_list(toEat)]", ATKLOG_FEW)
add_attack_logs(user, src, "Fed [toEat]. Reagents: [toEat.reagents.log_list(toEat)]", ATKLOG_MOST)
if(!iscarbon(user))
LAssailant = null
else
@@ -29,7 +29,7 @@
if(dna.species && dna.species.has_organ["brain"])
var/obj/item/organ/internal/brain/sponge = get_int_organ(/obj/item/organ/internal/brain)
if(sponge)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.brain_mod
sponge.receive_damage(amount, 1)
if(updating)
@@ -43,7 +43,7 @@
if(dna.species && dna.species.has_organ["brain"])
var/obj/item/organ/internal/brain/sponge = get_int_organ(/obj/item/organ/internal/brain)
if(sponge)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.brain_mod
sponge.damage = min(max(amount, 0), (maxHealth*2))
if(updating)
@@ -76,11 +76,10 @@
amount += O.burn_dam
return amount
/mob/living/carbon/human/adjustBruteLoss(amount, updating_health = TRUE, damage_source = null, robotic = FALSE)
if(dna.species)
amount = amount * dna.species.brute_mod
if(amount > 0)
if(dna.species)
amount = amount * dna.species.brute_mod
take_overall_damage(amount, 0, updating_health, used_weapon = damage_source)
else
heal_overall_damage(-amount, 0, updating_health, FALSE, robotic)
@@ -88,9 +87,9 @@
return STATUS_UPDATE_HEALTH
/mob/living/carbon/human/adjustFireLoss(amount, updating_health = TRUE, damage_source = null, robotic = FALSE)
if(dna.species)
amount = amount * dna.species.burn_mod
if(amount > 0)
if(dna.species)
amount = amount * dna.species.burn_mod
take_overall_damage(0, amount, updating_health, used_weapon = damage_source)
else
heal_overall_damage(0, -amount, updating_health, FALSE, robotic)
@@ -98,9 +97,8 @@
return STATUS_UPDATE_HEALTH
/mob/living/carbon/human/proc/adjustBruteLossByPart(amount, organ_name, obj/damage_source = null, updating_health = TRUE)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.brute_mod
if(organ_name in bodyparts_by_name)
var/obj/item/organ/external/O = get_organ(organ_name)
@@ -111,9 +109,8 @@
O.heal_damage(-amount, 0, internal = 0, robo_repair = O.is_robotic(), updating_health = updating_health)
return STATUS_UPDATE_HEALTH
/mob/living/carbon/human/proc/adjustFireLossByPart(amount, organ_name, obj/damage_source = null, updating_health = TRUE)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.burn_mod
if(organ_name in bodyparts_by_name)
@@ -134,7 +131,7 @@
return ..()
/mob/living/carbon/human/adjustCloneLoss(amount)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.clone_mod
. = ..()
@@ -174,22 +171,22 @@
// Defined here solely to take species flags into account without having to recast at mob/living level.
/mob/living/carbon/human/adjustOxyLoss(amount)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.oxy_mod
. = ..()
/mob/living/carbon/human/setOxyLoss(amount)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.oxy_mod
. = ..()
/mob/living/carbon/human/adjustToxLoss(amount)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.tox_mod
. = ..()
/mob/living/carbon/human/setToxLoss(amount)
if(dna.species)
if(dna.species && amount > 0)
amount = amount * dna.species.tox_mod
. = ..()
@@ -594,6 +594,11 @@ var/const/INGEST = 2
return 1
/datum/reagents/proc/check_and_add(reagent, check, add)
if(get_reagent_amount(reagent) < check)
add_reagent(reagent, add)
return TRUE
/datum/reagents/proc/remove_reagent(reagent, amount, safety)//Added a safety check for the trans_id_to
if(!isnum(amount))
@@ -20,7 +20,7 @@
/obj/machinery/chem_master/New()
create_reagents(100)
overlays += "waitlight"
update_icon()
/obj/machinery/chem_master/ex_act(severity)
switch(severity)
@@ -32,6 +32,12 @@
qdel(src)
return
/obj/machinery/chem_master/update_icon()
overlays.Cut()
icon_state = "mixer[beaker ? "1" : "0"][powered() ? "" : "_nopower"]"
if(powered())
overlays += "waitlight"
/obj/machinery/chem_master/blob_act()
if(prob(50))
qdel(src)
@@ -57,7 +63,7 @@
B.forceMove(src)
to_chat(user, "<span class='notice'>You add the beaker to the machine!</span>")
SSnanoui.update_uis(src)
icon_state = "mixer1"
update_icon()
else if(istype(B, /obj/item/storage/pill_bottle))
@@ -184,7 +190,7 @@
beaker.forceMove(get_turf(src))
beaker = null
reagents.clear_reagents()
icon_state = "mixer0"
update_icon()
else if(href_list["createpill"] || href_list["createpill_multiple"])
if(!condi)
var/count = 1
@@ -411,6 +411,7 @@
l_pocket = /obj/item/grenade/clusterbuster/holy
shoes = /obj/item/clothing/shoes/magboots/advance
glasses = /obj/item/clothing/glasses/night
r_pocket = /obj/item/nullrod
cybernetic_implants = list(
/obj/item/organ/internal/cyberimp/chest/nutriment/plus,
+58
View File
@@ -56,6 +56,36 @@
-->
<div class="commit sansserif">
<h2 class="date">13 October 2018</h2>
<h3 class="author">Birdtalon updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Chem master now will show its de-powered state properly.</li>
</ul>
<h3 class="author">DarkPyrolord updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Changed attack log level for reagent forcefeeding from FEW to MOST</li>
</ul>
<h3 class="author">FlimFlamm updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Tweaked formatting of Newscaster stories</li>
<li class="bugfix">Fixes images displaying improperly on Newscaster stories</li>
</ul>
<h3 class="author">Ty-Omaha updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Boxing logs moved to the ALL preference</li>
</ul>
<h3 class="author">alex-gh updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Species damage modifiers now only affect damage, not healing.</li>
<li class="tweak">Races that took more damage from certain damage types no longer heal from that damage type faster. For example: Drask no longer heal from burn at double rate; Grey, Vox no longer heal from brute at increased rate (Note: IPC healing with welders/wires is not affected).</li>
<li class="tweak">Kidan no longer heal from brute at a reduced rate.</li>
</ul>
<h3 class="author">uc_guy updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">You can no longer get an infection and die during abductor surgery.</li>
<li class="bugfix">Voice analyzers no longer activate on noise.</li>
</ul>
<h2 class="date">12 October 2018</h2>
<h3 class="author">Alonefromhell updated:</h3>
<ul class="changes bgimages16">
@@ -63,6 +93,34 @@
<li class="bugfix">META - Cargo shuttle airlocks now bolt properly.</li>
<li class="bugfix">META - Cargo shuttle flaps are now airtight. All hail Cargonia.</li>
</ul>
<h3 class="author">Birdtalon updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Gamma ERT Paranormal gets their null rod.</li>
<li class="tweak">Moves check_and_add() to reagents holder</li>
</ul>
<h3 class="author">DesolateG updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Refactors global var lists to use the global subsystem.</li>
</ul>
<h3 class="author">Farie82 updated:</h3>
<ul class="changes bgimages16">
<li class="rscadd">Added the on_give proc for items. Was needed for the fixes</li>
<li class="bugfix">Giving two handed items like the DIY chainsaw and potted plants now works correctly</li>
<li class="bugfix">The DIY chainsaw, doomslayer chainsaw and the potted plants now do damage when given to somebody else and when picked up while the chainsaw was on.</li>
</ul>
<h3 class="author">Purpose updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Cyberiad's grimy tiles are now actually dirty and cleanable.</li>
<li class="tweak">Delta's grimy tiles are now actually dirty and cleanable.</li>
<li class="bugfix">Ironsand is now visible in the Map Maker.</li>
<li class="bugfix">Away missions updated with the appropriate dirt/grime so that it is now cleanable.</li>
<li class="bugfix">Fixes stool's unique suicide message.</li>
<li class="bugfix">Fixes rollerbeds no longer going through plastic flaps.</li>
</ul>
<h3 class="author">TDSSS updated:</h3>
<ul class="changes bgimages16">
<li class="bugfix">Removed Skrell discrimination, allows ! character in IDs (agent IDs or made via ID computer)</li>
</ul>
<h3 class="author">variableundefined updated:</h3>
<ul class="changes bgimages16">
<li class="tweak">Ore now represented by stack that holds up to 50 items. Should reduce lag with ORM greatly.</li>
+42
View File
@@ -7442,6 +7442,28 @@ DO NOT EDIT THIS FILE BY HAND! AUTOMATICALLY GENERATED BY ss13_genchangelog.py.
- bugfix: META - Cargo shuttle blast doors now reacts to the right button.
- bugfix: META - Cargo shuttle airlocks now bolt properly.
- bugfix: META - Cargo shuttle flaps are now airtight. All hail Cargonia.
Birdtalon:
- bugfix: Gamma ERT Paranormal gets their null rod.
- tweak: Moves check_and_add() to reagents holder
DesolateG:
- tweak: Refactors global var lists to use the global subsystem.
Farie82:
- rscadd: Added the on_give proc for items. Was needed for the fixes
- bugfix: Giving two handed items like the DIY chainsaw and potted plants now works
correctly
- bugfix: The DIY chainsaw, doomslayer chainsaw and the potted plants now do damage
when given to somebody else and when picked up while the chainsaw was on.
Purpose:
- tweak: Cyberiad's grimy tiles are now actually dirty and cleanable.
- tweak: Delta's grimy tiles are now actually dirty and cleanable.
- bugfix: Ironsand is now visible in the Map Maker.
- bugfix: Away missions updated with the appropriate dirt/grime so that it is now
cleanable.
- bugfix: Fixes stool's unique suicide message.
- bugfix: Fixes rollerbeds no longer going through plastic flaps.
TDSSS:
- bugfix: Removed Skrell discrimination, allows ! character in IDs (agent IDs or
made via ID computer)
variableundefined:
- tweak: Ore now represented by stack that holds up to 50 items. Should reduce lag
with ORM greatly.
@@ -7455,3 +7477,23 @@ DO NOT EDIT THIS FILE BY HAND! AUTOMATICALLY GENERATED BY ss13_genchangelog.py.
- rscadd: You can throw sand into people's eyes! Pocket sand!
- tweak: 'Phazon take 5 bluespace crystal to construct now instead of 1. remove:
Transfer prompt when you click on a stack of the same type with a stack'
2018-10-13:
Birdtalon:
- bugfix: Chem master now will show its de-powered state properly.
DarkPyrolord:
- tweak: Changed attack log level for reagent forcefeeding from FEW to MOST
FlimFlamm:
- tweak: Tweaked formatting of Newscaster stories
- bugfix: Fixes images displaying improperly on Newscaster stories
Ty-Omaha:
- tweak: Boxing logs moved to the ALL preference
alex-gh:
- bugfix: Species damage modifiers now only affect damage, not healing.
- tweak: 'Races that took more damage from certain damage types no longer heal from
that damage type faster. For example: Drask no longer heal from burn at double
rate; Grey, Vox no longer heal from brute at increased rate (Note: IPC healing
with welders/wires is not affected).'
- tweak: Kidan no longer heal from brute at a reduced rate.
uc_guy:
- bugfix: You can no longer get an infection and die during abductor surgery.
- bugfix: Voice analyzers no longer activate on noise.
@@ -1,4 +0,0 @@
author: "DesolateG"
delete-after: True
changes:
- tweak: "Refactors global var lists to use the global subsystem."
@@ -1,4 +0,0 @@
author: "TDSSS"
delete-after: True
changes:
- bugfix: "Removed Skrell discrimination, allows ! character in IDs (agent IDs or made via ID computer)"
@@ -1,5 +0,0 @@
author: "Purpose"
delete-after: True
changes:
- bugfix: "Fixes stool's unique suicide message."
- bugfix: "Fixes rollerbeds no longer going through plastic flaps."
@@ -1,6 +0,0 @@
author: "Farie82"
delete-after: True
changes:
- rscadd: "Added the on_give proc for items. Was needed for the fixes"
- bugfix: "Giving two handed items like the DIY chainsaw and potted plants now works correctly"
- bugfix: "The DIY chainsaw, doomslayer chainsaw and the potted plants now do damage when given to somebody else and when picked up while the chainsaw was on."
@@ -1,4 +0,0 @@
author: "Purpose"
delete-after: True
changes:
- tweak: "Cyberiad's grimy tiles are now actually dirty and cleanable."
@@ -1,4 +0,0 @@
author: "Purpose"
delete-after: True
changes:
- tweak: "Delta's grimy tiles are now actually dirty and cleanable."
@@ -1,5 +0,0 @@
author: "Purpose"
delete-after: True
changes:
- bugfix: "Ironsand is now visible in the Map Maker."
- bugfix: "Away missions updated with the appropriate dirt/grime so that it is now cleanable."
+10 -6
View File
@@ -139,11 +139,15 @@ Property of Nanotrasen</font><br>
{{else}}
{{for data.messages}}
<div class='statusDisplay'>
<b>{{:value.title}}</b><br>
{{:value.body}}<br>
<p style='text-align: center;'>
<font size="5"><b>{{:value.title}}</b></font><br>
</p>
{{if value.img}}
<img src='data:image/png;base64,{{:value.img}}' width=180><br>
{{/if}}
<img src='tmp_photo{{:value.message_number}}.png' style='display: block; margin-left: auto; margin-right: auto;' width=350><br>
{{/if}}
<p style='text-align: justify;'>
{{:value.body}}<br>
</p>
<i><font size=1>[{{:value.message_type}} by <span class='good'>{{:value.author}}</span>]</font></i><br>
<i><font size=1>Message view count: {{:value.view_count}}</font></i>
</div>
@@ -296,10 +300,10 @@ Property of Nanotrasen</font><br>
<div class='itemContent'>{{:data.description}}</div>
</div>
<div class='item'>
<div class='itemLabel'>Photo:</div>
<div class='itemLabel'>Photo:</div><br>
<div class='itemContent'>
{{if data.photo}}
<img src='data:image/png;base64,{{:data.photo}}' width=180>
<img src='tmp_photow.png' width=350><br>
{{else}}
None
{{/if}}