mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
Implement toxic farts.
This commit is contained in:
@@ -491,6 +491,34 @@ steam.start() -- spawns the effect
|
||||
if(smoke) smoke.delete()
|
||||
src.total_smoke--
|
||||
|
||||
// Goon compat.
|
||||
/datum/effect/effect/system/smoke_spread/chem/fart
|
||||
set_up(var/mob/M, n = 5, c = 0, loca, direct)
|
||||
if(n > 20)
|
||||
n = 20
|
||||
number = n
|
||||
cardinals = c
|
||||
|
||||
chemholder.reagents.add_reagent("mercury", 50)
|
||||
|
||||
if(istype(loca, /turf/))
|
||||
location = loca
|
||||
else
|
||||
location = get_turf(loca)
|
||||
if(direct)
|
||||
direction = direct
|
||||
|
||||
var/contained = "\[[chemholder.reagents.get_reagent_ids()]\]"
|
||||
var/area/A = get_area(location)
|
||||
|
||||
var/where = "[A.name] | [location.x], [location.y]"
|
||||
var/whereLink=formatJumpTo(location,where)
|
||||
|
||||
var/more = "(<A HREF='?_src_=holder;adminmoreinfo=\ref[M]'>?</a>)"
|
||||
message_admins("[M][more] produced a toxic fart in ([whereLink])[contained].", 0, 1)
|
||||
log_game("[M][more] produced a toxic fart in ([where])[contained].")
|
||||
|
||||
|
||||
/////////////////////////////////////////////
|
||||
//////// Attach an Ion trail to any object, that spawns when it moves (like for the jetpack)
|
||||
/// just pass in the object to attach it to in set_up
|
||||
|
||||
@@ -539,6 +539,32 @@
|
||||
message = "<B>[src]</B> makes a very loud noise."
|
||||
m_type = 2
|
||||
|
||||
// Needed for M_TOXIC_FART
|
||||
if("fart")
|
||||
if(world.time-lastFart >= 600)
|
||||
message = "<b>[src]</b> [pick("passes wind","farts")]."
|
||||
m_type = 2
|
||||
var/location = get_turf(src)
|
||||
playsound(location, 'sound/effects/smoke.ogg', 50, 1, -3)
|
||||
if(M_TOXIC_FARTS in mutations)
|
||||
if(wear_suit && wear_suit.body_parts_covered & LOWER_TORSO)
|
||||
if (internal != null && wear_mask && (wear_mask.flags & MASKINTERNALS))
|
||||
return
|
||||
src << "\red You gas yourself!"
|
||||
reagents.add_reagent("mercury", rand(10,20))
|
||||
return
|
||||
var/datum/effect/effect/system/smoke_spread/chem/fart/S = new /datum/effect/effect/system/smoke_spread/chem/fart
|
||||
S.attach(location)
|
||||
S.set_up(src, 10, 0, location)
|
||||
spawn(0)
|
||||
S.start()
|
||||
sleep(10)
|
||||
S.start()
|
||||
lastFart=world.time
|
||||
else
|
||||
message = "<b>[src]</b> strains, and nothing happens."
|
||||
m_type = 1
|
||||
|
||||
if ("help")
|
||||
src << "blink, blink_r, blush, bow-(none)/mob, burp, choke, chuckle, clap, collapse, cough,\ncry, custom, deathgasp, drool, eyebrow, frown, gasp, giggle, groan, grumble, handshake, hug-(none)/mob, glare-(none)/mob,\ngrin, laugh, look-(none)/mob, moan, mumble, nod, pale, point-atom, raise, salute, shake, shiver, shrug,\nsigh, signal-#1-10, smile, sneeze, sniff, snore, stare-(none)/mob, tremble, twitch, twitch_s, whimper,\nwink, yawn"
|
||||
|
||||
|
||||
@@ -61,4 +61,6 @@
|
||||
|
||||
var/meatleft = 3 //For chef item
|
||||
|
||||
var/check_mutations=0 // Check mutations on next life tick
|
||||
var/check_mutations=0 // Check mutations on next life tick
|
||||
|
||||
var/lastFart = 0 // Toxic fart cooldown.
|
||||
Reference in New Issue
Block a user