Closed shawngiese closed 3 years ago
It actually seems like you want a level of complexity / customization that while it would be cool for Sentinel to handle, is possibly more of a place where you'll want to start scripting server-specific logic. I (very biasedly) recommend that you try using Denizen: https://www.spigotmc.org/resources/denizen.21039/ A scripting engine that interacts with Citizens (and as well Sentinel) to enable incredible levels of customization on a server. Denizen, Citizens, and Sentinel share a Discord server if you want to learn more / discuss this option: https://discord.gg/Q6pZGSR
That said, there may be some things that can be added in Sentinel from this idea, that if all added might just about build what you're dreaming up:
/sentinel addtarget player
+ /sentinel addavoid 2xPlayer
, ie attack any player seen, but if there's two players, run away), or perhaps sub-target-lists, like /sentinel addavoid player,helditem:diamond_sword
which adds an avoid for one player AND one player holding a diamond_sword - which would also allow things like addtarget spider,skeleton
which will only attack if BOTH a spider AND a skeleton are around (not that you would generally do that - it's mostly useful for avoidance here I think).event:message:help
activates whenever someone in visual range yells "help!"). And as a natural extension, 'message targets' type of system, which allows you to add a message that an NPC will shout (once or on repeat) when a certain target list is nearby. This could be a "help!" repeating for "2xPlayer" or it might be a "hello, welcome to the town!" once for each player spotted within a few blocks. (Currently that's handled by greeting
system, but the greeting system is very limited in capability)Thanks for considering the new feature... trying to get some more role playing out of the NPCs. I will definitely look at the denizen.
Those possible additions would get pretty close to what I am aiming at... return to spawn event, avoid this / target that mix looks great too. Advanced messaging... well that would be icing on top... especially if you could attach it to an event. For example... player distance 2, message - narrated format "you hear movement nearby" player distance 1, message - "Alert, soldiers!" as lookout runs to camp
I've made some major additions towards this functionality... see the readme for details, but of particular note:
There is now an event:message,SOME_TEXT
target/avoid available. So you can do event:message,help
and it will react when a player says "help!" in chat nearby.
There isn't yet a message response to targets available. (Not sure if that's worth adding atm, would be a rather complicated addition) It's just able to avoid or attack people that post the message for the moment.
There is now multi target support - done like /sentinel addtarget multi:zombie,zombie,creeper
(targets 2 zombies and 1 creeper)
There is now more-specific targets support - done like /sentinel addavoid allinone:player|helditem:diamond_sword
targets a player that is holding a sword
There isn't yet a "safe spot to run back to" available (will likely add soon)
Update: as of Sentinel build DEV-238+, you can do /sentinel avoidreturnpoint
to set the safe spot to run back to.
Great, thanks! Looking forward to try these changes out.
I support the idea of custom messages when acquiring targets, maybe could even add a cooldown for how many seconds or ticks apart each message appears as well so that it doesn't spamm chat
How do I remove /sentinel addavoid allinone:player|helditem:diamond_sword? Using the same command with removeavoid doesn't work?
/sentinel removeavoid allinone:0
(the 0
is the numbered index of the target label in the targets list ... it's set up this way to just be less of a pain)
Please use the #sentinel-lobby
channel on the Discord https://discord.gg/Q6pZGSR for general help questions.
I think with the available Sentinel events in Denizen and the features already core to Denizen itself (proximity trigger, etc) you can build the custom messages and other advanced handling yourself. Given that, and that the other requests were added, I'm going to call this issue completed.
For Sentinel,
It would be fun if we could have sentinel return / run to a selected location (a base maybe) on trigger... like spies, or thieves watching a path. Then maybe pass a location marker (what the sentinel was watching) for a destination to others (their group, more guards). Or wake everyone up / send them to their posts. If that is getting too complex having them shout out something as they ran back to base would also set the mood.
I was thinking that the sentinel would guard an area but when it saw something (say two target creatures) it would trigger something like run and get help, or call out 'intruders, intruders' that could trigger others NPCs to come. Or if they were thieves and saw more than one person (maybe with a diamond) they could go get some more friends to attack.
Could make a fun dynamic so when the players figured it out they could send one person to draw off the group and then go raid their camp.