mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-30 15:37:36 +01:00
Merge remote-tracking branch 'upstream/master' into third_times_the_charm_questionmark
Conflicts: code/game/objects/items.dm
This commit is contained in:
@@ -96,10 +96,13 @@
|
||||
if(ishuman(M)) // Would've done this via species instead of type, but the basic mob doesn't have a species, go figure.
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(H.species.flags & NO_DNA_RAD)
|
||||
return
|
||||
|
||||
if (!usr.IsAdvancedToolUser())
|
||||
return
|
||||
return 0
|
||||
|
||||
if (!user.IsAdvancedToolUser())
|
||||
return 0
|
||||
|
||||
if(inuse)
|
||||
return 0
|
||||
|
||||
M.attack_log += text("\[[time_stamp()]\] <font color='orange'>Has been injected with [name] by [user.name] ([user.ckey])</font>")
|
||||
user.attack_log += text("\[[time_stamp()]\] <font color='red'>Used the [name] to inject [M.name] ([M.ckey])</font>")
|
||||
@@ -110,91 +113,37 @@
|
||||
else
|
||||
M.LAssailant = user
|
||||
|
||||
if (user)
|
||||
if (istype(M, /mob/living/carbon/human))
|
||||
if(!inuse)
|
||||
var/obj/effect/equip_e/human/O = new /obj/effect/equip_e/human( )
|
||||
O.source = user
|
||||
O.target = M
|
||||
O.item = src
|
||||
O.s_loc = user.loc
|
||||
O.t_loc = M.loc
|
||||
O.place = "dnainjector"
|
||||
src.inuse = 1
|
||||
spawn(50) // Not the best fix. There should be an failure proc, for /effect/equip_e/, which is called when the first initital checks fail
|
||||
inuse = 0
|
||||
M.requests += O
|
||||
if (buf.types & DNA2_BUF_SE)
|
||||
if(block)// Isolated injector
|
||||
//testing("Isolated block [block] injector with contents: [GetValue()]")
|
||||
if (GetState() && block == MONKEYBLOCK && istype(M, /mob/living/carbon/human) )
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
else
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||
else
|
||||
// testing("DNA injector with contents: [english_list(buf.dna.SE)]")
|
||||
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human) )
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||
else
|
||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
else
|
||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
if(buf.types & DNA2_BUF_SE)
|
||||
|
||||
if(block)
|
||||
if(GetState() && block == MONKEYBLOCK && ishuman(M))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
else
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||
|
||||
spawn( 0 )
|
||||
O.process()
|
||||
return
|
||||
else
|
||||
if(!inuse)
|
||||
if(GetState(MONKEYBLOCK) && ishuman(M))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
else
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red [] has been injected with [] by [].", M, src, user), 1)
|
||||
//Foreach goto(192)
|
||||
if (!(istype(M, /mob/living/carbon/human)))
|
||||
user << "\red Apparently it didn't work."
|
||||
return
|
||||
else
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
|
||||
if (buf.types & DNA2_BUF_SE)
|
||||
if(block)// Isolated injector
|
||||
// testing("Isolated block [block] injector with contents: [english_list(GetValue())]")
|
||||
if (GetState() && block == MONKEYBLOCK && istype(M, /mob/living/carbon/human) )
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name] (MONKEY)")
|
||||
log_game("[key_name_admin(user)] injected [key_name_admin(M)] with the Isolated [name] \red(MONKEY)")
|
||||
else
|
||||
log_attack("[key_name(user)] injected [key_name(M)] with the Isolated [name]")
|
||||
else
|
||||
// testing("DNA injector with contents: [english_list(buf.dna.SE)]")
|
||||
if (GetState(MONKEYBLOCK) && istype(M, /mob/living/carbon/human))
|
||||
message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name] \red(MONKEY)")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name] (MONKEY)")
|
||||
else
|
||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
else
|
||||
// message_admins("[key_name_admin(user)] injected [key_name_admin(M)] with the [name]")
|
||||
log_game("[key_name(user)] injected [key_name(M)] with the [name]")
|
||||
inuse = 1
|
||||
inject(M, user)//Now we actually do the heavy lifting.
|
||||
spawn(50)
|
||||
inuse = 0
|
||||
/*
|
||||
A user injecting themselves could mean their own transformation and deletion of mob.
|
||||
I don't have the time to figure out how this code works so this will do for now.
|
||||
I did rearrange things a bit.
|
||||
*/
|
||||
if(user)//If the user still exists. Their mob may not.
|
||||
if(M)//Runtime fix: If the mob doesn't exist, mob.name doesnt work. - Nodrak
|
||||
user.show_message(text("\red You inject [M.name]"))
|
||||
else
|
||||
user.show_message(text("\red You finish the injection."))
|
||||
return
|
||||
user.visible_message("<span class='danger'>\The [user] starts injecting \the [M] with \the [src]!</span>", "<span class='notice'>You start injecting \the [M] with \the [src].</span>")
|
||||
if(do_after(user, 50, target = M))
|
||||
inject(M, user)//Now we actually do the heavy lifting
|
||||
user.visible_message("<span class='danger'>\The [user] injects \the [M] with \the [src]!</span>", "<span class='danger'>You inject \the [M] with \the [src].</span>")
|
||||
|
||||
if(user)//If the user still exists. Their mob may not.
|
||||
if(M)//Runtime fix: If the mob doesn't exist, mob.name doesnt work. - Nodrak
|
||||
user.show_message("<span class='alert'>You inject [M.name]</span>")
|
||||
else
|
||||
user.show_message("<span class='alert'>You finish the injection.</span>")
|
||||
|
||||
|
||||
/obj/item/weapon/dnainjector/hulkmut
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
var/implanted = null
|
||||
var/mob/living/imp_in = null
|
||||
var/obj/item/organ/external/part = null
|
||||
_color = "b"
|
||||
item_color = "b"
|
||||
var/allow_reagents = 0
|
||||
var/malfunction = 0
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
update()
|
||||
if (src.imp)
|
||||
src.icon_state = text("implantcase-[]", src.imp._color)
|
||||
src.icon_state = text("implantcase-[]", src.imp.item_color)
|
||||
src.origin_tech = src.imp.origin_tech
|
||||
else
|
||||
src.icon_state = "implantcase-0"
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
/obj/item/weapon/implant/freedom
|
||||
name = "freedom"
|
||||
desc = "Use this to escape from those evil Red Shirts."
|
||||
_color = "r"
|
||||
item_color = "r"
|
||||
var/activation_emote = "chuckle"
|
||||
origin_tech = "materials=2;magnets=3;biotech=3;syndicate=4"
|
||||
var/uses = 4
|
||||
|
||||
@@ -25,10 +25,10 @@
|
||||
hitsound = 'sound/weapons/blade1.ogg'
|
||||
if(attack_verb_on.len)
|
||||
attack_verb = attack_verb_on
|
||||
if(!_color)
|
||||
if(!item_color)
|
||||
icon_state = icon_state_on
|
||||
else
|
||||
icon_state = "sword[_color]"
|
||||
icon_state = "sword[item_color]"
|
||||
w_class = w_class_on
|
||||
playsound(user, 'sound/weapons/saberon.ogg', 35, 1) //changed it from 50% volume to 35% because deafness
|
||||
user << "<span class='notice'>[src] is now active.</span>"
|
||||
@@ -86,8 +86,8 @@
|
||||
var/blade_color
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/New()
|
||||
if(_color == null)
|
||||
_color = pick("red", "blue", "green", "purple")
|
||||
if(item_color == null)
|
||||
item_color = pick("red", "blue", "green", "purple")
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/IsShield()
|
||||
if(active)
|
||||
@@ -120,12 +120,12 @@
|
||||
icon_state = "esaw_0"
|
||||
icon_state_on = "esaw_1"
|
||||
hitcost = 75 //Costs more than a standard cyborg esword
|
||||
_color = null
|
||||
item_color = null
|
||||
w_class = 3
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg/saw/New()
|
||||
..()
|
||||
_color = null
|
||||
item_color = null
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg/saw/IsShield()
|
||||
return 0
|
||||
@@ -133,16 +133,16 @@
|
||||
/obj/item/weapon/melee/energy/sword/saber
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/blue
|
||||
_color = "blue"
|
||||
item_color = "blue"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/purple
|
||||
_color = "purple"
|
||||
item_color = "purple"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/green
|
||||
_color = "green"
|
||||
item_color = "green"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/red
|
||||
_color = "red"
|
||||
item_color = "red"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/attackby(obj/item/weapon/W, mob/living/user, params)
|
||||
..()
|
||||
@@ -156,7 +156,7 @@
|
||||
var/obj/item/weapon/twohanded/dualsaber/newSaber = new /obj/item/weapon/twohanded/dualsaber(user.loc)
|
||||
if(src.hacked) // That's right, we'll only check the "original" esword.
|
||||
newSaber.hacked = 1
|
||||
newSaber._color = "rainbow"
|
||||
newSaber.item_color = "rainbow"
|
||||
user.unEquip(W)
|
||||
user.unEquip(src)
|
||||
qdel(W)
|
||||
@@ -165,7 +165,7 @@
|
||||
else if(istype(W, /obj/item/device/multitool))
|
||||
if(hacked == 0)
|
||||
hacked = 1
|
||||
_color = "rainbow"
|
||||
item_color = "rainbow"
|
||||
user << "<span class='warning'>RNBW_ENGAGE</span>"
|
||||
|
||||
if(active)
|
||||
|
||||
Reference in New Issue
Block a user