mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 15:47:15 +01:00
Merge branch 'master' of https://github.com/tgstation/-tg-station into mapmergersoannoying
Conflicts: _maps/map_files/tgstation.2.1.3.dmm
This commit is contained in:
@@ -6,13 +6,6 @@
|
||||
layer = 2.1
|
||||
anchored = 1
|
||||
|
||||
|
||||
/obj/effect/decal/cleanable/crayon/examine()
|
||||
set src in view(2)
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
/obj/effect/decal/cleanable/crayon/New(location,main = "#FFFFFF", var/type = "rune")
|
||||
..()
|
||||
loc = location
|
||||
|
||||
@@ -76,6 +76,7 @@
|
||||
desc = "They seem to pulse slightly with an inner life"
|
||||
icon_state = "eggs"
|
||||
var/amount_grown = 0
|
||||
var/player_spiders = 0
|
||||
|
||||
/obj/effect/spider/eggcluster/New()
|
||||
pixel_x = rand(3,-3)
|
||||
@@ -87,7 +88,9 @@
|
||||
if(amount_grown >= 100)
|
||||
var/num = rand(3,12)
|
||||
for(var/i=0, i<num, i++)
|
||||
new /obj/effect/spider/spiderling(src.loc)
|
||||
var/obj/effect/spider/spiderling/S = new /obj/effect/spider/spiderling(src.loc)
|
||||
if(player_spiders)
|
||||
S.player_spiders = 1
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/spiderling
|
||||
@@ -101,6 +104,7 @@
|
||||
var/grow_as = null
|
||||
var/obj/machinery/atmospherics/unary/vent_pump/entry_vent
|
||||
var/travelling_in_vent = 0
|
||||
var/player_spiders = 0
|
||||
|
||||
/obj/effect/spider/spiderling/New()
|
||||
pixel_x = rand(6,-6)
|
||||
@@ -186,7 +190,14 @@
|
||||
if(amount_grown >= 100)
|
||||
if(!grow_as)
|
||||
grow_as = pick(typesof(/mob/living/simple_animal/hostile/giant_spider))
|
||||
new grow_as(src.loc)
|
||||
var/mob/living/simple_animal/hostile/giant_spider/S = new grow_as(src.loc)
|
||||
if(player_spiders)
|
||||
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET)
|
||||
var/client/C = null
|
||||
|
||||
if(candidates.len)
|
||||
C = pick(candidates)
|
||||
S.key = C.key
|
||||
qdel(src)
|
||||
|
||||
/obj/effect/spider/cocoon
|
||||
|
||||
@@ -86,9 +86,8 @@
|
||||
|
||||
src.loc = T
|
||||
|
||||
/obj/item/examine()
|
||||
set src in view()
|
||||
|
||||
/obj/item/examine(mob/user) //This might be spammy. Remove?
|
||||
..()
|
||||
var/size
|
||||
switch(src.w_class)
|
||||
if(1.0)
|
||||
@@ -106,25 +105,13 @@
|
||||
else
|
||||
//if ((CLUMSY in usr.mutations) && prob(50)) t = "funny-looking"
|
||||
|
||||
//This reformat names to get a/an properly working on item descriptions when they are bloody
|
||||
var/f_name = "\a [src]"
|
||||
if(src.blood_DNA)
|
||||
f_name = "a bloody [name]"
|
||||
|
||||
var/determiner
|
||||
var/pronoun
|
||||
if(src.gender == PLURAL)
|
||||
determiner = "These are"
|
||||
pronoun = "They are"
|
||||
else
|
||||
determiner = "This is"
|
||||
pronoun = "It is"
|
||||
|
||||
usr << "\icon[src][determiner] [f_name]. [pronoun] a [size] item." //e.g. These are some gloves. They are a small item. or This is a toolbox. It is a bulky item.
|
||||
|
||||
if(src.desc)
|
||||
usr << src.desc
|
||||
return
|
||||
user << "[pronoun] a [size] item." //e.g. They are a small item. or It is a bulky item.
|
||||
|
||||
/obj/item/attack_hand(mob/user as mob)
|
||||
if (!user) return
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
/obj/item/device/aicard
|
||||
name = "inteliCard"
|
||||
desc = "A storage device for AIs. Patent pending."
|
||||
icon = 'icons/obj/aicards.dmi'
|
||||
icon_state = "aicard" // aicard-full
|
||||
item_state = "electronic"
|
||||
@@ -56,7 +57,7 @@
|
||||
dat += "<b>AI nonfunctional</b>"
|
||||
else
|
||||
if (!src.flush)
|
||||
dat += {"<A href='byond://?src=\ref[src];choice=Wipe'>Wipe AI</A>"}
|
||||
dat += {"<A href='byond://?src=\ref[src];choice=Wipe'>Wipe AI</A>"}
|
||||
else
|
||||
dat += "<b>Wipe in progress</b>"
|
||||
dat += "<br>"
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
icon_state = "flash"
|
||||
item_state = "flashbang" //looks exactly like a flash (and nothing like a flashbang)
|
||||
throwforce = 0
|
||||
w_class = 1.0
|
||||
w_class = 1
|
||||
throw_speed = 3
|
||||
throw_range = 7
|
||||
flags = CONDUCT
|
||||
@@ -13,206 +13,147 @@
|
||||
var/times_used = 0 //Number of times it's been used.
|
||||
var/broken = 0 //Is the flash burnt out?
|
||||
var/last_used = 0 //last world.time it was used.
|
||||
var/burnt = "flashburnt"
|
||||
var/flashanim = "flash2"
|
||||
|
||||
|
||||
/obj/item/device/flash/proc/clown_check(mob/user)
|
||||
if(user && (CLUMSY in user.mutations) && prob(50))
|
||||
user << "<span class='danger'>[src] slips out of your hand.</span>"
|
||||
user.drop_item()
|
||||
flash_carbon(user, user, 15, 0)
|
||||
user.visible_message("<span class='disarm'>[user] blinds [user] with the flash!</span>")
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/obj/item/device/flash/proc/flash_recharge()
|
||||
//capacitor recharges over time
|
||||
for(var/i=0, i<3, i++)
|
||||
if(last_used+600 > world.time)
|
||||
break
|
||||
last_used += 600
|
||||
times_used -= 2
|
||||
last_used = world.time
|
||||
times_used = max(0,round(times_used)) //sanity
|
||||
|
||||
/obj/item/device/flash/proc/burn_out(mob/user = null) //Made so you can override it if you want to have an invincible flash from R&D or something.
|
||||
/obj/item/device/flash/proc/burn_out(var/mob/user) //Made so you can override it if you want to have an invincible flash from R&D or something.
|
||||
broken = 1
|
||||
icon_state = burnt
|
||||
if(user)
|
||||
user << "<span class='warning'>The bulb has burnt out!</span>"
|
||||
icon_state = "[initial(icon_state)]burnt"
|
||||
user.visible_message("<span class='notice'>The [src.name] burns out!</span>")
|
||||
|
||||
|
||||
/obj/item/device/flash/proc/flash_recharge(var/mob/user)
|
||||
if(prob(times_used * 2)) //if you use it 5 times in a minute it has a 10% chance to break!
|
||||
burn_out(user)
|
||||
return 0
|
||||
|
||||
var/deciseconds_passed = world.time - last_used
|
||||
for(var/seconds = deciseconds_passed/10, seconds>=10, seconds-=10) //get 1 charge every 10 seconds
|
||||
times_used--
|
||||
|
||||
last_used = world.time
|
||||
times_used = max(0, times_used) //sanity
|
||||
|
||||
|
||||
/obj/item/device/flash/proc/try_use_flash(var/mob/user)
|
||||
flash_recharge(user)
|
||||
|
||||
if(broken)
|
||||
return 0
|
||||
|
||||
playsound(src.loc, 'sound/weapons/flash.ogg', 100, 1)
|
||||
flick("[initial(icon_state)]2", src)
|
||||
times_used++
|
||||
|
||||
if(user && !clown_check(user))
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
/obj/item/device/flash/proc/flash_carbon(var/mob/living/carbon/M, var/mob/user = null, var/power = 5, convert = 1)
|
||||
add_logs(user, M, "flashed", object="[src.name]")
|
||||
var/safety = M:eyecheck()
|
||||
if(safety <= 0)
|
||||
M.confused += power
|
||||
flick("e_flash", M.flash)
|
||||
if(user && convert)
|
||||
terrible_conversion_proc(M, user)
|
||||
|
||||
|
||||
/obj/item/device/flash/attack(mob/living/M, mob/user)
|
||||
if(!user || !M) return //sanity
|
||||
|
||||
add_logs(user, M, "flashed", object="[src.name]")
|
||||
|
||||
if(!clown_check(user)) return
|
||||
if(broken)
|
||||
user << "<span class='warning'>[src] is broken.</span>"
|
||||
return
|
||||
|
||||
flash_recharge()
|
||||
|
||||
//spamming the flash before it's fully charged (60seconds) increases the chance of it breaking
|
||||
//It will never break on the first use.
|
||||
switch(times_used)
|
||||
if(0 to 5)
|
||||
last_used = world.time
|
||||
if(prob(times_used)) //if you use it 5 times in a minute it has a 10% chance to break!
|
||||
burn_out(user)
|
||||
return
|
||||
times_used++
|
||||
else //can only use it 5 times a minute
|
||||
user << "<span class='warning'>*click* *click*</span>"
|
||||
return
|
||||
playsound(src.loc, 'sound/weapons/flash.ogg', 100, 1)
|
||||
var/flashfail = 0
|
||||
if(!try_use_flash(user))
|
||||
return 0
|
||||
|
||||
if(iscarbon(M))
|
||||
var/safety = M:eyecheck()
|
||||
if(safety <= 0)
|
||||
M.Weaken(5)
|
||||
flick("e_flash", M.flash)
|
||||
|
||||
if(ishuman(M) && ishuman(user) && M.stat != DEAD)
|
||||
if(user.mind && ((user.mind in ticker.mode.head_revolutionaries) || (user.mind in ticker.mode.A_bosses) || (user.mind in ticker.mode.B_bosses)))
|
||||
if(M.client)
|
||||
if(M.stat == CONSCIOUS)
|
||||
M.mind_initialize() //give them a mind datum if they don't have one.
|
||||
var/resisted
|
||||
if(!isloyal(M))
|
||||
if(user.mind in ticker.mode.head_revolutionaries)
|
||||
if(!ticker.mode.add_revolutionary(M.mind))
|
||||
resisted = 1
|
||||
if(user.mind in ticker.mode.A_bosses)
|
||||
if(!ticker.mode.add_gangster(M.mind,"A"))
|
||||
resisted = 1
|
||||
if(user.mind in ticker.mode.B_bosses)
|
||||
if(!ticker.mode.add_gangster(M.mind,"B"))
|
||||
resisted = 1
|
||||
else
|
||||
resisted = 1
|
||||
|
||||
if(resisted)
|
||||
user << "<span class='warning'>This mind seems resistant to the flash!</span>"
|
||||
else
|
||||
user << "<span class='warning'>They must be conscious before you can convert them!</span>"
|
||||
else
|
||||
user << "<span class='warning'>This mind is so vacant that it is not susceptible to influence!</span>"
|
||||
else
|
||||
flashfail = 1
|
||||
flash_carbon(M, user, 5, 1)
|
||||
user.visible_message("<span class='disarm'>[user] blinds [M] with the flash!</span>")
|
||||
return 1
|
||||
|
||||
else if(issilicon(M))
|
||||
M.Weaken(rand(5,10))
|
||||
else
|
||||
flashfail = 1
|
||||
|
||||
if(isrobot(user))
|
||||
spawn(0)
|
||||
var/atom/movable/overlay/animation = new(user.loc)
|
||||
animation.layer = user.layer + 1
|
||||
animation.icon_state = "blank"
|
||||
animation.icon = 'icons/mob/mob.dmi'
|
||||
animation.master = user
|
||||
flick("blspell", animation)
|
||||
sleep(5)
|
||||
qdel(animation)
|
||||
|
||||
if(!flashfail)
|
||||
flick(flashanim, src)
|
||||
if(!issilicon(M))
|
||||
|
||||
user.visible_message("<span class='disarm'>[user] blinds [M] with the flash!</span>")
|
||||
else
|
||||
|
||||
user.visible_message("<span class='notice'>[user] overloads [M]'s sensors with the flash!</span>")
|
||||
else
|
||||
|
||||
user.visible_message("<span class='notice'>[user] fails to blind [M] with the flash!</span>")
|
||||
|
||||
add_logs(user, M, "flashed", object="[src.name]")
|
||||
user.visible_message("<span class='disarm'>[user] overloads [M]'s sensors with the flash!</span>")
|
||||
return 1
|
||||
|
||||
user.visible_message("<span class='notice'>[user] fails to blind [M] with the flash!</span>")
|
||||
|
||||
|
||||
/obj/item/device/flash/attack_self(mob/living/carbon/user, flag = 0, emp = 0)
|
||||
if(!user || !clown_check(user)) return
|
||||
if(broken)
|
||||
user.show_message("<span class='warning'>[src] is broken!</span>", 2)
|
||||
return
|
||||
|
||||
flash_recharge()
|
||||
|
||||
//spamming the flash before it's fully charged (60seconds) increases the chance of it breaking
|
||||
//It will never break on the first use.
|
||||
switch(times_used)
|
||||
if(0 to 5)
|
||||
if(prob(2*times_used)) //if you use it 5 times in a minute it has a 10% chance to break!
|
||||
burn_out(user)
|
||||
return
|
||||
times_used++
|
||||
else //can only use it 5 times a minute
|
||||
user.show_message("<span class='warning'>*click* *click*</span>", 2)
|
||||
return
|
||||
playsound(src.loc, 'sound/weapons/flash.ogg', 100, 1)
|
||||
flick("flash2", src)
|
||||
if(user && isrobot(user))
|
||||
spawn(0)
|
||||
var/atom/movable/overlay/animation = new(user.loc)
|
||||
animation.layer = user.layer + 1
|
||||
animation.icon_state = "blank"
|
||||
animation.icon = 'icons/mob/mob.dmi'
|
||||
animation.master = user
|
||||
flick("blspell", animation)
|
||||
sleep(5)
|
||||
qdel(animation)
|
||||
|
||||
if(!try_use_flash(user))
|
||||
return 0
|
||||
for(var/mob/living/carbon/M in oviewers(3, null))
|
||||
var/safety = M:eyecheck()
|
||||
if(!safety)
|
||||
if(!M.blinded)
|
||||
flick("flash", M.flash)
|
||||
flash_carbon(M, user, 3, 0)
|
||||
|
||||
return
|
||||
|
||||
/obj/item/device/flash/emp_act(severity)
|
||||
if(broken) return
|
||||
flash_recharge()
|
||||
switch(times_used)
|
||||
if(0 to 5)
|
||||
if(prob(2*times_used))
|
||||
burn_out()
|
||||
return
|
||||
times_used++
|
||||
if(istype(loc, /mob/living/carbon))
|
||||
var/mob/living/carbon/M = loc
|
||||
var/safety = M.eyecheck()
|
||||
if(safety <= 0)
|
||||
M.Weaken(5)
|
||||
flick("e_flash", M.flash)
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message("<span class='disarm'>[M] is blinded by the flash!</span>")
|
||||
if(!try_use_flash())
|
||||
return 0
|
||||
for(var/mob/living/carbon/M in viewers(3, null))
|
||||
flash_carbon(M, null, 10, 0)
|
||||
burn_out()
|
||||
..()
|
||||
|
||||
/obj/item/device/flash/synthetic
|
||||
name = "synthetic flash"
|
||||
desc = "When a problem arises, SCIENCE is the solution."
|
||||
icon_state = "sflash"
|
||||
origin_tech = "magnets=2;combat=1"
|
||||
var/construction_cost = list("metal"=750, "glass"=750)
|
||||
var/construction_time=100
|
||||
|
||||
/obj/item/device/flash/synthetic/attack(mob/living/M, mob/user)
|
||||
..()
|
||||
if(!broken)
|
||||
burn_out(user)
|
||||
/obj/item/device/flash/proc/terrible_conversion_proc(var/mob/M, var/mob/user)
|
||||
if(ishuman(M) && ishuman(user) && M.stat != DEAD)
|
||||
if(user.mind && ((user.mind in ticker.mode.head_revolutionaries) || (user.mind in ticker.mode.A_bosses) || (user.mind in ticker.mode.B_bosses)))
|
||||
if(M.client)
|
||||
if(M.stat == CONSCIOUS)
|
||||
M.mind_initialize() //give them a mind datum if they don't have one.
|
||||
var/resisted
|
||||
if(!isloyal(M))
|
||||
if(user.mind in ticker.mode.head_revolutionaries)
|
||||
if(!ticker.mode.add_revolutionary(M.mind))
|
||||
resisted = 1
|
||||
if(user.mind in ticker.mode.A_bosses)
|
||||
if(!ticker.mode.add_gangster(M.mind,"A"))
|
||||
resisted = 1
|
||||
if(user.mind in ticker.mode.B_bosses)
|
||||
if(!ticker.mode.add_gangster(M.mind,"B"))
|
||||
resisted = 1
|
||||
else
|
||||
resisted = 1
|
||||
|
||||
/obj/item/device/flash/synthetic/attack_self(mob/living/carbon/user, flag = 0, emp = 0)
|
||||
if(resisted)
|
||||
user << "<span class='warning'>This mind seems resistant to the flash!</span>"
|
||||
else
|
||||
user << "<span class='warning'>They must be conscious before you can convert them!</span>"
|
||||
else
|
||||
user << "<span class='warning'>This mind is so vacant that it is not susceptible to influence!</span>"
|
||||
|
||||
|
||||
/obj/item/device/flash/cyborg
|
||||
origin_tech = null
|
||||
|
||||
/obj/item/device/flash/cyborg/attack(mob/living/M, mob/user)
|
||||
..()
|
||||
if(!broken)
|
||||
burn_out(user)
|
||||
cyborg_flash_animation(user)
|
||||
|
||||
/obj/item/device/flash/cyborg/attack_self(mob/user)
|
||||
..()
|
||||
cyborg_flash_animation(user)
|
||||
|
||||
/obj/item/device/flash/cyborg/proc/cyborg_flash_animation(var/mob/living/user)
|
||||
var/atom/movable/overlay/animation = new(user.loc)
|
||||
animation.layer = user.layer + 1
|
||||
animation.icon_state = "blank"
|
||||
animation.icon = 'icons/mob/mob.dmi'
|
||||
animation.master = user
|
||||
flick("blspell", animation)
|
||||
sleep(5)
|
||||
qdel(animation)
|
||||
|
||||
|
||||
/obj/item/device/flash/memorizer
|
||||
name = "memorizer"
|
||||
desc = "If you see this, you're not likely to remember it any time soon."
|
||||
icon_state = "memorizer"
|
||||
item_state = "nullrod"
|
||||
burnt = "memorizerburnt"
|
||||
flashanim = "memorizer2"
|
||||
item_state = "nullrod"
|
||||
@@ -249,10 +249,6 @@
|
||||
emp_cur_charges = min(emp_cur_charges+1, emp_max_charges)
|
||||
return 1
|
||||
|
||||
/obj/item/device/flashlight/emp/examine()
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/device/flashlight/emp/attack(mob/living/M as mob, mob/living/user as mob)
|
||||
if(on && user.zone_sel.selecting == "eyes") // call original attack proc only if aiming at the eyes
|
||||
..()
|
||||
|
||||
@@ -66,10 +66,9 @@
|
||||
failmsg = "The [name]'s refill light blinks red."
|
||||
..()
|
||||
|
||||
/obj/item/device/lightreplacer/examine()
|
||||
set src in view(2)
|
||||
/obj/item/device/lightreplacer/examine(mob/user)
|
||||
..()
|
||||
usr << "It has [uses] lights remaining."
|
||||
user << "It has [uses] light\s remaining."
|
||||
|
||||
/obj/item/device/lightreplacer/attackby(obj/item/W, mob/user)
|
||||
if(istype(W, /obj/item/weapon/card/emag) && emagged == 0)
|
||||
|
||||
@@ -443,16 +443,12 @@
|
||||
return get_hearers_in_view(canhear_range, src)
|
||||
|
||||
|
||||
/obj/item/device/radio/examine()
|
||||
set src in view()
|
||||
|
||||
/obj/item/device/radio/examine(mob/user)
|
||||
..()
|
||||
if ((in_range(src, usr) || loc == usr))
|
||||
if (b_stat)
|
||||
usr.show_message("<span class='notice'>\the [src] can be attached and modified!</span>")
|
||||
else
|
||||
usr.show_message("<span class='notice'>\the [src] can not be modified or attached!</span>")
|
||||
return
|
||||
if (b_stat)
|
||||
user << "<span class='notice'>[name] can be attached and modified.</span>"
|
||||
else
|
||||
user << "<span class='notice'>[name] can not be modified or attached.</span>"
|
||||
|
||||
/obj/item/device/radio/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
..()
|
||||
|
||||
@@ -26,10 +26,9 @@
|
||||
update_icon()
|
||||
|
||||
|
||||
/obj/item/device/taperecorder/examine()
|
||||
set src in view(1)
|
||||
/obj/item/device/taperecorder/examine(mob/user)
|
||||
..()
|
||||
usr << "The wire panel is [open_panel ? "opened" : "closed"]."
|
||||
user << "The wire panel is [open_panel ? "opened" : "closed"]."
|
||||
|
||||
|
||||
/obj/item/device/taperecorder/attackby(obj/item/I, mob/user)
|
||||
|
||||
@@ -32,25 +32,23 @@
|
||||
src.loc = null
|
||||
..()
|
||||
|
||||
/obj/item/stack/examine()
|
||||
set src in view(1)
|
||||
/obj/item/stack/examine(mob/user)
|
||||
..()
|
||||
if (is_cyborg)
|
||||
if(src.singular_name)
|
||||
usr << "There is enough energy for [src.get_amount()] [src.singular_name]\s."
|
||||
user << "There is enough energy for [src.get_amount()] [src.singular_name]\s."
|
||||
else
|
||||
usr << "There is enough energy for [src.get_amount()]."
|
||||
user << "There is enough energy for [src.get_amount()]."
|
||||
return
|
||||
if(src.singular_name)
|
||||
if(src.get_amount()>1)
|
||||
usr << "There are [src.get_amount()] [src.singular_name]\s in the stack."
|
||||
user << "There are [src.get_amount()] [src.singular_name]\s in the stack."
|
||||
else
|
||||
usr << "There is [src.get_amount()] [src.singular_name] in the stack."
|
||||
user << "There is [src.get_amount()] [src.singular_name] in the stack."
|
||||
else if(src.get_amount()>1)
|
||||
usr << "There are [src.get_amount()] in the stack."
|
||||
user << "There are [src.get_amount()] in the stack."
|
||||
else
|
||||
usr << "There is [src.get_amount()] in the stack."
|
||||
return
|
||||
user << "There is [src.get_amount()] in the stack."
|
||||
|
||||
/obj/item/stack/proc/get_amount()
|
||||
if (is_cyborg)
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
*/
|
||||
/obj/item/toy/gun
|
||||
name = "cap gun"
|
||||
desc = "There are 0 caps left. Looks almost like the real thing! Ages 8 and up. Please recycle in an autolathe when you're out of caps!"
|
||||
desc = "Looks almost like the real thing! Ages 8 and up. Please recycle in an autolathe when you're out of caps."
|
||||
icon = 'icons/obj/gun.dmi'
|
||||
icon_state = "revolver"
|
||||
item_state = "gun"
|
||||
@@ -121,12 +121,9 @@
|
||||
attack_verb = list("struck", "pistol whipped", "hit", "bashed")
|
||||
var/bullets = 7.0
|
||||
|
||||
/obj/item/toy/gun/examine()
|
||||
set src in usr
|
||||
|
||||
src.desc = text("There are [] cap\s left. Looks almost like the real thing! Ages 8 and up.", src.bullets)
|
||||
/obj/item/toy/gun/examine(mob/user)
|
||||
..()
|
||||
return
|
||||
user << "There [bullets == 1 ? "is" : "are"] [bullets] cap\s left."
|
||||
|
||||
/obj/item/toy/gun/attackby(obj/item/toy/ammo/gun/A as obj, mob/user as mob)
|
||||
|
||||
@@ -168,7 +165,7 @@
|
||||
|
||||
/obj/item/toy/ammo/gun
|
||||
name = "ammo-caps"
|
||||
desc = "There are 7 caps left! Make sure to recyle the box in an autolathe when it gets empty."
|
||||
desc = "Make sure to recyle the box in an autolathe when it gets empty."
|
||||
icon = 'icons/obj/ammo.dmi'
|
||||
icon_state = "357-7"
|
||||
w_class = 1.0
|
||||
@@ -178,8 +175,10 @@
|
||||
|
||||
/obj/item/toy/ammo/gun/update_icon()
|
||||
src.icon_state = text("357-[]", src.amount_left)
|
||||
src.desc = text("There are [] cap\s left! Make sure to recycle the box in an autolathe when it gets empty.", src.amount_left)
|
||||
return
|
||||
|
||||
/obj/item/toy/ammo/gun/examine(mob/user)
|
||||
..()
|
||||
user << "There [amount_left == 1 ? "is" : "are"] [amount_left] cap\s left."
|
||||
|
||||
/*
|
||||
* Toy crossbow
|
||||
@@ -195,11 +194,10 @@
|
||||
attack_verb = list("attacked", "struck", "hit")
|
||||
var/bullets = 5
|
||||
|
||||
/obj/item/toy/crossbow/examine()
|
||||
set src in view(2)
|
||||
/obj/item/toy/crossbow/examine(mob/user)
|
||||
..()
|
||||
if (bullets)
|
||||
usr << "<span class='notice'>It is loaded with [bullets] foam darts!</span>"
|
||||
user << "<span class='notice'>It is loaded with [bullets] foam dart\s.</span>"
|
||||
|
||||
/obj/item/toy/crossbow/attackby(obj/item/I as obj, mob/user as mob)
|
||||
if(istype(I, /obj/item/toy/ammo/crossbow))
|
||||
@@ -817,10 +815,9 @@ obj/item/toy/cards/singlecard
|
||||
pixel_x = -5
|
||||
|
||||
|
||||
obj/item/toy/cards/singlecard/examine()
|
||||
set src in usr.contents
|
||||
if(ishuman(usr))
|
||||
var/mob/living/carbon/human/cardUser = usr
|
||||
obj/item/toy/cards/singlecard/examine(mob/user)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/cardUser = user
|
||||
if(cardUser.get_item_by_slot(slot_l_hand) == src || cardUser.get_item_by_slot(slot_r_hand) == src)
|
||||
cardUser.visible_message("<span class='notice'>[cardUser] checks \his card.</span>", "<span class='notice'>The card reads: [src.cardname]</span>")
|
||||
else
|
||||
|
||||
@@ -42,10 +42,10 @@
|
||||
else
|
||||
return 1
|
||||
|
||||
/obj/item/weapon/airlock_painter/examine()
|
||||
/obj/item/weapon/airlock_painter/examine(mob/user)
|
||||
..()
|
||||
if(!ink)
|
||||
usr << "<span class='notice'>It doesn't have a toner cardridge installed.</span>"
|
||||
user << "<span class='notice'>It doesn't have a toner cardridge installed.</span>"
|
||||
return
|
||||
var/ink_level = "high"
|
||||
if(ink.charges < 1)
|
||||
@@ -54,7 +54,8 @@
|
||||
ink_level = "low"
|
||||
else if((ink.charges/ink.max_charges) > 1) //Over 100% (admin var edit)
|
||||
ink_level = "dangerously high"
|
||||
usr << "<span class='notice'>Its ink levels look [ink_level].</span>"
|
||||
user << "<span class='notice'>Its ink levels look [ink_level].</span>"
|
||||
|
||||
|
||||
/obj/item/weapon/airlock_painter/attackby(obj/item/weapon/W, mob/user)
|
||||
..()
|
||||
|
||||
@@ -79,10 +79,10 @@
|
||||
src.add_fingerprint(user)
|
||||
return
|
||||
|
||||
/obj/item/weapon/card/id/examine()
|
||||
/obj/item/weapon/card/id/examine(mob/user)
|
||||
..()
|
||||
if(mining_points)
|
||||
usr << "There's [mining_points] mining equipment redemption points loaded onto this card."
|
||||
user << "There's [mining_points] mining equipment redemption point\s loaded onto this card."
|
||||
|
||||
/obj/item/weapon/card/id/GetAccess()
|
||||
return access
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
var/sprite_name = "fire_extinguisher"
|
||||
|
||||
/obj/item/weapon/extinguisher/mini
|
||||
name = "fire extinguisher"
|
||||
name = "pocket fire extinguisher"
|
||||
desc = "A light and compact fibreglass-framed model fire extinguisher."
|
||||
icon_state = "miniFE0"
|
||||
item_state = "miniFE"
|
||||
@@ -36,12 +36,6 @@
|
||||
create_reagents(max_water)
|
||||
reagents.add_reagent("water", max_water)
|
||||
|
||||
/obj/item/weapon/extinguisher/examine()
|
||||
set src in usr
|
||||
..()
|
||||
usr << "It contains [src.reagents.total_volume] units of water!"
|
||||
return
|
||||
|
||||
/obj/item/weapon/extinguisher/attack_self(mob/user as mob)
|
||||
safety = !safety
|
||||
src.icon_state = "[sprite_name][!safety]"
|
||||
|
||||
@@ -21,8 +21,7 @@
|
||||
name = "[initial(name)] casing" // By adding the " casing" part here we can use initial(name) to get the final name, making it nice to say "large grenade" when it is a large grenade.
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/chem_grenade/examine()
|
||||
set src in usr
|
||||
/obj/item/weapon/grenade/chem_grenade/examine(mob/user)
|
||||
display_timer = (stage == READY && !nadeassembly) //show/hide the timer based on assembly state
|
||||
..()
|
||||
|
||||
|
||||
@@ -97,8 +97,7 @@
|
||||
explosion(src.loc,-1,-1,-1, flame_range = range) // no explosive damage, only a large fireball.
|
||||
qdel(src)
|
||||
|
||||
/obj/item/weapon/grenade/iedcasing/examine()
|
||||
set src in usr
|
||||
/obj/item/weapon/grenade/iedcasing/examine(mob/user)
|
||||
..()
|
||||
if(assembled == 3)
|
||||
usr << "You can't tell when it will explode!"
|
||||
user << "You can't tell when it will explode!"
|
||||
|
||||
@@ -45,14 +45,13 @@
|
||||
return*/
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/examine()
|
||||
set src in usr
|
||||
/obj/item/weapon/grenade/examine(mob/user)
|
||||
..()
|
||||
if(display_timer)
|
||||
if(det_time > 1)
|
||||
usr << "The timer is set to [det_time/10] seconds."
|
||||
user << "The timer is set to [det_time/10] second\s."
|
||||
else
|
||||
usr << "\The [src] is set for instant detonation."
|
||||
user << "\The [src] is set for instant detonation."
|
||||
|
||||
|
||||
/obj/item/weapon/grenade/attack_self(mob/user as mob)
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/weapon/melee/energy/
|
||||
/obj/item/weapon/melee/energy
|
||||
var/active = 0
|
||||
|
||||
/obj/item/weapon/melee/energy/suicide_act(mob/user)
|
||||
@@ -44,7 +44,6 @@
|
||||
add_fingerprint(user)
|
||||
|
||||
/obj/item/weapon/melee/energy/sword
|
||||
color
|
||||
name = "energy sword"
|
||||
desc = "May the force be within you."
|
||||
icon_state = "sword0"
|
||||
@@ -57,9 +56,11 @@
|
||||
flags = NOSHIELD
|
||||
origin_tech = "magnets=3;syndicate=4"
|
||||
var/hacked = 0
|
||||
item_color = null
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/New()
|
||||
item_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)
|
||||
@@ -98,9 +99,36 @@
|
||||
add_fingerprint(user)
|
||||
return
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/attackby(obj/item/weapon/W, mob/living/user)
|
||||
/obj/item/weapon/melee/energy/sword/cyborg
|
||||
var/hitcost = 500
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg/attack(mob/M, var/mob/living/silicon/robot/R)
|
||||
if(R.cell)
|
||||
var/obj/item/weapon/stock_parts/cell/C = R.cell
|
||||
if(active && !(C.use(hitcost)))
|
||||
attack_self(R)
|
||||
R << "<span class='notice'>It's out of charge!</span>"
|
||||
return
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/blue
|
||||
item_color = "blue"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/purple
|
||||
item_color = "purple"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/green
|
||||
item_color = "green"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/red
|
||||
item_color = "red"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/saber/attackby(obj/item/weapon/W, mob/living/user)
|
||||
..()
|
||||
if(istype(W, /obj/item/weapon/melee/energy/sword))
|
||||
if(istype(W, /obj/item/weapon/melee/energy/sword/saber))
|
||||
if(W == src)
|
||||
user << "<span class='notice'>You try to attach the end of the energy sword to... itself. You're not very smart, are you?</span>"
|
||||
if(ishuman(user))
|
||||
@@ -115,6 +143,7 @@
|
||||
user.unEquip(src)
|
||||
qdel(W)
|
||||
qdel(src)
|
||||
user.put_in_hands(newSaber)
|
||||
else if(istype(W, /obj/item/device/multitool))
|
||||
if(hacked == 0)
|
||||
hacked = 1
|
||||
@@ -133,32 +162,11 @@
|
||||
else
|
||||
user << "<span class='warning'>It's already fabulous!</span>"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg
|
||||
var/hitcost = 500
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/cyborg/attack(mob/M, var/mob/living/silicon/robot/R)
|
||||
if(R.cell)
|
||||
var/obj/item/weapon/stock_parts/cell/C = R.cell
|
||||
if(active && !(C.use(hitcost)))
|
||||
attack_self(R)
|
||||
R << "<span class='notice'>It's out of charge!</span>"
|
||||
return
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/pirate
|
||||
name = "energy cutlass"
|
||||
desc = "Arrrr matey."
|
||||
icon_state = "cutlass0"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/green
|
||||
New()
|
||||
item_color = "green"
|
||||
|
||||
/obj/item/weapon/melee/energy/sword/red
|
||||
New()
|
||||
item_color = "red"
|
||||
|
||||
/obj/item/weapon/melee/energy/blade
|
||||
name = "energy blade"
|
||||
desc = "A concentrated beam of energy in the shape of a blade. Very stylish... and lethal."
|
||||
|
||||
@@ -56,7 +56,7 @@
|
||||
M.visible_message("<span class='danger'>[M] has been beaten with [src] by [user]!</span>", \
|
||||
"<span class='userdanger'>[M] has been beaten with [src] by [user]!</span>")
|
||||
else
|
||||
playsound(loc, 'sound/weapons/Genhit.ogg', 50, 1, -1)
|
||||
playsound(loc, 'sound/effects/woodhit.ogg', 50, 1, -1)
|
||||
M.Stun(7)
|
||||
M.Weaken(7)
|
||||
M.visible_message("<span class='danger'>[M] has been stunned with [src] by [user]!</span>", \
|
||||
@@ -64,4 +64,75 @@
|
||||
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.forcesay(hit_appends)
|
||||
H.forcesay(hit_appends)
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/melee/telebaton
|
||||
name = "telescopic baton"
|
||||
desc = "A compact yet robust personal defense weapon. Can be concealed when folded."
|
||||
icon = 'icons/obj/weapons.dmi'
|
||||
icon_state = "telebaton_0"
|
||||
item_state = "telebaton_0"
|
||||
slot_flags = SLOT_BELT
|
||||
w_class = 2
|
||||
force = 3
|
||||
var/cooldown = 0
|
||||
var/on = 0
|
||||
|
||||
/obj/item/weapon/melee/telebaton/attack_self(mob/user as mob)
|
||||
on = !on
|
||||
if(on)
|
||||
user.visible_message("<span class ='warning'>With a flick of their wrist, [user] extends their telescopic baton.</span>",\
|
||||
"<span class ='warning'>You extend the baton.</span>",\
|
||||
"You hear an ominous click.")
|
||||
icon_state = "telebaton_1"
|
||||
item_state = "nullrod"
|
||||
w_class = 4 //doesnt fit in backpack when its on for balance
|
||||
force = 10 //seclite damage
|
||||
attack_verb = list("smacked", "struck", "cracked", "beaten")
|
||||
else
|
||||
user.visible_message("<span class ='notice'>[user] collapses their telescopic baton.</span>",\
|
||||
"<span class ='notice'>You collapse the baton.</span>",\
|
||||
"You hear a click.")
|
||||
icon_state = "telebaton_0"
|
||||
item_state = "telebaton_0" //no sprite in other words
|
||||
slot_flags = SLOT_BELT
|
||||
w_class = 2
|
||||
force = 3 //not so robust now
|
||||
attack_verb = list("hit", "poked")
|
||||
|
||||
playsound(src.loc, 'sound/weapons/batonextend.ogg', 50, 1)
|
||||
add_fingerprint(user)
|
||||
|
||||
/obj/item/weapon/melee/telebaton/attack(mob/target as mob, mob/living/user as mob)
|
||||
if(on)
|
||||
add_fingerprint(user)
|
||||
if((CLUMSY in user.mutations) && prob(50))
|
||||
user << "<span class ='danger'>You club yourself over the head.</span>"
|
||||
user.Weaken(3 * force)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.apply_damage(2*force, BRUTE, "head")
|
||||
else
|
||||
user.take_organ_damage(2*force)
|
||||
return
|
||||
if (user.a_intent == "harm")
|
||||
if(!..()) return
|
||||
if(!isrobot(target)) return
|
||||
else
|
||||
if(cooldown <= 0)
|
||||
playsound(get_turf(src), 'sound/effects/woodhit.ogg', 75, 1, -1)
|
||||
target.Weaken(3)
|
||||
src.add_fingerprint(user)
|
||||
target.visible_message("<span class ='danger'>[target] has been knocked down with \the [src] by [user]!</span>")
|
||||
if(!iscarbon(user))
|
||||
target.LAssailant = null
|
||||
else
|
||||
target.LAssailant = user
|
||||
cooldown = 1
|
||||
spawn(40)
|
||||
cooldown = 0
|
||||
return
|
||||
else
|
||||
return ..()
|
||||
@@ -14,7 +14,7 @@
|
||||
desc = "You wear this on your back and put items into it."
|
||||
icon_state = "backpack"
|
||||
item_state = "backpack"
|
||||
w_class = 4.0
|
||||
w_class = 4
|
||||
slot_flags = SLOT_BACK //ERROOOOO
|
||||
max_w_class = 3
|
||||
max_combined_w_class = 21
|
||||
@@ -35,10 +35,6 @@
|
||||
max_w_class = 5
|
||||
max_combined_w_class = 35
|
||||
|
||||
/obj/item/weapon/storage/backpack/holding/New()
|
||||
..()
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/backpack/holding/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(crit_fail)
|
||||
user << "<span class='danger'>The Bluespace generator isn't working.</span>"
|
||||
@@ -73,9 +69,9 @@
|
||||
icon_state = "giftbag0"
|
||||
item_state = "giftbag"
|
||||
w_class = 4.0
|
||||
storage_slots = 20
|
||||
storage_slots = 20 //Can store a lot.
|
||||
max_w_class = 3
|
||||
max_combined_w_class = 400 // can store a ton of shit!
|
||||
max_combined_w_class = 60
|
||||
|
||||
/obj/item/weapon/storage/backpack/cultpack
|
||||
name = "trophy rack"
|
||||
@@ -89,6 +85,12 @@
|
||||
icon_state = "clownpack"
|
||||
item_state = "clownpack"
|
||||
|
||||
/obj/item/weapon/storage/backpack/mime
|
||||
name = "Parcel Parceaux"
|
||||
desc = "A silent backpack made for those silent workers. Silence Co."
|
||||
icon_state = "mimepack"
|
||||
item_state = "mimepack"
|
||||
|
||||
/obj/item/weapon/storage/backpack/medic
|
||||
name = "medical backpack"
|
||||
desc = "It's a backpack especially designed for use in a sterile environment."
|
||||
@@ -122,10 +124,9 @@
|
||||
desc = "It's a very fancy satchel made with fine leather."
|
||||
icon_state = "satchel"
|
||||
|
||||
/obj/item/weapon/storage/backpack/satchel/withwallet
|
||||
New()
|
||||
..()
|
||||
new /obj/item/weapon/storage/wallet/random( src )
|
||||
/obj/item/weapon/storage/backpack/satchel/withwallet/New()
|
||||
..()
|
||||
new /obj/item/weapon/storage/wallet/random( src )
|
||||
|
||||
/obj/item/weapon/storage/backpack/satchel_norm
|
||||
name = "satchel"
|
||||
@@ -181,8 +182,27 @@
|
||||
icon_state = "satchel-cap"
|
||||
item_state = "captainpack"
|
||||
|
||||
/obj/item/weapon/storage/backpack/mime
|
||||
name = "Parcel Parceaux"
|
||||
desc = "A silent backpack made for those silent workers. Silence Co."
|
||||
icon_state = "mimepack"
|
||||
item_state = "mimepack"
|
||||
/obj/item/weapon/storage/backpack/satchel_flat
|
||||
name = "smuggler's satchel"
|
||||
desc = "A very slim satchel that can easily fit into tight spaces."
|
||||
icon_state = "satchel-flat"
|
||||
w_class = 3 //Can fit in backpacks itself.
|
||||
storage_slots = 5
|
||||
max_combined_w_class = 15
|
||||
level = 1
|
||||
cant_hold = list(/obj/item/weapon/storage/backpack/satchel_flat) //muh recursive backpacks
|
||||
|
||||
/obj/item/weapon/storage/backpack/satchel_flat/hide(var/intact)
|
||||
if(intact)
|
||||
invisibility = 101
|
||||
anchored = 1 //otherwise you can start pulling, cover it, and drag around an invisible backpack.
|
||||
icon_state = "[initial(icon_state)]2"
|
||||
else
|
||||
invisibility = initial(invisibility)
|
||||
anchored = 0
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
/obj/item/weapon/storage/backpack/satchel_flat/New()
|
||||
..()
|
||||
new /obj/item/stack/tile/plasteel(src)
|
||||
new /obj/item/weapon/crowbar(src)
|
||||
|
||||
@@ -50,8 +50,9 @@
|
||||
/obj/item/device/flashlight,
|
||||
/obj/item/stack/cable_coil,
|
||||
/obj/item/device/t_scanner,
|
||||
/obj/item/device/analyzer)
|
||||
|
||||
/obj/item/device/analyzer,
|
||||
/obj/item/weapon/extinguisher/mini
|
||||
)
|
||||
|
||||
/obj/item/weapon/storage/belt/utility/full/New()
|
||||
..()
|
||||
@@ -71,6 +72,7 @@
|
||||
new /obj/item/weapon/crowbar(src)
|
||||
new /obj/item/weapon/wirecutters(src)
|
||||
new /obj/item/device/t_scanner(src)
|
||||
new /obj/item/weapon/extinguisher/mini(src)
|
||||
|
||||
|
||||
|
||||
@@ -91,8 +93,9 @@
|
||||
/obj/item/weapon/storage/fancy/cigarettes,
|
||||
/obj/item/weapon/storage/pill_bottle,
|
||||
/obj/item/stack/medical,
|
||||
/obj/item/device/flashlight/pen
|
||||
)
|
||||
/obj/item/device/flashlight/pen,
|
||||
/obj/item/weapon/extinguisher/mini
|
||||
)
|
||||
|
||||
|
||||
/obj/item/weapon/storage/belt/security
|
||||
|
||||
@@ -24,19 +24,14 @@
|
||||
src.icon_state = "[src.icon_type]box[total_contents]"
|
||||
return
|
||||
|
||||
/obj/item/weapon/storage/fancy/examine()
|
||||
set src in oview(1)
|
||||
/obj/item/weapon/storage/fancy/examine(mob/user)
|
||||
..()
|
||||
if(contents.len <= 0)
|
||||
usr << "There are no [src.icon_type]s left in the box."
|
||||
user << "There are no [src.icon_type]s left in the box."
|
||||
else if(contents.len == 1)
|
||||
usr << "There is one [src.icon_type] left in the box."
|
||||
user << "There is one [src.icon_type] left in the box."
|
||||
else
|
||||
usr << "There are [src.contents.len] [src.icon_type]s in the box."
|
||||
|
||||
return
|
||||
|
||||
|
||||
user << "There are [src.contents.len] [src.icon_type]s in the box."
|
||||
|
||||
/*
|
||||
* Donut Box
|
||||
|
||||
@@ -27,10 +27,9 @@
|
||||
max_w_class = 2
|
||||
max_combined_w_class = 14
|
||||
|
||||
/obj/item/weapon/storage/secure/examine()
|
||||
set src in oview(1)
|
||||
/obj/item/weapon/storage/secure/examine(mob/user)
|
||||
..()
|
||||
usr << text("The service panel is [src.open ? "open" : "closed"].")
|
||||
user << text("The service panel is [src.open ? "open" : "closed"].")
|
||||
|
||||
/obj/item/weapon/storage/secure/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(locked)
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
|
||||
/obj/item/weapon/storage/MouseDrop(obj/over_object)
|
||||
if(iscarbon(usr)) //all the check for item manipulation are in other places, you can safely open any storages as anything and its not buggy, i checked
|
||||
if(iscarbon(usr) || isdrone(usr)) //all the check for item manipulation are in other places, you can safely open any storages as anything and its not buggy, i checked
|
||||
var/mob/M = usr
|
||||
|
||||
if (istype(usr.loc,/obj/mecha)) // stops inventory actions in a mech
|
||||
|
||||
@@ -83,3 +83,18 @@
|
||||
new /obj/item/stack/cable_coil(src,30,color)
|
||||
new /obj/item/weapon/wirecutters(src)
|
||||
new /obj/item/device/multitool(src)
|
||||
|
||||
/obj/item/weapon/storage/toolbox/drone
|
||||
name = "mechanical toolbox"
|
||||
icon_state = "blue"
|
||||
item_state = "toolbox_blue"
|
||||
|
||||
/obj/item/weapon/storage/toolbox/drone/New()
|
||||
..()
|
||||
new /obj/item/weapon/screwdriver(src)
|
||||
new /obj/item/weapon/wrench(src)
|
||||
new /obj/item/weapon/weldingtool(src)
|
||||
new /obj/item/weapon/crowbar(src)
|
||||
new /obj/item/stack/cable_coil(src,30,color)
|
||||
new /obj/item/weapon/wirecutters(src)
|
||||
new /obj/item/device/multitool(src)
|
||||
@@ -43,7 +43,7 @@
|
||||
return
|
||||
|
||||
if("murder")
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/clothing/glasses/thermal/syndi(src)
|
||||
new /obj/item/weapon/card/emag(src)
|
||||
new /obj/item/clothing/shoes/syndigaloshes(src)
|
||||
@@ -78,8 +78,8 @@
|
||||
return
|
||||
|
||||
if("darklord")
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/dnainjector/telemut/darkbundle(src)
|
||||
new /obj/item/clothing/head/chaplain_hood(src)
|
||||
new /obj/item/clothing/suit/chaplain_hoodie(src)
|
||||
|
||||
@@ -52,13 +52,12 @@
|
||||
else
|
||||
icon_state = "[initial(name)]"
|
||||
|
||||
/obj/item/weapon/melee/baton/examine()
|
||||
set src in view(1)
|
||||
/obj/item/weapon/melee/baton/examine(mob/user)
|
||||
..()
|
||||
if(bcell)
|
||||
usr <<"<span class='notice'>The baton is [round(bcell.percent())]% charged.</span>"
|
||||
user <<"<span class='notice'>The baton is [round(bcell.percent())]% charged.</span>"
|
||||
if(!bcell)
|
||||
usr <<"<span class='warning'>The baton does not have a power source installed.</span>"
|
||||
user <<"<span class='warning'>The baton does not have a power source installed.</span>"
|
||||
|
||||
/obj/item/weapon/melee/baton/attackby(obj/item/weapon/W, mob/user)
|
||||
if(istype(W, /obj/item/weapon/stock_parts/cell))
|
||||
|
||||
@@ -23,14 +23,6 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/tank/oxygen/examine()
|
||||
set src in usr
|
||||
..()
|
||||
if(air_contents.oxygen < 10)
|
||||
usr << text("<span class='userdanger'>The meter on the [src.name] indicates you are almost out of air!</span>")
|
||||
playsound(usr, 'sound/effects/alert.ogg', 50, 1)
|
||||
|
||||
|
||||
/obj/item/weapon/tank/oxygen/yellow
|
||||
desc = "A tank of oxygen, this one is yellow."
|
||||
icon_state = "oxygen_f"
|
||||
@@ -69,13 +61,6 @@
|
||||
icon_state = "oxygen"
|
||||
|
||||
|
||||
/obj/item/weapon/tank/air/examine()
|
||||
set src in usr
|
||||
..()
|
||||
if(air_contents.oxygen < 1 && loc==usr)
|
||||
usr << "<span class='userdanger'>The meter on the [src.name] indicates you are almost out of air!</span>"
|
||||
usr << sound('sound/effects/alert.ogg')
|
||||
|
||||
/obj/item/weapon/tank/air/New()
|
||||
..()
|
||||
|
||||
@@ -138,14 +123,6 @@
|
||||
src.air_contents.oxygen = (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)
|
||||
return
|
||||
|
||||
|
||||
/obj/item/weapon/tank/emergency_oxygen/examine()
|
||||
set src in usr
|
||||
..()
|
||||
if(air_contents.oxygen < 0.2 && loc==usr)
|
||||
usr << text("<span class='userdanger'>The meter on the [src.name] indicates you are almost out of air!</span>")
|
||||
usr << sound('sound/effects/alert.ogg')
|
||||
|
||||
/obj/item/weapon/tank/emergency_oxygen/engi
|
||||
name = "extended-capacity emergency oxygen tank"
|
||||
icon_state = "emergency_engi"
|
||||
|
||||
@@ -36,13 +36,13 @@
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/weapon/tank/examine()
|
||||
/obj/item/weapon/tank/examine(mob/user)
|
||||
var/obj/icon = src
|
||||
..()
|
||||
if (istype(src.loc, /obj/item/assembly))
|
||||
icon = src.loc
|
||||
if (!in_range(src, usr))
|
||||
if (icon == src) usr << "<span class='notice'>If you want any more information you'll need to get closer.</span>"
|
||||
if (!in_range(src, user))
|
||||
if (icon == src) user << "<span class='notice'>If you want any more information you'll need to get closer.</span>"
|
||||
return
|
||||
|
||||
var/celsius_temperature = src.air_contents.temperature-T0C
|
||||
@@ -61,9 +61,7 @@
|
||||
else
|
||||
descriptive = "furiously hot"
|
||||
|
||||
usr << "<span class='notice'>It feels [descriptive]</span>"
|
||||
|
||||
return
|
||||
user << "<span class='notice'>It feels [descriptive].</span>"
|
||||
|
||||
/obj/item/weapon/tank/blob_act()
|
||||
if(prob(50))
|
||||
|
||||
@@ -18,14 +18,6 @@
|
||||
..()
|
||||
create_reagents(volume)
|
||||
noz = make_noz()
|
||||
return
|
||||
|
||||
/obj/item/weapon/watertank/examine()
|
||||
set src in usr
|
||||
..()
|
||||
for(var/datum/reagent/R in reagents.reagent_list)
|
||||
usr << "[round(R.volume)] units of [R.name] left."
|
||||
return
|
||||
|
||||
/obj/item/weapon/watertank/ui_action_click()
|
||||
if (usr.get_item_by_slot(slot_back) == src)
|
||||
|
||||
@@ -151,10 +151,9 @@
|
||||
reagents.add_reagent("fuel", max_fuel)
|
||||
|
||||
|
||||
/obj/item/weapon/weldingtool/examine()
|
||||
set src in usr
|
||||
/obj/item/weapon/weldingtool/examine(mob/user)
|
||||
..()
|
||||
usr << "It contains [get_fuel()]/[max_fuel] units of fuel!"
|
||||
user << "It contains [get_fuel()] unit\s of fuel out of [max_fuel]."
|
||||
|
||||
|
||||
/obj/item/weapon/weldingtool/attackby(obj/item/I, mob/user)
|
||||
@@ -445,4 +444,4 @@
|
||||
throw_speed = 3
|
||||
throw_range = 3
|
||||
m_amt = 66
|
||||
icon_state = "crowbar_large"
|
||||
icon_state = "crowbar_large"
|
||||
|
||||
@@ -20,13 +20,12 @@
|
||||
if(isnum(amt) && amt > -1)
|
||||
charges = amt
|
||||
|
||||
/obj/item/weapon/vending_refill/examine()
|
||||
set src in usr
|
||||
/obj/item/weapon/vending_refill/examine(mob/user)
|
||||
..()
|
||||
if(charges)
|
||||
usr << "It can restock [charges] item(s)."
|
||||
user << "It can restock [charges] item(s)."
|
||||
else
|
||||
usr << "It's empty!"
|
||||
user << "It's empty!"
|
||||
|
||||
//NOTE I decided to go for about 1/3 of a machine's capacity
|
||||
|
||||
|
||||
@@ -15,4 +15,9 @@ obj/structure/ex_act(severity)
|
||||
qdel(src)
|
||||
return
|
||||
if(3.0)
|
||||
return
|
||||
return
|
||||
|
||||
obj/structure/Destroy()
|
||||
if(opacity)
|
||||
UpdateAffectingLights()
|
||||
..()
|
||||
@@ -163,15 +163,14 @@ LINEN BINS
|
||||
var/obj/item/hidden = null
|
||||
|
||||
|
||||
/obj/structure/bedsheetbin/examine()
|
||||
/obj/structure/bedsheetbin/examine(mob/user)
|
||||
..()
|
||||
if(amount < 1)
|
||||
usr << "There are no bed sheets in the bin."
|
||||
return
|
||||
if(amount == 1)
|
||||
usr << "There is one bed sheet in the bin."
|
||||
return
|
||||
usr << "There are [amount] bed sheets in the bin."
|
||||
user << "There are no bed sheets in the bin."
|
||||
else if(amount == 1)
|
||||
user << "There is one bed sheet in the bin."
|
||||
else
|
||||
user << "There are [amount] bed sheets in the bin."
|
||||
|
||||
|
||||
/obj/structure/bedsheetbin/update_icon()
|
||||
|
||||
@@ -179,16 +179,16 @@
|
||||
|
||||
if(istype(W, /obj/item/weapon/weldingtool))
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
user << "<span class='notice'>You begin cutting the [src] apart...</span>"
|
||||
playsound(loc, 'sound/items/Welder.ogg', 40, 1)
|
||||
if(do_after(user,40,5,1))
|
||||
if(src.opened)
|
||||
if(WT.remove_fuel(0,user))
|
||||
playsound(loc, 'sound/items/Welder2.ogg', 50, 1)
|
||||
new /obj/item/stack/sheet/metal(src.loc)
|
||||
for(var/mob/M in viewers(src))
|
||||
M.show_message("<span class='notice'>\The [src] has been cut apart by [user] with \the [WT].</span>", 3, "You hear welding.", 2)
|
||||
qdel(src)
|
||||
if(WT.remove_fuel(0,user))
|
||||
user << "<span class='notice'>You begin cutting the [src] apart...</span>"
|
||||
playsound(loc, 'sound/items/Welder.ogg', 40, 1)
|
||||
if(do_after(user,40,5,1))
|
||||
if( !src.opened || !istype(src, /obj/structure/closet) || !user || !WT || !WT.isOn() || !user.loc )
|
||||
return
|
||||
playsound(loc, 'sound/items/Welder2.ogg', 50, 1)
|
||||
new /obj/item/stack/sheet/metal(src.loc)
|
||||
visible_message("<span class='notice'>\The [src] has been cut apart by [user] with \the [WT].</span>", "You hear welding.")
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
if(isrobot(user))
|
||||
@@ -201,16 +201,17 @@
|
||||
return
|
||||
else if(istype(W, /obj/item/weapon/weldingtool))
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
user << "<span class='notice'>You begin [welded ? "unwelding":"welding"] the [src]...</span>"
|
||||
playsound(loc, 'sound/items/Welder2.ogg', 40, 1)
|
||||
if(do_after(user,40,5,1))
|
||||
if(!src.opened)
|
||||
if(WT.remove_fuel(0,user))
|
||||
playsound(loc, 'sound/items/welder.ogg', 50, 1)
|
||||
welded = !welded
|
||||
user << "<span class='notice'>You [welded ? "welded the [src] shut":"unwelded the [src]"]</span>"
|
||||
update_icon()
|
||||
user.visible_message("<span class='warning'>[src] has been [welded? "welded shut":"unwelded"] by [user.name].</span>")
|
||||
if(WT.remove_fuel(0,user))
|
||||
user << "<span class='notice'>You begin [welded ? "unwelding":"welding"] the [src]...</span>"
|
||||
playsound(loc, 'sound/items/Welder2.ogg', 40, 1)
|
||||
if(do_after(user,40,5,1))
|
||||
if(src.opened || !istype(src, /obj/structure/closet) || !user || !WT || !WT.isOn() || !user.loc )
|
||||
return
|
||||
playsound(loc, 'sound/items/welder.ogg', 50, 1)
|
||||
welded = !welded
|
||||
user << "<span class='notice'>You [welded ? "welded the [src] shut":"unwelded the [src]"]</span>"
|
||||
update_icon()
|
||||
user.visible_message("<span class='warning'>[src] has been [welded? "welded shut":"unwelded"] by [user.name].</span>")
|
||||
return
|
||||
else if(!place(user, W))
|
||||
src.attack_hand(user)
|
||||
|
||||
@@ -96,9 +96,9 @@
|
||||
new /obj/item/clothing/suit/armor/tdome/red(src)
|
||||
new /obj/item/clothing/suit/armor/tdome/red(src)
|
||||
new /obj/item/clothing/suit/armor/tdome/red(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
@@ -124,9 +124,9 @@
|
||||
new /obj/item/clothing/suit/armor/tdome/green(src)
|
||||
new /obj/item/clothing/suit/armor/tdome/green(src)
|
||||
new /obj/item/clothing/suit/armor/tdome/green(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/melee/energy/sword/saber(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
new /obj/item/weapon/gun/energy/laser(src)
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
new /obj/item/weapon/storage/backpack/satchel_cap(src)
|
||||
new /obj/item/clothing/suit/captunic(src)
|
||||
new /obj/item/clothing/under/captainformal(src)
|
||||
new /obj/item/clothing/head/helmet/cap(src)
|
||||
new /obj/item/clothing/head/caphat/parade(src)
|
||||
new /obj/item/clothing/under/rank/captain(src)
|
||||
new /obj/item/clothing/suit/armor/vest/capcarapace(src)
|
||||
new /obj/item/weapon/cartridge/captain(src)
|
||||
@@ -71,7 +71,7 @@
|
||||
sleep(2)
|
||||
new /obj/item/clothing/suit/armor/vest(src)
|
||||
new /obj/item/clothing/suit/armor/hos/jensen(src)
|
||||
new /obj/item/clothing/head/helmet/HoS/dermal(src)
|
||||
new /obj/item/clothing/head/HoS/dermal(src)
|
||||
new /obj/item/weapon/cartridge/hos(src)
|
||||
new /obj/item/device/radio/headset/heads/hos/alt(src)
|
||||
new /obj/item/clothing/glasses/hud/security/sunglasses(src)
|
||||
@@ -103,7 +103,7 @@
|
||||
new /obj/item/clothing/suit/armor/vest(src)
|
||||
new /obj/item/clothing/under/rank/warden(src)
|
||||
new /obj/item/clothing/suit/armor/vest/warden(src)
|
||||
new /obj/item/clothing/head/helmet/warden(src)
|
||||
new /obj/item/clothing/head/warden(src)
|
||||
new /obj/item/weapon/clipboard(src)
|
||||
new /obj/item/device/radio/headset/headset_sec/alt(src)
|
||||
new /obj/item/clothing/glasses/hud/security/sunglasses(src)
|
||||
@@ -198,9 +198,12 @@
|
||||
sleep(2)
|
||||
new /obj/item/clothing/under/rank/det(src)
|
||||
new /obj/item/clothing/suit/det_suit(src)
|
||||
new /obj/item/clothing/gloves/black(src)
|
||||
new /obj/item/clothing/head/det_hat(src)
|
||||
new /obj/item/clothing/shoes/sneakers/brown(src)
|
||||
new /obj/item/clothing/gloves/black(src)
|
||||
new /obj/item/clothing/under/det/grey(src)
|
||||
new /obj/item/clothing/suit/det_suit/grey(src)
|
||||
new /obj/item/clothing/head/fedora(src)
|
||||
new /obj/item/clothing/shoes/laceup(src)
|
||||
new /obj/item/weapon/storage/box/evidence(src)
|
||||
new /obj/item/weapon/clipboard(src)
|
||||
new /obj/item/device/radio/headset/headset_sec(src)
|
||||
|
||||
@@ -7,24 +7,22 @@
|
||||
|
||||
|
||||
/obj/structure/closet/syndicate/personal
|
||||
desc = "It's a storage unit for operative gear."
|
||||
desc = "It's a personal storage unit for operative gear."
|
||||
|
||||
/obj/structure/closet/syndicate/personal/New()
|
||||
..()
|
||||
sleep(2)
|
||||
new /obj/item/weapon/tank/jetpack/oxygen/harness(src)
|
||||
new /obj/item/clothing/mask/gas/syndicate(src)
|
||||
new /obj/item/clothing/under/syndicate(src)
|
||||
new /obj/item/clothing/head/helmet/space/hardsuit/syndi(src)
|
||||
new /obj/item/clothing/suit/space/hardsuit/syndi(src)
|
||||
new /obj/item/clothing/suit/armor/vest(src)
|
||||
new /obj/item/clothing/head/helmet/swat/syndicate(src)
|
||||
new /obj/item/ammo_box/magazine/m10mm(src)
|
||||
new /obj/item/weapon/storage/belt/military(src)
|
||||
new /obj/item/weapon/crowbar/red(src)
|
||||
new /obj/item/weapon/stock_parts/cell/high(src)
|
||||
new /obj/item/device/multitool(src)
|
||||
|
||||
new /obj/item/clothing/glasses/night(src)
|
||||
return
|
||||
|
||||
/obj/structure/closet/syndicate/nuclear
|
||||
desc = "It's a storage unit for nuclear-operative gear."
|
||||
desc = "It's a storage unit for a Syndicate boarding party."
|
||||
|
||||
/obj/structure/closet/syndicate/nuclear/New()
|
||||
..()
|
||||
@@ -34,14 +32,13 @@
|
||||
new /obj/item/ammo_box/magazine/m10mm(src)
|
||||
new /obj/item/ammo_box/magazine/m10mm(src)
|
||||
new /obj/item/ammo_box/magazine/m10mm(src)
|
||||
new /obj/item/weapon/storage/box/handcuffs(src)
|
||||
new /obj/item/weapon/storage/box/flashbangs(src)
|
||||
new /obj/item/weapon/storage/box/teargas(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/gun/energy/gun(src)
|
||||
new /obj/item/weapon/gun/projectile/automatic/bulldog(src)
|
||||
new /obj/item/weapon/gun/projectile/automatic/bulldog(src)
|
||||
new /obj/item/weapon/gun/projectile/automatic/bulldog(src)
|
||||
new /obj/item/weapon/gun/projectile/automatic/bulldog(src)
|
||||
new /obj/item/weapon/gun/projectile/automatic/bulldog(src)
|
||||
new /obj/item/weapon/pinpointer/nukeop(src)
|
||||
new /obj/item/weapon/pinpointer/nukeop(src)
|
||||
new /obj/item/weapon/pinpointer/nukeop(src)
|
||||
|
||||
@@ -440,7 +440,8 @@ obj/structure/door_assembly/New()
|
||||
else if(istype(W, /obj/item/weapon/weldingtool) && !anchored )
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
if(WT.remove_fuel(0,user))
|
||||
user.visible_message("[user] dissassembles the airlock assembly.", "You start to dissassemble the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] dissassembles the airlock assembly.</span>", \
|
||||
"You start to dissassemble the airlock assembly.")
|
||||
playsound(src.loc, 'sound/items/Welder2.ogg', 50, 1)
|
||||
|
||||
if(do_after(user, 40))
|
||||
@@ -461,7 +462,9 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wrench) && !anchored )
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 100, 1)
|
||||
user.visible_message("[user] secures the airlock assembly to the floor.", "You start to secure the airlock assembly to the floor.")
|
||||
user.visible_message("<span class='warning'>[user] secures the airlock assembly to the floor.</span>", \
|
||||
"You start to secure the airlock assembly to the floor.", \
|
||||
"You hear wrenching")
|
||||
|
||||
if(do_after(user, 40))
|
||||
if( src.anchored )
|
||||
@@ -472,7 +475,9 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wrench) && anchored )
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 100, 1)
|
||||
user.visible_message("[user] unsecures the airlock assembly from the floor.", "You start to unsecure the airlock assembly from the floor.")
|
||||
user.visible_message("<span class='warning'>[user] unsecures the airlock assembly from the floor.</span>", \
|
||||
"You start to unsecure the airlock assembly from the floor.", \
|
||||
"You hear wrenching")
|
||||
if(do_after(user, 40))
|
||||
if( !src.anchored )
|
||||
return
|
||||
@@ -485,7 +490,8 @@ obj/structure/door_assembly/New()
|
||||
if (C.get_amount() < 1)
|
||||
user << "<span class='warning'>You need one length of cable to wire the airlock assembly.</span>"
|
||||
return
|
||||
user.visible_message("[user] wires the airlock assembly.", "You start to wire the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] wires the airlock assembly.</span>", \
|
||||
"You start to wire the airlock assembly.")
|
||||
if(do_after(user, 40))
|
||||
if(C.get_amount() < 1 || state != 0) return
|
||||
C.use(1)
|
||||
@@ -495,7 +501,8 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wirecutters) && state == 1 )
|
||||
playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1)
|
||||
user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] cuts the wires from the airlock assembly.</span>", \
|
||||
"You start to cut the wires from the airlock assembly.")
|
||||
|
||||
if(do_after(user, 40))
|
||||
if( src.state != 1 )
|
||||
@@ -507,12 +514,14 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/airlock_electronics) && state == 1 )
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1)
|
||||
user.visible_message("[user] installs the electronics into the airlock assembly.", "You start to install electronics into the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] installs the electronics into the airlock assembly.</span>", \
|
||||
"You start to install electronics into the airlock assembly.")
|
||||
user.drop_item()
|
||||
W.loc = src
|
||||
|
||||
if(do_after(user, 40))
|
||||
if( src.state != 1 )
|
||||
W.loc = src.loc
|
||||
return
|
||||
user << "<span class='notice'> You've installed the airlock electronics.</span>"
|
||||
src.state = 2
|
||||
@@ -525,7 +534,8 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/crowbar) && state == 2 )
|
||||
playsound(src.loc, 'sound/items/Crowbar.ogg', 100, 1)
|
||||
user.visible_message("[user] removes the electronics from the airlock assembly.", "You start to remove the electronics from the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] removes the electronics from the airlock assembly.</span>", \
|
||||
"You start to remove electronics from the airlock assembly.")
|
||||
|
||||
if(do_after(user, 40))
|
||||
if( src.state != 2 )
|
||||
@@ -546,7 +556,8 @@ obj/structure/door_assembly/New()
|
||||
if(G.get_amount() >= 1)
|
||||
if(G.type == /obj/item/stack/sheet/rglass)
|
||||
playsound(src.loc, 'sound/items/Crowbar.ogg', 100, 1)
|
||||
user.visible_message("[user] adds [G.name] to the airlock assembly.", "You start to install [G.name] into the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] adds [G.name] to the airlock assembly.</span>", \
|
||||
"You start to install [G.name] into the airlock assembly.")
|
||||
if(do_after(user, 40))
|
||||
if(G.get_amount() < 1 || mineral) return
|
||||
user << "<span class='notice'>You've installed reinforced glass windows into the airlock assembly.</span>"
|
||||
@@ -569,7 +580,8 @@ obj/structure/door_assembly/New()
|
||||
var/M = G.sheettype
|
||||
if(G.get_amount() >= 2)
|
||||
playsound(src.loc, 'sound/items/Crowbar.ogg', 100, 1)
|
||||
user.visible_message("[user] adds [G.name] to the airlock assembly.", "You start to install [G.name] into the airlock assembly.")
|
||||
user.visible_message("<span class='warning'>[user] adds [G.name] to the airlock assembly.</span>", \
|
||||
"You start to install [G.name] into the airlock assembly.")
|
||||
if(do_after(user, 40))
|
||||
if(G.get_amount() < 2 || mineral) return
|
||||
user << "<span class='notice'>You've installed [M] plating into the airlock assembly.</span>"
|
||||
@@ -583,25 +595,27 @@ obj/structure/door_assembly/New()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/screwdriver) && state == 2 )
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1)
|
||||
user.visible_message("[user] finishes the airlock.", "You start finishing the airlock.")
|
||||
user.visible_message("<span class='warning'>[user] finishes the airlock.</span>", \
|
||||
"You start finishing the airlock.")
|
||||
|
||||
if(do_after(user, 40))
|
||||
user << "<span class='notice'> You've finished the airlock.</span>"
|
||||
var/obj/machinery/door/airlock/door
|
||||
if(mineral == "glass")
|
||||
door = new src.glass_type( src.loc )
|
||||
else
|
||||
door = new src.airlock_type( src.loc )
|
||||
//door.req_access = src.req_access
|
||||
door.electronics = src.electronics
|
||||
if(src.electronics.use_one_access)
|
||||
door.req_one_access = src.electronics.conf_access
|
||||
else
|
||||
door.req_access = src.electronics.conf_access
|
||||
if(created_name)
|
||||
door.name = created_name
|
||||
src.electronics.loc = door
|
||||
qdel(src)
|
||||
if(state == 2)
|
||||
user << "<span class='notice'> You've finished the airlock.</span>"
|
||||
var/obj/machinery/door/airlock/door
|
||||
if(mineral == "glass")
|
||||
door = new src.glass_type( src.loc )
|
||||
else
|
||||
door = new src.airlock_type( src.loc )
|
||||
//door.req_access = src.req_access
|
||||
door.electronics = src.electronics
|
||||
if(src.electronics.use_one_access)
|
||||
door.req_one_access = src.electronics.conf_access
|
||||
else
|
||||
door.req_access = src.electronics.conf_access
|
||||
if(created_name)
|
||||
door.name = created_name
|
||||
src.electronics.loc = door
|
||||
qdel(src)
|
||||
else
|
||||
..()
|
||||
if(mineral == "glass")
|
||||
|
||||
@@ -20,12 +20,6 @@
|
||||
create_reagents(100)
|
||||
|
||||
|
||||
/obj/structure/janitorialcart/examine()
|
||||
set src in usr
|
||||
..()
|
||||
usr << "It contains [reagents.total_volume] unit\s of liquid!"
|
||||
//everything else is visible, so doesn't need to be mentioned
|
||||
|
||||
/obj/structure/janitorialcart/proc/wet_mop(obj/item/weapon/mop, mob/user)
|
||||
if(reagents.total_volume < 1)
|
||||
user << "[src] is out of water!</span>"
|
||||
@@ -176,12 +170,10 @@
|
||||
create_reagents(100)
|
||||
|
||||
|
||||
/obj/structure/stool/bed/chair/janicart/examine()
|
||||
set src in usr
|
||||
/obj/structure/stool/bed/chair/janicart/examine(mob/user)
|
||||
..()
|
||||
usr << "It contains [reagents.total_volume] unit\s of water!"
|
||||
if(mybag)
|
||||
usr << "\A [mybag] is hanging on the [callme]."
|
||||
user << "\A [mybag] is hanging on \the [callme]."
|
||||
|
||||
|
||||
/obj/structure/stool/bed/chair/janicart/attackby(obj/item/I, mob/user)
|
||||
|
||||
@@ -12,12 +12,6 @@
|
||||
/obj/structure/mopbucket/New()
|
||||
create_reagents(100)
|
||||
|
||||
|
||||
/obj/structure/mopbucket/examine()
|
||||
set src in usr
|
||||
..()
|
||||
usr << "It contains [reagents.total_volume] unit\s of water!"
|
||||
|
||||
/obj/structure/mopbucket/attackby(obj/item/I, mob/user)
|
||||
if(istype(I, /obj/item/weapon/mop))
|
||||
if(reagents.total_volume < 1)
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
icon_state = "closed"
|
||||
exit_delay = 2
|
||||
enter_delay = 3
|
||||
tube_construction = /obj/structure/c_transit_tube/station
|
||||
var/pod_moving = 0
|
||||
var/automatic_launch_time = 100
|
||||
var/cooldown_delay = 200
|
||||
@@ -27,6 +28,7 @@
|
||||
|
||||
// Stations which will send the tube in the opposite direction after their stop.
|
||||
/obj/structure/transit_tube/station/reverse
|
||||
tube_construction = /obj/structure/c_transit_tube/station/reverse
|
||||
reverse_launch = 1
|
||||
|
||||
/obj/structure/transit_tube/station/should_stop_pod(pod, from_dir)
|
||||
@@ -40,6 +42,20 @@
|
||||
return
|
||||
|
||||
|
||||
//pod insertion
|
||||
/obj/structure/transit_tube/station/MouseDrop_T(obj/structure/c_transit_tube_pod/R as obj, mob/user as mob)
|
||||
if(!usr.canmove || usr.stat || usr.restrained())
|
||||
return
|
||||
if (!istype(R) || get_dist(user, src) > 1 || get_dist(src,R) > 1)
|
||||
return
|
||||
var/obj/structure/transit_tube_pod/T = new/obj/structure/transit_tube_pod(src)
|
||||
R.transfer_fingerprints_to(T)
|
||||
T.add_fingerprint(usr)
|
||||
T.loc = src.loc
|
||||
T.dir = turn(src.dir, -90)
|
||||
user.visible_message("<span class='notice'>[user] inserts the [R].</span>", "<span class='notice'>You insert the [R].</span>")
|
||||
qdel(R)
|
||||
|
||||
|
||||
/obj/structure/transit_tube/station/attack_hand(mob/user as mob)
|
||||
if(!pod_moving)
|
||||
@@ -76,6 +92,17 @@
|
||||
src.Bumped(GM)
|
||||
qdel(G)
|
||||
break
|
||||
if(istype(W, /obj/item/weapon/crowbar))
|
||||
for(var/obj/structure/transit_tube_pod/pod in loc)
|
||||
if(pod.contents)
|
||||
user << "<span class='notice'>Empty the pod first.</span>"
|
||||
return
|
||||
user.visible_message("<span class='notice'>[user] removes the [pod].</span>", "<span class='notice'>You remove the [pod].</span>")
|
||||
var/obj/structure/c_transit_tube_pod/R = new/obj/structure/c_transit_tube_pod(src.loc)
|
||||
pod.transfer_fingerprints_to(R)
|
||||
R.add_fingerprint(user)
|
||||
qdel(pod)
|
||||
..(W, user)
|
||||
|
||||
/obj/structure/transit_tube/station/proc/open_animation()
|
||||
if(icon_state == "closed")
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
// Basic transit tubes. Straight pieces, curved sections,
|
||||
// and basic splits/joins (no routing logic).
|
||||
// Mappers: you can use "Generate Instances from Icon-states"
|
||||
@@ -9,6 +8,7 @@
|
||||
density = 1
|
||||
layer = 3.1
|
||||
anchored = 1.0
|
||||
var/tube_construction = /obj/structure/c_transit_tube
|
||||
var/list/tube_dirs = null
|
||||
var/exit_delay = 2
|
||||
var/enter_delay = 1
|
||||
@@ -48,6 +48,37 @@ obj/structure/transit_tube/ex_act(severity)
|
||||
if(tube_dirs == null)
|
||||
init_dirs()
|
||||
|
||||
/obj/structure/transit_tube/attackby(obj/item/W, mob/user)
|
||||
if(istype(W, /obj/item/weapon/wrench))
|
||||
if(copytext(icon_state, 1, 3) != "D-") //decorative diagonals cannot be unwrenched directly
|
||||
for(var/obj/structure/transit_tube_pod/pod in loc)
|
||||
user << "<span class='notice'>Remove the pod first.</span>"
|
||||
return
|
||||
user.visible_message("<span class='warning'>[user] starts to deattach the [src]!</span>", "<span class='notice'>You start deattaching the [name]...</span>")
|
||||
playsound(src.loc, 'sound/items/Ratchet.ogg', 50, 1)
|
||||
if(do_after(user, 35))
|
||||
user << "<span class='notice'>You deattach the [name]!</span>"
|
||||
var/obj/structure/R = new tube_construction(src.loc)
|
||||
R.icon_state = src.icon_state
|
||||
src.transfer_fingerprints_to(R)
|
||||
R.add_fingerprint(user)
|
||||
src.destroy_diagonals()
|
||||
qdel(src)
|
||||
|
||||
//destroys disconnected decorative diagonals
|
||||
/obj/structure/transit_tube/proc/destroy_diagonals()
|
||||
for(var/obj/structure/transit_tube/D in orange(1, src))
|
||||
if(copytext(D.icon_state, 1, 3) == "D-") //is diagonal
|
||||
var/my_dir = text2dir_extended(copytext(D.icon_state, 3, 5))
|
||||
var/is_connecting = 0
|
||||
for(var/obj/structure/transit_tube/N in orange(1,D))
|
||||
if( (( get_dir(D,N) == turn(my_dir, -45) && D.has_exit(turn(my_dir, 90)) ) || \
|
||||
( get_dir(D,N) == turn(my_dir, 45) && D.has_exit(turn(my_dir, -90))) ) && \
|
||||
D != src )
|
||||
is_connecting = 1
|
||||
break
|
||||
if(!is_connecting)
|
||||
qdel(D)
|
||||
|
||||
// Called to check if a pod should stop upon entering this tube.
|
||||
/obj/structure/transit_tube/proc/should_stop_pod(pod, from_dir)
|
||||
@@ -57,7 +88,6 @@ obj/structure/transit_tube/ex_act(severity)
|
||||
/obj/structure/transit_tube/proc/pod_stopped(pod, from_dir)
|
||||
return
|
||||
|
||||
|
||||
// Returns a /list of directions this tube section can connect to.
|
||||
// Tubes that have some sort of logic or changing direction might
|
||||
// override it with additional logic.
|
||||
@@ -258,53 +288,3 @@ obj/structure/transit_tube/ex_act(severity)
|
||||
|
||||
direction_table[text] = directions
|
||||
return directions
|
||||
|
||||
|
||||
|
||||
// A copy of text2dir, extended to accept one and two letter
|
||||
// directions, and to clearly return 0 otherwise.
|
||||
/obj/structure/transit_tube/proc/text2dir_extended(direction)
|
||||
switch(uppertext(direction))
|
||||
if("NORTH", "N")
|
||||
return 1
|
||||
if("SOUTH", "S")
|
||||
return 2
|
||||
if("EAST", "E")
|
||||
return 4
|
||||
if("WEST", "W")
|
||||
return 8
|
||||
if("NORTHEAST", "NE")
|
||||
return 5
|
||||
if("NORTHWEST", "NW")
|
||||
return 9
|
||||
if("SOUTHEAST", "SE")
|
||||
return 6
|
||||
if("SOUTHWEST", "SW")
|
||||
return 10
|
||||
else
|
||||
return 0
|
||||
|
||||
|
||||
|
||||
// A copy of dir2text, which returns the short one or two letter
|
||||
// directions used in tube icon states.
|
||||
/obj/structure/transit_tube/proc/dir2text_short(direction)
|
||||
switch(direction)
|
||||
if(1)
|
||||
return "N"
|
||||
if(2)
|
||||
return "S"
|
||||
if(4)
|
||||
return "E"
|
||||
if(8)
|
||||
return "W"
|
||||
if(5)
|
||||
return "NE"
|
||||
if(6)
|
||||
return "SE"
|
||||
if(9)
|
||||
return "NW"
|
||||
if(10)
|
||||
return "SW"
|
||||
else
|
||||
return
|
||||
|
||||
@@ -0,0 +1,132 @@
|
||||
// transit tube construction
|
||||
|
||||
// normal transit tubes
|
||||
/obj/structure/c_transit_tube
|
||||
name = "unattached transit tube"
|
||||
icon = 'icons/obj/pipes/transit_tube.dmi'
|
||||
icon_state = "E-W" //icon_state decides which tube will be built
|
||||
density = 0
|
||||
layer = 3.1 //same as the built tube
|
||||
anchored = 0.0
|
||||
|
||||
//wrapper for turn that changes the transit tube formatted icon_state instead of the dir
|
||||
/obj/structure/c_transit_tube/proc/tube_turn(var/angle)
|
||||
var/list/badtubes = list("W-E", "W-E-Pass", "S-N", "S-N-Pass", "SW-NE", "SE-NW")
|
||||
var/list/split_text = text2list(icon_state, "-")
|
||||
for(var/i=1; i<=split_text.len; i++)
|
||||
var/curdir = text2dir_extended(split_text[i]) //0 if not a valid direction (e.g. Pass, Block)
|
||||
if(curdir)
|
||||
split_text[i] = dir2text_short(turn(curdir, angle))
|
||||
var/newdir = list2text(split_text, "-")
|
||||
if(badtubes.Find(newdir))
|
||||
split_text.Swap(1,2)
|
||||
newdir = list2text(split_text, "-")
|
||||
icon_state = newdir
|
||||
|
||||
/obj/structure/c_transit_tube/proc/tube_flip()
|
||||
var/list/split_text = text2list(icon_state, "-")
|
||||
//skip straight pipes
|
||||
if(length(split_text[2]) < 2)
|
||||
return
|
||||
//for junctions, just swap the diagonals with each other
|
||||
if(split_text.len == 3 && split_text[3] != "Pass")
|
||||
split_text.Swap(2,3)
|
||||
//for curves, swap the diagonal direction that is not in the same axis as the cardinal direction
|
||||
else
|
||||
if(split_text[1] == "N" || split_text[1] == "S")
|
||||
split_text[2] = copytext(split_text[2],1,2) + ((copytext(split_text[2],2,3) == "E") ? "W" : "E")
|
||||
else
|
||||
split_text[2] = ((copytext(split_text[2],1,2) == "N") ? "S" : "N") + copytext(split_text[2],2,3)
|
||||
icon_state = list2text(split_text, "-")
|
||||
|
||||
// disposals-style flip and rotate verbs
|
||||
/obj/structure/c_transit_tube/verb/rotate()
|
||||
set name = "Rotate Tube"
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
if(usr.canUseTopic())
|
||||
return
|
||||
|
||||
tube_turn(-90)
|
||||
|
||||
/obj/structure/c_transit_tube/verb/flip()
|
||||
set name = "Flip"
|
||||
set category = "Object"
|
||||
set src in view(1)
|
||||
|
||||
if(usr.canUseTopic())
|
||||
return
|
||||
|
||||
tube_flip()
|
||||
|
||||
/obj/structure/c_transit_tube/proc/buildtube()
|
||||
var/obj/structure/transit_tube/R = new/obj/structure/transit_tube(src.loc)
|
||||
R.icon_state = src.icon_state
|
||||
R.init_dirs()
|
||||
R.generate_automatic_corners(R.tube_dirs)
|
||||
return R
|
||||
|
||||
/obj/structure/c_transit_tube/attackby(var/obj/item/I, var/mob/user)
|
||||
if(istype(I, /obj/item/weapon/wrench))
|
||||
user << "<span class='notice'>You start attaching the [name]...</span>"
|
||||
src.add_fingerprint(user)
|
||||
if(do_after(user, 40))
|
||||
if(!src) return
|
||||
user << "<span class='notice'>You attach the [name]!</span>"
|
||||
var/obj/structure/transit_tube/R = src.buildtube()
|
||||
src.transfer_fingerprints_to(R)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
// transit tube station
|
||||
/obj/structure/c_transit_tube/station
|
||||
name = "unattached through station"
|
||||
icon = 'icons/obj/pipes/transit_tube_station.dmi'
|
||||
icon_state = "closed"
|
||||
|
||||
/obj/structure/c_transit_tube/station/tube_turn(var/angle)
|
||||
src.dir = turn(src.dir, angle)
|
||||
|
||||
/obj/structure/c_transit_tube/station/tube_flip()
|
||||
src.tube_turn(180)
|
||||
|
||||
/obj/structure/c_transit_tube/station/buildtube()
|
||||
var/obj/structure/transit_tube/station/R = new/obj/structure/transit_tube/station(src.loc)
|
||||
R.dir = src.dir
|
||||
R.init_dirs()
|
||||
return R
|
||||
|
||||
// reverser station, used for the terminus
|
||||
/obj/structure/c_transit_tube/station/reverse
|
||||
name = "unattached terminus station"
|
||||
|
||||
/obj/structure/c_transit_tube/station/reverse/buildtube()
|
||||
var/obj/structure/transit_tube/station/reverse/R = new/obj/structure/transit_tube/station/reverse(src.loc)
|
||||
R.dir = src.dir
|
||||
R.init_dirs()
|
||||
return R
|
||||
|
||||
// block, used after the terminus of a transit tube station, decorative only
|
||||
// code-wise they're normal tubes but they're ~speshul~ because they care about the dir instead of the icon_state
|
||||
// in that sense they're the same as stations and can reuse their flip and rotate verbs
|
||||
/obj/structure/c_transit_tube/station/block
|
||||
name = "unattached tube blocker"
|
||||
icon = 'icons/obj/pipes/transit_tube.dmi'
|
||||
icon_state = "Block"
|
||||
|
||||
/obj/structure/c_transit_tube/station/block/buildtube()
|
||||
var/obj/structure/transit_tube/R = new/obj/structure/transit_tube(src.loc)
|
||||
R.icon_state = src.icon_state
|
||||
R.dir = src.dir
|
||||
R.init_dirs()
|
||||
return R
|
||||
|
||||
//transit tube pod
|
||||
//see station.dm for the logic
|
||||
/obj/structure/c_transit_tube_pod
|
||||
name = "unattached transit tube pod"
|
||||
icon = 'icons/obj/pipes/transit_tube_pod.dmi'
|
||||
icon_state = "pod"
|
||||
anchored = 0.0
|
||||
density = 0
|
||||
@@ -25,6 +25,23 @@
|
||||
|
||||
..()
|
||||
|
||||
/obj/structure/transit_tube_pod/attackby(var/obj/item/I, var/mob/user)
|
||||
if(istype(I, /obj/item/weapon/crowbar))
|
||||
if(!moving)
|
||||
for(var/obj/structure/transit_tube/station/T in loc)
|
||||
return
|
||||
if(src.contents)
|
||||
user.visible_message("<span class='notice'>[user] empties the [src].</span>", "<span class='notice'>You empty the [src].</span>")
|
||||
for(var/atom/movable/M in src.contents)
|
||||
M.loc = src.loc
|
||||
return
|
||||
else
|
||||
user << "<span class='notice'>You free the [src].</span>"
|
||||
var/obj/structure/c_transit_tube_pod/R = new/obj/structure/c_transit_tube_pod(src.loc)
|
||||
src.transfer_fingerprints_to(R)
|
||||
R.add_fingerprint(user)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/transit_tube_pod/proc/follow_tube(var/reverse_launch)
|
||||
if(moving)
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user