# Permanent buff upgrades?

**URL:** <https://forums.unrealengine.com/t/permanent-buff-upgrades/482362>\
**Category:** Editor Scripting\
**Tags:** savegame, upgrade, in-app-purchase, unreal-engine, Blueprint, question\
**Created:** [April 23, 2021, 2:40pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362 "2021-04-23T14:40:02Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![unrealredist](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@unrealredist](https://forums.unrealengine.com/u/unrealredist)\
**Post date:** [April 23, 2021, 2:40pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/1 "2021-04-23T14:40:02Z")

</div>

I want to make a store that permanently upgrades buffs for example, Increase Fire rate, Projectile damage, etc, I tried… But for weeks I cannot figure out, Heres the code I was using,

 ![336861-bp4.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/4/8/148833ad2c7773d5123e695361814382b904b10e.png)

This is to refresh the saved game and set the fire rate

 ![336862-workshop.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/a/f/9/af9771ca1ed18e415cc0252e64b555dc9bf80604.png)

And this is to purchase the upgrade so that it can be refreshed and used, Now I tried it and now I shoot like a minigun /: When I clearly set the delay to 1.0 So can anyone help?

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [April 23, 2021, 3:01pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/2 "2021-04-23T15:01:59Z")

</div>

Why are you saving & loading game on Tick? Top screenshot.

---

<div class="post-metadata">

**Author:** ![unrealredist](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@unrealredist](https://forums.unrealengine.com/u/unrealredist)\
**Post date:** [April 23, 2021, 3:08pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/3 "2021-04-23T15:08:57Z")

</div>

So that It will constantly be updated

---

<div class="post-metadata">

**Author:** ![unrealredist](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@unrealredist](https://forums.unrealengine.com/u/unrealredist)\
**Post date:** [April 23, 2021, 3:09pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/4 "2021-04-23T15:09:48Z")

</div>

Wait a sec was I supposed to use **Event Begin Play**

---

<div class="post-metadata">

**Author:** ![unrealredist](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@unrealredist](https://forums.unrealengine.com/u/unrealredist)\
**Post date:** [April 23, 2021, 3:12pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/5 "2021-04-23T15:12:44Z")

</div>

NVM Did not work

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [April 23, 2021, 3:16pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/6 "2021-04-23T15:16:06Z")

</div>

You’re loading and saving game 60 times per second…

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [April 23, 2021, 3:16pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/7 "2021-04-23T15:16:31Z")

</div>

It’s this generally speaking:

 ![336863-screenshot-2.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/6/7/e/67e37455dfdd819b9829af74acd95d0a9519f7c7.png)

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [April 23, 2021, 3:17pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/8 "2021-04-23T15:17:20Z")

</div>

Pressing 1 buys firerate updgrade. Next time the game starts, we load this value from the save data.

* * *

Playing for the first time, the firerate is 1, firing 1 per second:

[![Image from Gyazo](https://d3kjluh73b9h9o.cloudfront.net/original/4X/1/2/f/12fb783e6eb25d72b1a9306f61b538a0b0050c53.gif)](https://gyazo.com/f82a56afa85019880821462bfd8d6cc0)

Buying 4 upgrades brings it to 5, we now shoot 5 times per second:

[![Image from Gyazo](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/7/f/77fa6e1b4a25bd030ab5e27c7025715038fe7919.gif)](https://gyazo.com/adf82ee31e7f70979bb42043f151de0b)

Restarting the game yields the same results as above. We fire more quickly.

Hope this helps.

---

<div class="post-metadata">

**Author:** ![unrealredist](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@unrealredist](https://forums.unrealengine.com/u/unrealredist)\
**Post date:** [April 24, 2021, 11:00am UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/9 "2021-04-24T11:00:14Z")

</div>

Wow great job!!! but is there a way to limit the Firerate from (0 - 5)? also can I pls see the code in the **Collapsed Graph** Thats it

---

<div class="post-metadata">

**Author:** ![Everynone](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/everynone/32/1135017_2.png) [@Everynone](https://forums.unrealengine.com/u/Everynone)\
**Post date:** [April 24, 2021, 2:22pm UTC](https://forums.unrealengine.com/t/permanent-buff-upgrades/482362/10 "2021-04-24T14:22:50Z")

</div>

You can clamp values like so:

 ![337004-screenshot-1.png](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/f/1/bf11424811695df43bb3ea84d82a0e1ec73ceed4.png)

> the Collapsed

That’s just the standard spawn projectile stuff from the template, I copied it and collapsed so it takes less space.
