Block Placement System

So I’m making a game and I was wondering if there is a script for block placing and pickup, but you can only place one block, I couldn’t find it anywhere on YouTube or Google.

There’s lots of help request threads about making minecraft clones that could be a good starting point, try the search feature

I did try that but all of them make it so you can place an infinite amount of blocks

Well, the quick and dirty way to make those only allow one block to be placed is to have a global boolean in the script that tracks whether a block has been placed and only allow placing blocks if it’s false

HOW TO MAKE A MINECRAFT BLOCK PLACING SYSTEM IN ROBLOX - YouTube
Check this out. If you just want 1 block, create a intValue and do:

-- here's the script

if intValue <= 0
   placeBlock() -- This would be the function that places out the block.
   intValue.Value += 1 -- The intValue's Value goes up to 1 (max blocks).
else
   warn("Max blocks is placed") -- If there's already a block outplaced, you'll not be able to place out another.
end

Hope this helps!