Download

Who killed what?

Let’s say there are multiple players connected, and player 1 kills a dodo.
Is there a way for the server to be notified as soon as this happens?
And likewise, is it possible to know who or what actually killed it?

There are ways of binding events to ShooterCharacterDied, and the notification exists for when your tamed creatures are killed, it tells you who/what did it.

I would hazard a guess that there is either a similar event somewhere that handles the notification or you should be able to use Event Any Damage Received and use the Instigator to determine who did what.

A very basic way of looking at it.

-WM

Thanks! This seems to work:

leJ00xk.png

From the event cast the damage causer to shooter character. That will allow replication to take place correctly(get player pawn won’t) and essentially combine that branch into itself anyway as you have the option of proceeding from cast fail(false) or continuing on if succeeds(true).

-WM

That would eliminate the knowledge of which player (index) caused the damage. Anyhow, I tested it and it works just fine.
I suppose if I did it your way, I could get all actors of class ShooterCharacter, and use a for loop to get the indices, but that seems a bit overkill for my purposes.

Ok, that doesn’t really tell me why you’re trying to do it the way you are.

The reason I stated that is because those indexes aren’t replicated, that’s a local thing, really only used for single player instances - and in ARK single player still uses a server instance contained within itself it seems. That in conjunction with trying to do this in the level blueprint is a recipe for disaster, as unless you’re running singleplayer or never intend to make it public on the workshop, it will not work on servers.

From shootercharacter you can pull the targeting team(this will reflect the entire tribe if the player is in a tribe meaning it will be valid for all) or you can get the Unique(steam) or Linked(UE4 Engine) ID’s which are specific to a player.

At any rate, what I say is just advice, it is entirely your decision as to what you do.

-WM