Add Basic Spell System (#9)
Co-authored-by: alhashij <alhashimy.janna@gmail.com> Reviewed-on: #9 Co-authored-by: Lance1416 <lanceli1416@gmail.com> Co-committed-by: Lance1416 <lanceli1416@gmail.com>
This commit was merged in pull request #9.
This commit is contained in:
@@ -30,6 +30,11 @@ void ALumiController::GetLumiCharacter(ALumiCharacter*& OutLumiCharacter) const
|
||||
OutLumiCharacter = LumiCharacter;
|
||||
}
|
||||
|
||||
ALumiCharacter* ALumiController::GetLumiCharacter() const
|
||||
{
|
||||
return LumiCharacter;
|
||||
}
|
||||
|
||||
void ALumiController::OnPossess(APawn* InPawn)
|
||||
{
|
||||
Super::OnPossess(InPawn);
|
||||
@@ -99,8 +104,8 @@ void ALumiController::OnPossess(APawn* InPawn)
|
||||
{
|
||||
EnhancedInputComponent->BindAction(SpellAction,
|
||||
ETriggerEvent::Started,
|
||||
LumiCharacter,
|
||||
&ALumiCharacter::OnSpellActionStarted);
|
||||
this,
|
||||
&ALumiController::OnSpellActionStarted);
|
||||
EnhancedInputComponent->BindAction(SpellAction,
|
||||
ETriggerEvent::Completed,
|
||||
this,
|
||||
@@ -128,12 +133,12 @@ void ALumiController::OnUnPossess()
|
||||
|
||||
void ALumiController::OnSpellActionStarted()
|
||||
{
|
||||
ShowMouseCursor();
|
||||
// ShowMouseCursor();
|
||||
LumiCharacter->OnSpellActionStarted();
|
||||
}
|
||||
|
||||
void ALumiController::OnSpellActionCompleted()
|
||||
{
|
||||
LumiCharacter->OnSpellActionCompleted();
|
||||
HideMouseCursor();
|
||||
// HideMouseCursor();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user