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

Why Won't the part change size and shape in my script? (REMOTEEVENTS)?

Ok so if you look at my script you will see in the server script i tried changing The first one is my local script which everything is right i think

--local script
local ScreenGui = script.Parent
local button = ScreenGui.TextButton
local Remote = game:GetService("ReplicatedStorage"):WaitForChild('RemoteEvent')


button.MouseButton1Click:Connect(function()


Remote:FireServer()

end)
--serverscript
local ScreenGui = script.Parent
local Button = ScreenGui.TextButton
local Remote = game:GetService("ReplicatedStorage"):WaitForChild('RemoteEvent')


Remote.OnServerEvent:Connect(function(player)
	print(player)
	print('0eventfired')
	local part = Instance.new("Part",workspace)
	part.Position = Vector3.new(0,0,0,0)
	part.Size = Vector3.new(10,10,10)
	part.Shape = 'Ball'
end)

5 comments

0

the problem is likely where your server script is located. im guessing its in StarterGui, because its parent is the ScreenGui. you should move it to ServerScriptService and remove the variable for the ScreenGui.

0

I think it's because he is printing just player, I made an answer, it should help him and fix his issue.

0

and the button variable

0

Anyway, I don't think it'd matter since he didn't use the variables at all, other than Remote? Odd.

0

the variables dont matter but theyre unused and unneeded and should be removed

1 answer

theres four arguments in the Vector3.new declaration, perhaps this is throwing an error and thus won't run the .Size change

3 comments

0

i thought u were an idiot until i realized what u were talking about. nice catch ;)

0

thanks

0

Incorrect as well. The fourth argument is simply discarded.

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