I made Mana and Regenerate Mana System. Has it BETTER WAY?

Hi, I’m student in South Korea and, this is my first question.(I’m not good at Eng)

I made mana system which i defined ‘Ether’ with BP(BP_ThirdPersonCharacter).

And, I want to know there are better ways!!! That All, Thank you.

variables


connected at Begin Play event

no thats about right, you could clean it up by moving the Get/Set CurrentEther inside the function since thats all it will handle anyway

or you can pull the Max out and use it to regenerate anything like health too

2 Likes

You could also pull out the return pin of the timer and promote it to a variable. You could then clear and stop the timer once the mana equals max mana to not waste CPU cycles. Then just restart the timer once the mana drops below max.

2 Likes

Ah, It must be good way to optimize program!! Thank you for your help!!!

Oh, I missed that. Thank you for pointing out that!


Is it right?

One more question I tried to restart the timer after pausing timer, but it doesn’t work.
Can you teach me how to deal this problem?

thats correct, also to restart the timer you can just call the event again. otherwise show us your code


It still not working :(…


I also tried this way



I solved!!! Thank you guys!!!


YES~!~!~!

Yeah i meant you have to call the 'SetTimer" Event again but as long as you’re happy with the way it works

1 Like