Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How would I do sanity checks with a placement system that uses models?

So I have a system which allows players to resize the models

Now the Problem

HOW WOULD I DO SANITY CHECKS ONTO THE MODEL

Do I trust the players model from the client that they resized ENTIRELY?

I was thinking of something like

Player sends a model to the server ---->>>> Server checks if that model from the client is under a folder

so like

Client Side

RemoteEvent:FireServer(ModelToResize)



RemoteEvent.OnServerEvent:Connect(function(Player, ModelBeingResized)

	if ModelBeingResized.Parent == PlayerFolder then
		--Resize it
	end


end)


1 answer

I would suggest that you add a check that checks if the model is sized larger than its largest allowed size. Also, I would suggest that the models exist in Replicated Storage, and both the client and server just pull from there, so that the client doesn't end up sending a model that shouldn't be there. You could implement this by sending the name of the model, and the size it should be resized to, instead of the entire model.

2 comments

0

Thing is Models do not have any size,

0

you would use the same methods and data you are using to resize the models on the client side

This discussion is preserved as it was. New answers, comments, and votes are closed.