sky1145960810
New member
- Messages
- 5
- Points
- 1
C++:
bool Hook_APrimalStructure_Die(APrimalStructure* _this, float KillingDamage, FDamageEvent* DamageEvent, AController* Killer, AActor* DamageCauser)
{
int structureTeamId = _this->TargetingTeamField();
if (structureTeamId != 0) // tribe
{
if (Killer && Killer->IsA(APlayerController::StaticClass())) {
AShooterPlayerController* player = (AShooterPlayerController*)Killer;
int killerTeamId = player->TargetingTeamField();
ArkApi::GetApiUtils().SendChatMessage(player, "TestPlugin", *FString("[Structure Death] StructureTeamId: " + std::to_string(structureTeamId)));
ArkApi::GetApiUtils().SendChatMessage(player, "TestPlugin", *FString("[Structure Death] KillerTeamId: " + std::to_string(killerTeamId)));
}
}
}