mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-28 23:51:17 +01:00
Mousetrap, mouse and spawning fixes (#1497)
Adjusts mousetraps a bit. So they'll be triggered by all mobs instead of only humans, and trigger when walked on. Also nerfs the instastun that comes from stepping on them without shoes, because that's pretty broken against giant monsters like vaurca breeders. applies halloss instead based on mob size. Smaller things get hurt more. Fixes #1445 Fixes #1449 Fixes #1450
This commit is contained in:
@@ -465,12 +465,12 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if(config.disable_player_mice)
|
||||
src << "<span class='warning'>Spawning as a mouse is currently disabled.</span>"
|
||||
return
|
||||
|
||||
|
||||
if(ticker.current_state < GAME_STATE_PLAYING)
|
||||
src << "<span class='warning'>You can not spawn as a mouse before round start!</span>"
|
||||
return
|
||||
|
||||
if(!MayRespawn(1, ANIMAL_SPAWN_DELAY))
|
||||
|
||||
if(!MayRespawn(1, ANIMAL))
|
||||
return
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
@@ -815,7 +815,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if (ghostimage)
|
||||
client.images -= ghostimage //remove ourself
|
||||
|
||||
mob/dead/observer/MayRespawn(var/feedback = 0, var/respawn_time = 0)
|
||||
mob/dead/observer/MayRespawn(var/feedback = 0, var/respawn_type = null)
|
||||
if(!client)
|
||||
return 0
|
||||
if(config.antag_hud_restricted && has_enabled_antagHUD == 1)
|
||||
@@ -823,10 +823,21 @@ mob/dead/observer/MayRespawn(var/feedback = 0, var/respawn_time = 0)
|
||||
src << "<span class='warning'>antagHUD restrictions prevent you from respawning.</span>"
|
||||
return 0
|
||||
|
||||
var/timedifference = world.time - timeofdeath
|
||||
if(respawn_time && timeofdeath && timedifference < respawn_time MINUTES)
|
||||
var/timedifference_text = time2text(respawn_time MINUTES - timedifference,"mm:ss")
|
||||
src << "<span class='warning'>You must have been dead for [respawn_time] minute\s to respawn. You have [timedifference_text] left.</span>"
|
||||
if (respawn_type)
|
||||
var/timedifference = world.time- get_death_time(respawn_type)
|
||||
var/respawn_time = 0
|
||||
if (respawn_type == CREW)
|
||||
respawn_time = config.respawn_delay *600
|
||||
else if (respawn_type == ANIMAL)
|
||||
respawn_time = RESPAWN_ANIMAL
|
||||
else if (respawn_type == MINISYNTH)
|
||||
respawn_time = RESPAWN_MINISYNTH
|
||||
|
||||
if (respawn_time && timedifference >= respawn_time)
|
||||
return 1
|
||||
else if (feedback)
|
||||
var/timedifference_text = time2text(respawn_time - timedifference,"mm:ss")
|
||||
src << "<span class='warning'>You must have been dead for [respawn_time/600] minute\s to respawn. You have [timedifference_text] left.</span>"
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
Reference in New Issue
Block a user