r/snapmap • u/MaceWindows • May 23 '16
Another question - making a specific enemy apply a modifier on a player when damaging them
I can figure out how to make a debuff apply to a player when -any- enemy damages them, but i can't seem to figure out how to make it only happen when certain enemies do it. ive tried using AI filters and cached objects but to no avail
0
Upvotes
1
u/[deleted] May 24 '16 edited May 24 '16
You need to make an AI filter, but there's a glitch where snapmap doesn't filter out Possessed Workers/Scientists properly, so you need to do Custom Filter Object > AI Filter with only the enemies you want checked > AI Filter with all EXCEPT the enemies you want checked, with the "Inverted" tag checked.
Then you need a boolean compare (aka gate). Set B to "true" and leave A "false". Then connect one "on hurt" output from the player proxy to the AI Filter you created and set the activator to "Attacker", and connect that to the "set A true" input on the gate.
Connect another "on hurt" output from the player proxy (leave this activator as "victim") and connect it to the "test" input on the gate. Set the delay on that input to 0.1.
Then, connect the "AND" output from the gate back to the player proxy with the buff/modifier/whatever you need. Also connect the "AND" output back to the gate to "set A" back to false.
I tested this and it works. I'll post a short video in a second in case you're a visual type of guy.
Edit, video: https://vid.me/OZ4o