Answered by
3 years ago Edited 3 years ago
Walking speed does not need Remote Events, you can use humanoid.WalkSpeed to change a humanoid's speed.
Edit: If you place a folder in a player with 2 intvalues that change their values as the humanoid changes its jumppower or walkspeed, then whenever a player respawns their character you can change their jumppower and walkspeed to those values. This will now only not work on the client side, so you have to change jumppower and walkspeed on the server side. If jumppower doesn't work, make sure your humanoids are using jumppower and not jumpheight.
Script creating two intvalues inside players as they join:
01 | local Players = game:GetService( "Players" ) |
03 | local StarterPlayer = game:GetService( "StarterPlayer" ) |
05 | local function PlayerAdded(Player) |
07 | local Folder = Instance.new( "Folder" ) |
09 | Folder.Name = "PlayerData" |
11 | Folder.Parent = Player |
13 | local IntValue 1 = Instance.new( "IntValue" ) |
15 | IntValue 1. Name = "JumpPower" |
17 | IntValue 1. Parent = Folder |
19 | IntValue 1. Value = StarterPlayer.CharacterJumpPower |
21 | local IntValue 2 = Instance.new( "IntValue" ) |
23 | IntValue 2. Name = "WalkSpeed" |
25 | IntValue 2. Parent = Folder |
27 | IntValue 2. Value = StarterPlayer.CharacterWalkSpeed |
29 | local function CharacterAdded(Character) |
31 | local Humanoid = Character:WaitForChild( "Humanoid" ) |
33 | Humanoid.JumpPower = IntValue 1. Value |
35 | Humanoid.WalkSpeed = IntValue 2. Value |
37 | local function JumpPowerChanged() |
39 | IntValue 1. Value = Humanoid.JumpPower |
42 | Humanoid:GetPropertyChangedSignal( "JumpPower" ):Connect(JumpPowerChanged) |
44 | local function WalkSpeedChanged() |
46 | IntValue 2. Value = Humanoid.WalkSpeed |
49 | Humanoid:GetPropertyChangedSignal( "WalkSpeed" ):Connect(WalkSpeedChanged) |
52 | Player.CharacterAdded:Connect(CharacterAdded) |
55 | Players.PlayerAdded:Connect(PlayerAdded) |
Make sure to put this script in Game.ServerScriptService or Game.Workspace, as a server script of course.
Please let me know if my editing didn't help, I'll be happy to help.