Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes giant lizard code breaking when disarmed, and adds some minor features to the mob #7025

Merged
merged 22 commits into from
Oct 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
57ec629
fix disarm bug
VileBeggar Aug 24, 2024
2bd082a
stops the lizards from resting after moving
VileBeggar Aug 25, 2024
d104c0a
adds structure destruction, fixes mob moving while still knocked down…
VileBeggar Aug 25, 2024
466e13d
fix comment typo
VileBeggar Aug 25, 2024
cfe7001
stops message spam when eating from allied hands
VileBeggar Aug 25, 2024
8cb05b2
switch between targets if original target is far away
VileBeggar Aug 25, 2024
9017f71
add latespawn lizards
VileBeggar Aug 25, 2024
bf15f35
stops pouncing from hurting own friends, now eats all meat products
VileBeggar Aug 26, 2024
466e3be
fix paralyze bug #2, increase damage against xenos, add tamable var
VileBeggar Aug 26, 2024
a2771a8
replace random number with max attack distance
VileBeggar Aug 26, 2024
6410767
adds wounds overlay, tongue flicks, lowers latespawn
VileBeggar Aug 27, 2024
3ed1423
fix (and slightly unoptimize) tongue flicker offsets
VileBeggar Aug 27, 2024
750f1a8
increase latespawn chance again
VileBeggar Aug 28, 2024
b074b3a
lower the maximum though
VileBeggar Aug 28, 2024
6d1ff12
add resin door breaking
VileBeggar Aug 28, 2024
2ff99d0
fix pred taming
VileBeggar Aug 29, 2024
0fb4b45
fix sound being made when set on fire and dead
VileBeggar Aug 31, 2024
023f225
add client food eating
VileBeggar Sep 3, 2024
4700f1a
potentially fixes permastunned
VileBeggar Sep 6, 2024
66255d4
Merge branch 'master' into jagras-fix-thing
VileBeggar Sep 14, 2024
4b7fc3c
remove nasty moveto check, stop ravaging attack when prone
VileBeggar Sep 16, 2024
3188c6b
Apply suggestions from code review
VileBeggar Oct 9, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions code/__DEFINES/mode.dm
Original file line number Diff line number Diff line change
Expand Up @@ -295,6 +295,7 @@ DEFINE_BITFIELD(whitelist_status, list(
#define FACTION_LIST_MARINE_WY list(FACTION_MARINE, FACTION_PMC, FACTION_WY_DEATHSQUAD, FACTION_WY)
#define FACTION_LIST_MARINE_UPP list(FACTION_MARINE, FACTION_UPP)
#define FACTION_LIST_MARINE_TWE list(FACTION_MARINE, FACTION_TWE)
#define FACTION_LIST_YAUTJA list(FACTION_YAUTJA)

// Xenomorphs
#define FACTION_PREDALIEN "Predalien"
Expand Down
3 changes: 3 additions & 0 deletions code/_globalvars/misc.dm
Original file line number Diff line number Diff line change
Expand Up @@ -135,3 +135,6 @@ GLOBAL_VAR(xeno_queue_candidate_count)
GLOBAL_VAR(obfs_x)
/// A number between -500 and 500.
GLOBAL_VAR(obfs_y)

/// The current amount of giant lizards that are alive.
GLOBAL_VAR_INIT(giant_lizards_alive, 0)
1 change: 1 addition & 0 deletions code/game/gamemodes/cm_initialize.dm
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ Additional game mode variables.
player.mind_initialize() //Will work on ghosts too, but won't add them to active minds.
player.mind.setup_human_stats()
player.faction = FACTION_YAUTJA
player.faction_group = FACTION_LIST_YAUTJA
players += player.mind
return players

Expand Down
18 changes: 18 additions & 0 deletions code/game/objects/effects/landmarks/landmarks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@
GLOB.monkey_spawns -= src
return ..()

#define MAXIMUM_LIZARD_AMOUNT 4

/obj/effect/landmark/lizard_spawn
name = "lizard spawn"
icon_state = "lizard_spawn"
Expand All @@ -129,6 +131,22 @@
. = ..()
if(prob(66))
new /mob/living/simple_animal/hostile/retaliate/giant_lizard(loc)
addtimer(CALLBACK(src, PROC_REF(latespawn_lizard)), rand(35 MINUTES, 50 MINUTES))

/obj/effect/landmark/lizard_spawn/proc/latespawn_lizard()
//if there's already a ton of lizards alive, try again later
if(GLOB.giant_lizards_alive > MAXIMUM_LIZARD_AMOUNT)
addtimer(CALLBACK(src, PROC_REF(latespawn_lizard)), rand(15 MINUTES, 25 MINUTES))
return
//if there's a living mob that can witness the spawn then try again later
for(var/mob/living/living_mob in range(7, src))
if(living_mob.stat != DEAD || living_mob.client)
continue
addtimer(CALLBACK(src, PROC_REF(latespawn_lizard)), 1 MINUTES)
return
new /mob/living/simple_animal/hostile/retaliate/giant_lizard(loc)

#undef MAXIMUM_LIZARD_AMOUNT

/obj/effect/landmark/latewhiskey
name = "Whiskey Outpost Late join"
Expand Down
2 changes: 2 additions & 0 deletions code/modules/gear_presets/yautja.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
languages = list(LANGUAGE_YAUTJA)
rank = "Predator"
faction = FACTION_YAUTJA
faction_group = FACTION_LIST_YAUTJA
uses_special_name = TRUE
skills = /datum/skills/yautja/warrior

Expand All @@ -23,6 +24,7 @@
/datum/equipment_preset/yautja/load_id(mob/living/carbon/human/new_human)
new_human.job = rank
new_human.faction = faction
new_human.faction_group = faction_group

/datum/equipment_preset/yautja/load_vanity(mob/living/carbon/human/new_human)
return //No vanity items for Yautja!
Expand Down
2 changes: 1 addition & 1 deletion code/modules/mob/death.dm
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
return 0

if(!gibbed)
visible_message("<b>\The [src.name]</b> [deathmessage]")
visible_message("<b>[src.name]</b> [deathmessage]")

if(cause_data && !istype(cause_data))
stack_trace("death called with string cause ([cause_data]) instead of datum")
Expand Down
Loading
Loading