Merge remote-tracking branch 'refs/remotes/origin/master' into OnceYouLeaveYouCannotComeBack

This commit is contained in:
Krausus
2016-07-29 14:51:05 -04:00
122 changed files with 2251 additions and 1430 deletions
+1 -1
View File
@@ -110,7 +110,7 @@
if(!I) //If there's nothing to drop, the drop is automatically succesfull. If(unEquip) should generally be used to check for NODROP.
return 1
if((I.flags & NODROP) && !force)
if(!canUnEquip(I, force))
return 0
if(I == r_hand)
+2 -1
View File
@@ -569,6 +569,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump,
return 1
return
/mob/living/carbon/unEquip(obj/item/I) //THIS PROC DID NOT CALL ..()
. = ..() //Sets the default return value to what the parent returns.
if(!. || !I) //We don't want to set anything to null if the parent returned 0.
@@ -1041,4 +1042,4 @@ so that different stomachs can handle things in different ways VB*/
/mob/living/carbon/proc/update_internals_hud_icon(internal_state = 0)
if(hud_used && hud_used.internals)
hud_used.internals.icon_state = "internal[internal_state]"
hud_used.internals.icon_state = "internal[internal_state]"
@@ -107,15 +107,19 @@
if(slot_tie)
return 1
// The actual dropping happens at the mob level - checks to prevent drops should
// come here
/mob/living/carbon/human/canUnEquip(obj/item/I, force)
. = ..()
var/obj/item/organ/O = I
if(istype(O) && O.owner == src)
. = 0 // keep a good grip on your heart
/mob/living/carbon/human/unEquip(obj/item/I)
. = ..() //See mob.dm for an explanation on this and some rage about people copypasting instead of calling ..() like they should.
if(!. || !I)
return
var/obj/item/organ/internal/O = I //Organs shouldn't be removed unless you call droplimb.
if(istype(O) && O.owner == src)
return
if(I == wear_suit)
if(s_store)
unEquip(s_store, 1) //It makes no sense for your suit storage to stay on you if you drop your suit.
+1 -1
View File
@@ -8,7 +8,7 @@
Returns
standard 0 if fail
*/
/mob/living/proc/apply_damage(var/damage = 0,var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0, var/used_weapon = null, var/sharp = 0, var/edge = 0)
/mob/living/proc/apply_damage(var/damage = 0, var/damagetype = BRUTE, var/def_zone = null, var/blocked = 0, var/sharp = 0, var/edge = 0, var/used_weapon = null)
blocked = (100-blocked)/100
if(!damage || (blocked <= 0)) return 0
switch(damagetype)