diff --git a/Source/the_twilight_abyss/PlayerTemp/TempCharacter.cpp b/Source/the_twilight_abyss/PlayerTemp/TempCharacter.cpp index bfdfe06..aed31e5 100644 --- a/Source/the_twilight_abyss/PlayerTemp/TempCharacter.cpp +++ b/Source/the_twilight_abyss/PlayerTemp/TempCharacter.cpp @@ -85,6 +85,7 @@ void ATempCharacter::LineTraceLogic() } if(OutHit.GetActor()->FindComponentByClass()) { + UE_LOG(LogTemp, Display, TEXT("Hit Merchant")); auto ItemArray = OutHit.GetActor()->FindComponentByClass()->GetItem(0); if(GoldBalance >= ItemArray->ItemCostPrice) { @@ -139,6 +140,7 @@ void ATempCharacter::LineTraceLogic() void ATempCharacter::InputDisabler() { UE_LOG(LogTemp, Display, TEXT("Disabling playermovement")); + disableTab = true; //GetWorld()->GetFirstPlayerController()->InputComponent->RemoveActionBinding("Interact", IE_Pressed); GetWorld()->GetFirstPlayerController()->SetIgnoreLookInput(true); GetWorld()->GetFirstPlayerController()->SetIgnoreMoveInput(true); @@ -163,6 +165,7 @@ void ATempCharacter::InputDisabler() void ATempCharacter::InputEnabler() { UE_LOG(LogTemp, Display, TEXT("Enabling Inputs")); + disableTab = true; GetWorld()->GetFirstPlayerController()->SetIgnoreLookInput(false); GetWorld()->GetFirstPlayerController()->SetIgnoreMoveInput(false); GetWorld()->GetFirstPlayerController()->bShowMouseCursor = false; diff --git a/Source/the_twilight_abyss/PlayerTemp/TempCharacter.h b/Source/the_twilight_abyss/PlayerTemp/TempCharacter.h index 928b8df..510587b 100644 --- a/Source/the_twilight_abyss/PlayerTemp/TempCharacter.h +++ b/Source/the_twilight_abyss/PlayerTemp/TempCharacter.h @@ -77,5 +77,8 @@ public: void BuyItem(); bool bShopKeeperText = false; + + UPROPERTY(BlueprintReadWrite) + bool disableTab = false; };