Hi, me and a couple friends are making a Roblox game and we don’t know how we would script a system where you buy something from a gui (we have made the gui and what to buy) and it gets put in another gui called your inventory. after you buy it, and you can place it down in your plot where you can rotate and put it back in your inventory if you want to after you’ve placed something down. I really hope somebody can help as me and my friends are really committed to this project and this is a massive roadblock for us. Thank you
#Need scripting help if anyone can spare a few mins
1 messages · Page 1 of 1 (latest)
So, this is a mix of 3 systems, which I would just make independently and connect them together.
- a shop UI, quite simple: player clicks button -> local check if he has enough money -> remote event to server -> server check if he has enough money -> remove money, add item (in that order, to prevent cheating)
- an inventory system: mainly just dict logic and a datastore (remember that you cannot save instances in them)
- a building system: control/preview done on client -> on built: remote event to server -> check if player has item, check if position is a valid position. Place it.
Then I would recommend also adding some system to actually save the builds and such