Im making a script where when the player says the command they grow bigger
The issue is whenever i fire the remote event from a local script it doesn’t work and im trying to figure out why .
Ive tried using tables instead on the server script but that didnt go well either .
server script
ts = game:GetService("TweenService")
goal1 = {}
goal1.Transparency = 1
goal2 = {}
goal2.Transparency = 0
tweenInfo = TweenInfo.new(1)
game.ReplicatedStorage.Big.OnClientEvent:Connect(function(Player, Character)
game.Players.PlayerAdded:Connect(function(Player)
Player.CharacterAdded:Connect(function(Character)
local Humanoid = Character:WaitForChild("Humanoid")
local face = Character.Head.face
Player.Chatted:Connect(function(msg)
for _,v in pairs(Character:GetDescendants()) do
if (v:IsA("BasePart") or v:IsA("MeshPart") or v:IsA("Decal")) then
if v.Name ~= "HumanoidRootPart" then
ts:Create(v, tweenInfo, {Transparency = 1}):Play()
end
end
end
wait(0.3)
local HS = Humanoid.HeadScale
local BDS = Humanoid.BodyDepthScale
local BWS = Humanoid.BodyWidthScale
local BHS = Humanoid.BodyHeightScale
wait(0.3)
HS.Value = HS.Value * 3
BDS.Value = BDS.Value * 3
BWS.Value = BWS.Value * 3
BHS.Value = BHS.Value * 3
for _,v in pairs(Character:GetDescendants()) do
if (v:IsA("BasePart") or v:IsA("MeshPart") or v:IsA("Decal")) then
if v.Name ~= "HumanoidRootPart" then
ts:Create(v, tweenInfo, {Transparency = 0}):Play()
end
end
end
Humanoid.WalkSpeed = 19
wait(15)
for _,v in pairs(Character:GetDescendants()) do
if (v:IsA("BasePart") or v:IsA("MeshPart") or v:IsA("Decal")) then
if v.Name ~= "HumanoidRootPart" then
ts:Create(v, tweenInfo, {Transparency = 1}):Play()
end
end
end
wait(0.6)
HS.Value = HS.Value / 3
BDS.Value = BDS.Value / 3
BWS.Value = BWS.Value / 3
BHS.Value = BHS.Value / 3
Humanoid.WalkSpeed = 16
for _,v in pairs(Character:GetDescendants()) do
if (v:IsA("BasePart") or v:IsA("MeshPart") or v:IsA("Decal")) then
if v.Name ~= "HumanoidRootPart" then
ts:Create(v, tweenInfo, {Transparency = 0}):Play()
end
end
end
end)
end)
end)
end)
local script
local db = false
local remote = game.ReplicatedStorage.Big
game.Players.PlayerAdded:Connect(function(Player)
Player.CharacterAdded:Connect(function(Character)
local Humanoid = Character:WaitForChild("Humanoid")
local face = Character.Head.face
Player.Chatted:Connect(function(msg)
if string.lower(msg) == "maior" and not db then
db = true
remote:FireAllClients()
end
wait(14)
db = false
end)
end)
end)