Files
kiwistation/code/modules/events/sentience.dm
T
coiax 18647dd3d6 Added "Sentience" rare random event (#22007)
* Added "Sentience" rare random event

🆑 coiax
add: Due to a combination of radiation and water supply contamination,
stations have been reporting animals gaining self awareness.
/🆑

Picks a random /mob/living/simple_animal on station that has no mind,
and gives it to a ghost who signs up, along with giving them a decent
chunk of health so they don't die instantly.

Note that this does include bots, which I've kept because it's hilarious
that the Mulebot spontaneously develops opinions.

Cockroaches now take 1 damage when stepped on, enough to kill a normal
cockroach, but not enough to kill a sentient one.

* Changed min() to max()

* Changed lore to appease Cheridan
2016-12-10 10:04:56 +13:00

43 lines
1.3 KiB
Plaintext

/datum/round_event_control/sentience
name = "Random Human-level Intelligence"
typepath = /datum/round_event/ghost_role/sentience
weight = 5
/datum/round_event/ghost_role/sentience
minimum_required = 1
role_name = "random animal"
/datum/round_event/ghost_role/sentience/spawn_role()
var/list/mob/dead/observer/candidates
candidates = get_candidates(ROLE_ALIEN, null, ROLE_ALIEN)
// find our chosen mob to breathe life into
// Mobs have to be simple animals, mindless and on station
var/list/potential = list()
for(var/mob/living/simple_animal/L in living_mob_list)
var/turf/T = get_turf(L)
if(T.z != ZLEVEL_STATION)
continue
if(!(L in player_list) && !L.mind)
potential += L
var/mob/living/simple_animal/SA = pick(potential)
var/mob/dead/observer/SG = pick(candidates)
if(!SA || !SG)
return FALSE
SA.key = SG.key
SA.languages_spoken |= HUMAN
SA.languages_understood |= HUMAN
SA.sentience_act()
SA.maxHealth = max(SA.maxHealth, 200)
SA.health = SA.maxHealth
SA.del_on_death = FALSE
SA << "<span class='userdanger'>Hello world!</span>"
SA << "<span class='warning'>Due to freak radiation and/or chemicals \
and/or lucky chance, you have gained human level intelligence \
and the ability to speak and understand human language!</span>"