Files
Paradise/code/game/objects/alien/weeds.dm
johnsonmt88@gmail.com c930622bea Attack verbs!
Instead of 'x has been attacked with y by z' it now reads 'x has been 'y.attack_verb-ed' with y by z'!
Example:
Monkeyman has been bashed in the head with a riot shield by Nodrak!
or
Monkeyman has been stabbed in the chest with an energy sword by Nodrak!

- Every obj now has a list named "attack_verbs"
- When declaring an object, just use attack_verb = list("verb1", "verb2") and so on to initialize the list for that specific item.
- I've added a bunch of these to a ton of items already, feel free to modify or add more. Just try to stay away from gimmicky verbs (clown stuff being the exception.)

clothing.dm and spawner.dm only had a single definition in each of them, so their definitins have been moved to obj.dm and their original dm files deleted. I'm not sure about spawner but clothing had all of its other definitions removed recently.

radio.dm was a completely blank file, so it was removed.

Changelog updated

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@4182 316c924e-a436-60f5-8080-3fe189b3f50e
2012-07-26 05:21:24 +00:00

108 lines
2.3 KiB
Plaintext

#define NODERANGE 3
/obj/effect/alien/weeds/New()
..()
if(istype(loc, /turf/space))
del(src)
return
if(icon_state == "weeds")icon_state = pick("weeds", "weeds1", "weeds2")
spawn(rand(150,300))
if(src)
Life()
return
/obj/effect/alien/weeds/node/New()
..()
sd_SetLuminosity(NODERANGE)
return
/obj/effect/alien/weeds/proc/Life()
set background = 1
var/turf/U = get_turf(src)
/*
if (locate(/obj/movable, U))
U = locate(/obj/movable, U)
if(U.density == 1)
del(src)
return
Alien plants should do something if theres a lot of poison
if(U.poison> 200000)
health -= round(U.poison/200000)
update()
return
*/
if (istype(U, /turf/space))
del(src)
return
direction_loop:
for(var/dirn in cardinal)
var/turf/T = get_step(src, dirn)
if (!istype(T) || T.density || locate(/obj/effect/alien/weeds) in T || istype(T.loc, /area/arrival) || istype(T, /turf/space))
continue
if(!(locate(/obj/effect/alien/weeds/node) in view(NODERANGE,T)))
continue
// if (locate(/obj/movable, T)) // don't propogate into movables
// continue
for(var/obj/O in T)
if(O.density)
continue direction_loop
new /obj/effect/alien/weeds(T)
/obj/effect/alien/weeds/ex_act(severity)
switch(severity)
if(1.0)
del(src)
if(2.0)
if (prob(50))
del(src)
if(3.0)
if (prob(5))
del(src)
return
/obj/effect/alien/weeds/attackby(var/obj/item/weapon/W, var/mob/user)
if(W.attack_verb.len)
visible_message("\red <B>\The [src] have been [pick(W.attack_verb)] with \the [W][(user ? " by [user]." : ".")]")
else
visible_message("\red <B>\The [src] have been attacked with \the [W][(user ? " by [user]." : ".")]")
var/damage = W.force / 4.0
if(istype(W, /obj/item/weapon/weldingtool))
var/obj/item/weapon/weldingtool/WT = W
if(WT.remove_fuel(0, user))
damage = 15
playsound(loc, 'Welder.ogg', 100, 1)
health -= damage
healthcheck()
/obj/effect/alien/weeds/proc/healthcheck()
if(health <= 0)
del(src)
/obj/effect/alien/weeds/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
if(exposed_temperature > 300)
health -= 5
healthcheck()
/*/obj/effect/alien/weeds/burn(fi_amount)
if (fi_amount > 18000)
spawn( 0 )
del(src)
return
return 0
return 1
*/
#undef NODRANGE