Something problem in "PowerUp" Video

in Unreal Tutorial Video(~9 - Communicating from C++ to Blueprints)

the character’s emit in game is slowly down.

but,
in my game.
that wasn’t

I think that there is NO C++ Code or blueprint about “PowerLevel Value’s Down”

how character’s emit in video was slowly down.

i can’t understand about that.

am i Missed something?

Hello 1205,

This video is based off a project that has quite a bit of code already set up inside of it. You can find the code for the project in the description of the video. Upon opening up the code files and taking a look (I downloaded the first link), you can find the line that causes the power level to decrease inside of TutorialCodeGameMode.cpp at line #38 inside the Tick function for this class. This would be why they are calling the Parent:Tick node inside of the blueprint.

void ATutorialCodeGameMode::Tick(float DeltaSeconds)
{
	ATutorialCodeCharacter* MyCharacter = Cast<ATutorialCodeCharacter>(UGameplayStatics::GetPlayerPawn(this, 0));
	
	//if the character still has power
	if (MyCharacter->PowerLevel > 0.05)
	{
		//decrease the character's power
		MyCharacter->PowerLevel = FMath::FInterpTo(MyCharacter->PowerLevel, 0.f, DeltaSeconds, DecayRate);
	}
	else
	{
		SetCurrentState(ETutorialCodePlayState::EGameOver);
	}

}

Hope this helps!