memories are no longer added if the target isn't aware of them. (#61375)

Fixing an oversight with the memories system. Memories shouldn't be added to people who aren't possibly aware of them.
This commit is contained in:
Ghom
2021-09-20 23:39:37 +02:00
committed by GitHub
parent 57ac5b649f
commit a2d6c75f31
13 changed files with 42 additions and 17 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ GLOBAL_LIST_INIT(creamable, typecacheof(list(
SEND_SIGNAL(parent, COMSIG_MOB_CREAMED)
add_memory_in_range(parent, 7, MEMORY_CREAMPIED, list(DETAIL_PROTAGONIST = parent), story_value = STORY_VALUE_OKAY)
add_memory_in_range(parent, 7, MEMORY_CREAMPIED, list(DETAIL_PROTAGONIST = parent), story_value = STORY_VALUE_OKAY, memory_flags = MEMORY_CHECK_BLINDNESS, protagonist_memory_flags = NONE)
creamface = mutable_appearance('icons/effects/creampie.dmi')
+1 -1
View File
@@ -40,7 +40,7 @@
shooter.visible_message(span_danger("[shooter] aims [weapon] point blank at [target]!"), \
span_danger("You aim [weapon] point blank at [target]!"), ignored_mobs = target)
to_chat(target, span_userdanger("[shooter] aims [weapon] point blank at you!"))
add_memory_in_range(target, 7, MEMORY_GUNPOINT, list(DETAIL_PROTAGONIST = target, DETAIL_DEUTERAGONIST = shooter, DETAIL_WHAT_BY = weapon), story_value = STORY_VALUE_OKAY)
add_memory_in_range(target, 7, MEMORY_GUNPOINT, list(DETAIL_PROTAGONIST = target, DETAIL_DEUTERAGONIST = shooter, DETAIL_WHAT_BY = weapon), story_value = STORY_VALUE_OKAY, memory_flags = MEMORY_CHECK_BLINDNESS)
shooter.apply_status_effect(STATUS_EFFECT_HOLDUP, shooter)
target.apply_status_effect(STATUS_EFFECT_HELDUP, shooter)
+1 -1
View File
@@ -68,4 +68,4 @@
if(dropsound)
playsound(master, pick(dropsound), 30)
if(drop_memory)
fool.mind?.add_memory(MEMORY_SPAGHETTI_SPILL, list(DETAIL_PROTAGONIST = fool), story_value = STORY_VALUE_OKAY)
fool.mind?.add_memory(MEMORY_SPAGHETTI_SPILL, list(DETAIL_PROTAGONIST = fool), story_value = STORY_VALUE_OKAY, memory_flags = MEMORY_CHECK_BLINDNESS)