-
-
Notifications
You must be signed in to change notification settings - Fork 444
/
Copy pathmining_mobs.dm
75 lines (67 loc) · 2.6 KB
/
mining_mobs.dm
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
//the base mining mob
/mob/living/simple_animal/hostile/asteroid
vision_range = 2
atmos_requirements = list("min_oxy" = 0, "max_oxy" = 0, "min_tox" = 0, "max_tox" = 0, "min_co2" = 0, "max_co2" = 0, "min_n2" = 0, "max_n2" = 0)
faction = list("mining", "skintwister_cloak")
weather_immunities = ALL
obj_damage = 30
environment_smash = ENVIRONMENT_SMASH_WALLS
minbodytemp = 0
maxbodytemp = INFINITY
response_help = "pokes"
response_disarm = "shoves"
response_harm = "strikes"
status_flags = 0
combat_mode = TRUE
// Pale purple, should be red enough to see stuff on lavaland
lighting_cutoff_red = 25
lighting_cutoff_green = 15
lighting_cutoff_blue = 35
mob_size = MOB_SIZE_LARGE
/// If we try to spawn an "empowered" version, what will it spawn
var/alpha_type
var/icon_aggro = null
var/crusher_loot
var/crusher_drop_mod = 25
var/throw_message = "bounces off of"
var/fromtendril = FALSE
/mob/living/simple_animal/hostile/asteroid/Aggro()
..()
if(vision_range == aggro_vision_range && icon_aggro)
icon_state = icon_aggro
/mob/living/simple_animal/hostile/asteroid/LoseAggro()
..()
if(stat == DEAD)
return
icon_state = icon_living
/mob/living/simple_animal/hostile/asteroid/bullet_act(obj/projectile/P)//Reduces damage from most projectiles to curb off-screen kills
if(!stat)
Aggro()
if(P.damage < 30 && P.damage_type != BRUTE)
P.damage = (P.damage / 3)
visible_message(span_danger("[P] has a reduced effect on [src]!"))
..()
/mob/living/simple_animal/hostile/asteroid/hitby(atom/movable/AM, skipcatch, hitpush, blocked, datum/thrownthing/throwingdatum) //No floor tiling them to death, wiseguy
if(istype(AM, /obj/item))
var/obj/item/T = AM
if(!stat)
Aggro()
if(T.throwforce <= 20 && !istype(T, /obj/item/restraints/legcuffs/bola))
visible_message(span_notice("The [T.name] [throw_message] [src.name]!"))
return
..()
/mob/living/simple_animal/hostile/asteroid/sentience_act()
faction -= "mining"
/mob/living/simple_animal/hostile/asteroid/death(gibbed)
SSblackbox.record_feedback("tally", "mobs_killed_mining", 1, type)
var/datum/status_effect/crusher_damage/C = has_status_effect(STATUS_EFFECT_CRUSHERDAMAGETRACKING)
if(C && crusher_loot && prob((C.total_damage/maxHealth) * crusher_drop_mod)) //on average, you'll need to kill 4 creatures before getting the item
spawn_crusher_loot()
..(gibbed)
/mob/living/simple_animal/hostile/asteroid/proc/spawn_crusher_loot()
butcher_results[crusher_loot] = 1
/mob/living/simple_animal/hostile/asteroid/handle_temperature_damage()
if(bodytemperature < minbodytemp)
adjustBruteLoss(2)
else if(bodytemperature > maxbodytemp)
adjustBruteLoss(20)