Create buy system

Hello,
I was wondering if anyone knew of any tutorials or have any advice on making a player buy system. Kind of like GTA where you have money and go into Ammunation and buy guns. I can’t seem to find anything like this on the internet. In my game players can collect money or some type of currency and then go into the store and buy food or ammo. Any information would be great!

Thanks,

Well I know you can just use a variable for currency and certain items you pick up can increase this amount, then you make a hud system that pops up when you talk to a certain npc that allows you to select different buy options. Once you set up the buying options you just do a simple script that checks if the player has enough money to buy that item and if so then it gives you that item and subtracts the money.

Idk if that helps or not. I could show you a C++ script I made in a doom mod of mine that does a text based shop gui system, that could help you visualize what you must do with blueprint.

I am working on this kinda thing.

What I do is keep the money “INT” in the player Char.

Then I use a 3D widget, press space and the mouse appears.

Click on the widget I want, it the transfer the item to my player and removes the money.

Very simple, it just depends on how you want to do it.

You could have it set up that the shop is it’s own level, so when you enter it, you load the level and then go back to the old level when you leave, or you could have a widget pop up on the screen and do it that way, or with a 3D widget like myself.

There are hundreds of ways you can do this, maybe even thousands, I would use UMG Widgets for the UI and variables stored either in the game state or character blueprint. Anyways however you do it is up to you, good luck.