Add spell interactable door

This commit is contained in:
2025-05-15 00:28:56 -04:00
parent bcca018acd
commit b072b71a9e
12 changed files with 108 additions and 8 deletions
@@ -288,6 +288,16 @@ void ALumiCharacter::AddSpellTemplateToTable(const FString& Name)
HideTrainWidget();
}
void ALumiCharacter::OnSpellCast_Implementation(const FString& SpellName)
{
UE_LOG(
LogLumiCharacter,
Log,
TEXT("ALumiCharacter::OnSpellCast_Implementation() Spell: %s"),
*SpellName
);
}
bool ALumiCharacter::GetPlayerController(APlayerController*& LumiController) const
{
LumiController = Cast<APlayerController>(this->Controller);
@@ -323,6 +333,8 @@ void ALumiCharacter::CastSpell()
{
bHasMatch = true;
UE_LOG(LogLumiCharacter, Log, TEXT("ALumiCharacter::CastSpell() Spell: %s"), *Result.Name);
OnSpellCast(Result.Name);
}
// TODO: Handle Spell Casting
@@ -201,6 +201,10 @@ protected:
virtual void
BeginPlay() override;
UFUNCTION(BlueprintNativeEvent, Category = "Spell")
void
OnSpellCast(const FString& SpellName);
private:
bool
GetPlayerController(APlayerController*& LumiController) const;