Respawn bugfixes

This commit is contained in:
ZomgPonies
2013-11-29 03:14:06 -05:00
parent 6595a67bb8
commit 1b7c889e66
11 changed files with 8150 additions and 8039 deletions
@@ -274,34 +274,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
else
see_invisible = SEE_INVISIBLE_OBSERVER_NOLIGHTING
/mob/dead/observer/verb/become_mouse()
set name = "Become mouse"
set category = "OOC"
var/timedifference = world.time - client.time_died_as_mouse
if(client.time_died_as_mouse && timedifference <= mouse_respawn_time * 600)
var/timedifference_text
timedifference_text = time2text(mouse_respawn_time * 600 - timedifference,"mm:ss")
src << "<span class='warning'>You may only spawn again as a mouse more than [mouse_respawn_time] minutes after your death. You have [timedifference_text] left.</span>"
return
//find a viable mouse candidate
var/mob/living/simple_animal/mouse/host
var/obj/machinery/atmospherics/unary/vent_pump/vent_found
var/list/found_vents = list()
for(var/obj/machinery/atmospherics/unary/vent_pump/v in world)
if(!v.welded && v.z == src.z)
found_vents.Add(v)
if(found_vents.len)
vent_found = pick(found_vents)
host = new /mob/living/simple_animal/mouse(vent_found.loc)
else
src << "<span class='warning'>Unable to find any unwelded vents to spawn mice at.</span>"
if(host)
host.ckey = src.ckey
host << "<span class='info'>You are now a mouse. Try to avoid interaction with players, and do not give hints away that you are more than a simple rodent.</span>"
/mob/dead/observer/verb/view_manfiest()
set name = "View Crew Manifest"
set category = "Ghost"
@@ -5,7 +5,7 @@
if(!gibbed)
if(istype(src, /mob/living/carbon/slime/adult))
ghostize()
// ghostize()
var/mob/living/carbon/slime/M1 = new primarytype(loc)
M1.rabid = 1
var/mob/living/carbon/slime/M2 = new primarytype(loc)
+1 -1
View File
@@ -671,7 +671,7 @@
/mob/living/verb/become_mouse()
/mob/living/proc/become_mouse()
if(usr in respawnable_list)
var/timedifference = world.time - client.time_died_as_mouse
if(client.time_died_as_mouse && timedifference <= mouse_respawn_time * 600)
@@ -0,0 +1,131 @@
/mob/living/carbon/simple_animal/emote(var/act,var/m_type=1,var/message = null)
var/param = null
if (findtext(act, "-", 1, null))
var/t1 = findtext(act, "-", 1, null)
param = copytext(act, t1 + 1, length(act) + 1)
act = copytext(act, 1, t1)
if(findtext(act,"s",-1) && !findtext(act,"_",-2))//Removes ending s's unless they are prefixed with a '_'
act = copytext(act,1,length(act))
var/muzzled = istype(src.wear_mask, /obj/item/clothing/mask/muzzle)
switch(act)
if ("me")
if(silent)
return
if (src.client)
if (client.prefs.muted & MUTE_IC)
src << "\red You cannot send IC messages (muted)."
return
if (src.client.handle_spam_prevention(message,MUTE_IC))
return
if (stat)
return
if(!(message))
return
return custom_emote(m_type, message)
if ("custom")
return custom_emote(m_type, message)
if("sign")
if (!src.restrained())
message = text("<B>The monkey</B> signs[].", (text2num(param) ? text(" the number []", text2num(param)) : null))
m_type = 1
if("scratch")
if (!src.restrained())
message = "<B>The [src.name]</B> scratches."
m_type = 1
if("whimper")
if (!muzzled)
message = "<B>The [src.name]</B> whimpers."
m_type = 2
if("roar")
if (!muzzled)
message = "<B>The [src.name]</B> roars."
m_type = 2
if("tail")
message = "<B>The [src.name]</B> waves his tail."
m_type = 1
if("gasp")
message = "<B>The [src.name]</B> gasps."
m_type = 2
if("shiver")
message = "<B>The [src.name]</B> shivers."
m_type = 2
if("drool")
message = "<B>The [src.name]</B> drools."
m_type = 1
if("paw")
if (!src.restrained())
message = "<B>The [src.name]</B> flails his paw."
m_type = 1
if("scretch")
if (!muzzled)
message = "<B>The [src.name]</B> scretches."
m_type = 2
if("choke")
message = "<B>The [src.name]</B> chokes."
m_type = 2
if("moan")
message = "<B>The [src.name]</B> moans!"
m_type = 2
if("nod")
message = "<B>The [src.name]</B> nods his head."
m_type = 1
if("sit")
message = "<B>The [src.name]</B> sits down."
m_type = 1
if("sway")
message = "<B>The [src.name]</B> sways around dizzily."
m_type = 1
if("sulk")
message = "<B>The [src.name]</B> sulks down sadly."
m_type = 1
if("twitch")
message = "<B>The [src.name]</B> twitches violently."
m_type = 1
if("dance")
if (!src.restrained())
message = "<B>The [src.name]</B> dances around happily."
m_type = 1
if("roll")
if (!src.restrained())
message = "<B>The [src.name]</B> rolls."
m_type = 1
if("shake")
message = "<B>The [src.name]</B> shakes his head."
m_type = 1
if("gnarl")
if (!muzzled)
message = "<B>The [src.name]</B> gnarls and shows his teeth.."
m_type = 2
if("jump")
message = "<B>The [src.name]</B> jumps!"
m_type = 1
if("collapse")
Paralyse(2)
message = text("<B>[]</B> collapses!", src)
m_type = 2
if("deathgasp")
message = "<b>The [src.name]</b> lets out a faint chimper as it collapses and stops moving..."
m_type = 1
if("help")
src << "choke, collapse, dance, deathgasp, drool, gasp, shiver, gnarl, jump, paw, moan, nod, roar, roll, scratch,\nscretch, shake, sign-#, sit, sulk, sway, tail, twitch, whimper"
else
src << text("Invalid Emote: []", act)
if ((message && src.stat == 0))
if(src.client)
log_emote("[name]/[key] : [message]")
if (m_type & 1)
for(var/mob/O in viewers(src, null))
O.show_message(message, m_type)
//Foreach goto(703)
else
for(var/mob/O in hearers(src, null))
O.show_message(message, m_type)
//Foreach goto(746)
return
@@ -15,7 +15,7 @@
var/turns_per_move = 1
var/turns_since_move = 0
universal_speak = 1
universal_speak = 0
var/meat_amount = 0
var/meat_type
var/stop_automated_movement = 0 //Use this to temporarely stop random movement or to if you write special movement code for animals.