#include "TreasureBox.h" #include "Components/SkeletalMeshComponent.h" #include "Components/StaticMeshComponent.h" #include "Net/UnrealNetwork.h" #include "RepairableComponent.h" #include "RepairableUsable.h" #include "SingleUsableComponent.h" #include "TerrainPlacementComponent.h" void ATreasureBox::PlaceResources(AProceduralSetup* Setup, float Radius, UDebrisPositioning* DebrisPositioning, const TArray& locationsToAvoid, UCurveFloat* AvoidCostCurve) { } void ATreasureBox::OnUsedEvent(APlayerCharacter* User, EInputKeys Key) { } void ATreasureBox::OnRepairedEvent(URepairableComponent* repaired) { } void ATreasureBox::OnHammerProgress(float Progress) { } void ATreasureBox::OnHammered(APlayerCharacter* User, EInputKeys Key) { } void ATreasureBox::OnFullyRepairedEvent(URepairableComponent* repaired) { } void ATreasureBox::OnAllResourcesCollectedEvent(URepairableComponent* repaired) { } void ATreasureBox::AfterRepairDelay() { } void ATreasureBox::ActivateCollection() { } void ATreasureBox::GetLifetimeReplicatedProps(TArray& OutLifetimeProps) const { Super::GetLifetimeReplicatedProps(OutLifetimeProps); DOREPLIFETIME(ATreasureBox, ItemsInserted); DOREPLIFETIME(ATreasureBox, IsTreasureAvailable); } ATreasureBox::ATreasureBox() { this->repairable = CreateDefaultSubobject(TEXT("repairable")); this->RepairUsable = CreateDefaultSubobject(TEXT("RepairUsable")); this->HammeringUsable = CreateDefaultSubobject(TEXT("HammeringUsable")); this->terrainPlacement = CreateDefaultSubobject(TEXT("terrainPlacement")); this->MiddlePlane = CreateDefaultSubobject(TEXT("MiddlePlane")); this->BoxMesh = CreateDefaultSubobject(TEXT("BoxMesh")); this->CollectActivationDelay = 5.00f; this->OpenBoxAnim = NULL; this->DelayToOpenAfterRepair = 2.00f; this->ResourceClass = NULL; this->boxRewarder = NULL; this->HologramRotationSpeed = 10.00f; this->ItemsInserted = 0; this->IsTreasureAvailable = false; }