mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2026-08-30 08:38:13 +01:00
Drakes and kururak will now threaten before attacking.
This commit is contained in:
@@ -34,8 +34,9 @@
|
||||
|
||||
if(holder.say_list)
|
||||
holder.ISay(safepick(holder.say_list.say_threaten))
|
||||
playsound(holder, holder.say_list.threaten_sound, 50, 1) // We do this twice to make the sound -very- noticeable to the target.
|
||||
playsound(target, holder.say_list.threaten_sound, 50, 1) // Actual aim-mode also does that so at least it's consistent.
|
||||
if(holder.say_list.threaten_sound)
|
||||
playsound(holder, holder.say_list.threaten_sound, 50, 1) // We do this twice to make the sound -very- noticeable to the target.
|
||||
playsound(target, holder.say_list.threaten_sound, 50, 1) // Actual aim-mode also does that so at least it's consistent.
|
||||
else // Otherwise we are waiting for them to go away or to wait long enough for escalate.
|
||||
if(target in list_targets()) // Are they still visible?
|
||||
var/should_escalate = FALSE
|
||||
@@ -48,6 +49,10 @@
|
||||
set_stance(STANCE_APPROACH)
|
||||
if(holder.say_list)
|
||||
holder.ISay(safepick(holder.say_list.say_escalate))
|
||||
if(holder.say_list.attack_sound)
|
||||
// As per threaten_sound above.
|
||||
playsound(holder, holder.say_list.attack_sound, 50, 1)
|
||||
playsound(target, holder.say_list.attack_sound, 50, 1)
|
||||
else
|
||||
return // Wait a bit.
|
||||
|
||||
@@ -57,8 +62,10 @@
|
||||
set_stance(STANCE_IDLE)
|
||||
if(holder.say_list)
|
||||
holder.ISay(safepick(holder.say_list.say_stand_down))
|
||||
playsound(holder, holder.say_list.stand_down_sound, 50, 1) // We do this twice to make the sound -very- noticeable to the target.
|
||||
playsound(target, holder.say_list.stand_down_sound, 50, 1) // Actual aim-mode also does that so at least it's consistent.
|
||||
if(holder.say_list.stand_down_sound)
|
||||
// As per threaten_sound above.
|
||||
playsound(holder, holder.say_list.stand_down_sound, 50, 1)
|
||||
playsound(target, holder.say_list.stand_down_sound, 50, 1)
|
||||
|
||||
// Determines what is deserving of a warning when STANCE_ALERT is active.
|
||||
/datum/ai_holder/proc/will_threaten(mob/living/the_target)
|
||||
|
||||
@@ -86,4 +86,3 @@
|
||||
path_display = TRUE
|
||||
last_turf_display = TRUE
|
||||
debug_ai = AI_LOG_INFO
|
||||
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
|
||||
var/threaten_sound = null // Sound file played when the mob's AI calls threaten_target() for the first time.
|
||||
var/stand_down_sound = null // Sound file played when the mob's AI loses sight of the threatened target.
|
||||
var/attack_sound = null // Sound file played when the mob's AI escalates to attacking from threatening.
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -52,14 +52,16 @@
|
||||
ai_holder.hostile = TRUE
|
||||
|
||||
/datum/ai_holder/simple_mob/intentional/grafadreka
|
||||
hostile = TRUE
|
||||
retaliate = TRUE
|
||||
cooperative = TRUE
|
||||
can_flee = TRUE
|
||||
flee_when_dying = TRUE
|
||||
home_low_priority = TRUE
|
||||
intelligence_level = AI_SMART
|
||||
hostile = TRUE
|
||||
retaliate = TRUE
|
||||
cooperative = TRUE
|
||||
can_flee = TRUE
|
||||
flee_when_dying = TRUE
|
||||
home_low_priority = TRUE
|
||||
threaten = TRUE
|
||||
var/next_food_check = 0
|
||||
var/next_sap_check = 0
|
||||
var/next_sap_check = 0
|
||||
var/next_heal_check = 0
|
||||
|
||||
/datum/ai_holder/simple_mob/intentional/grafadreka/should_flee(force)
|
||||
|
||||
+14
-3
@@ -43,10 +43,21 @@ Field studies suggest analytical abilities on par with some species of cepholapo
|
||||
|
||||
|
||||
/datum/say_list/grafadreka
|
||||
speak = list("Chff!", "Skhh.", "Rrrss...")
|
||||
emote_see = list("scratches its ears","grooms its spines", "sways its tail", "claws at the ground")
|
||||
emote_hear = list("hisses", "rattles", "rasps", "barks", "warbles")
|
||||
speak = list("Chff!", "Skhh.", "Rrrss...")
|
||||
emote_see = list("scratches its ears","grooms its spines", "sways its tail", "claws at the ground")
|
||||
emote_hear = list("hisses", "rattles", "rasps", "barks", "warbles")
|
||||
say_understood = list("Rrrn!", "Hsst!")
|
||||
say_cannot = list("Gruwwrrn...")
|
||||
say_maybe_target = list("Chh?")
|
||||
say_got_target = list("RRSST!")
|
||||
say_threaten = list("Rrrrnrrnnn...", "Chssshhhk...")
|
||||
say_stand_down = list("Chff!")
|
||||
say_escalate = list("SKHH!", "CHFF!")
|
||||
say_retreat = list("Skhh!", "Chff!")
|
||||
|
||||
threaten_sound = 'sound/voice/drakes/drake_warn.ogg'
|
||||
attack_sound = 'sound/voice/drakes/drake_rattle.ogg'
|
||||
stand_down_sound = 'sound/voice/drakes/drake_grumble.ogg'
|
||||
|
||||
/decl/mob_organ_names/grafadreka
|
||||
hit_zones = list(
|
||||
|
||||
@@ -88,6 +88,15 @@
|
||||
emote_see = list("scratches its ear","flutters its tails", "flicks an ear", "shakes out its hair")
|
||||
emote_hear = list("chirps", "clicks", "grumbles", "chitters")
|
||||
|
||||
say_understood = list("Kurr...", "Ksss...")
|
||||
say_cannot = list("Kurr...", "Ksss...")
|
||||
say_maybe_target = list("Kurr?", "Ksss?")
|
||||
say_got_target = list("Kurr!", "Ksss!")
|
||||
say_threaten = list("Kurr...", "Ksss...")
|
||||
say_stand_down = list("Kurr!", "Ksss!")
|
||||
say_escalate = list("KURR!", "KSSS!")
|
||||
say_retreat = list("KURR!", "KSSS!")
|
||||
|
||||
/mob/living/simple_mob/animal/sif/kururak/leader // Going to be the starting leader. Has some base buffs to make it more likely to stay the leader.
|
||||
maxHealth = 250
|
||||
health = 250
|
||||
@@ -342,16 +351,16 @@
|
||||
*/
|
||||
|
||||
/datum/ai_holder/simple_mob/intentional/kururak
|
||||
hostile = FALSE
|
||||
retaliate = TRUE
|
||||
cooperative = TRUE
|
||||
can_flee = TRUE
|
||||
hostile = FALSE
|
||||
retaliate = TRUE
|
||||
cooperative = TRUE
|
||||
can_flee = TRUE
|
||||
flee_when_dying = TRUE
|
||||
threaten = TRUE
|
||||
|
||||
/datum/ai_holder/simple_mob/intentional/kururak/handle_special_strategical()
|
||||
follow_distance = rand(initial(follow_distance), initial(follow_distance) + 2)
|
||||
var/mob/living/simple_mob/animal/sif/kururak/K = holder
|
||||
|
||||
if(istype(K))
|
||||
var/mob/living/simple_mob/animal/sif/kururak/highest_instinct = K.detect_instinct()
|
||||
if(highest_instinct == K)
|
||||
|
||||
Reference in New Issue
Block a user