So basicly i have a model called level1 and what i am looking is to add a spleef script in them which i have in the workspace called spleefscript! What im looking to do is insert or make all of those 200 blocks work on that single script and not make me put a script in each of the blocks that might that 2 hours.
You can use one script to interact with multiple objects in your game. But of course, you will need to reference them.
You may not be able to implement this into your script, but it is because I have no idea what your script looks like.
In this example here I used a for loop to get (or reference I think) the blocks that are the platform for a Spleef game.
-- Let's just say that you put all of the blocks used as the platform -- in a Spleef game in a folder -- named SpleefPlatform. -- remember to define speelfPlatform folder correctly since I did not, this will give an error if you don't. local spleefPlatform local function activateSpleefPlatform() for _, child in pairs(spleefPlatform:GetChildren()) do if not child:IsA("BasePart") then return end local spleefPlatformBlock = child -- there is a high chance that you will use a .Touched event. spleefPlatformBlock.Touched:Connect(function(partHit) -- Make them disappear if a player touches or something... end) end end activateSpleefPlatform()
For more information about for loops, go to this link: https://developer.roblox.com/en-us/articles/Loops