Ad
Still have questions? Join our Discord server and get real time help.
Log in to vote
0

Gravity prints different values?

Asked by 7 days ago
Edited 7 days ago

local script:

if msg:lower():match("full gravity") then
    local gravity = 197
    print(gravity)
game:GetService("ReplicatedStorage"):WaitForChild("gravity"):FireServer(gravity)
end

server script:

game.ReplicatedStorage:WaitForChild("gravity").OnServerEvent:Connect(function(player,gravity)
    game.Workspace.Gravity = gravity
    print(gravity)
end)

prints:

197

197

vity

why does server script both print 197 and vity?

0
Do you have another script or line of code running elsewhere? I don't see reason for 'vity' to appear than that unless it's your string manipulation alphawolvess 1673 — 7d
0
where in the heck is vity coming from :thonk:, that is surely from somewhere else starmaq 662 — 7d
0
i clicked on the prints to know where they come from and both one of the 197's and vity comes from the server script print Gameplayer365247v2 435 — 7d

Answer this question