mirror of
https://github.com/unixtensor/Roblox-Elevator-Game.git
synced 2025-12-14 14:51:55 +00:00
walkspeed and jumpheight changes, use the frameworks default values instead
This commit is contained in:
@@ -2,6 +2,7 @@ local HumanoidModule = {}
|
|||||||
HumanoidModule.__index = HumanoidModule
|
HumanoidModule.__index = HumanoidModule
|
||||||
|
|
||||||
type WalkSpeed = number?
|
type WalkSpeed = number?
|
||||||
|
type JumpHeight = number?
|
||||||
|
|
||||||
function HumanoidModule.constructor(Humanoid: Humanoid)
|
function HumanoidModule.constructor(Humanoid: Humanoid)
|
||||||
return setmetatable({
|
return setmetatable({
|
||||||
@@ -10,7 +11,11 @@ function HumanoidModule.constructor(Humanoid: Humanoid)
|
|||||||
end
|
end
|
||||||
|
|
||||||
function HumanoidModule:SetWalkSpeed(Speed: WalkSpeed)
|
function HumanoidModule:SetWalkSpeed(Speed: WalkSpeed)
|
||||||
self.Humanoid.WalkSpeed = Speed or 16
|
self.Humanoid.WalkSpeed = Speed or 10
|
||||||
|
end
|
||||||
|
|
||||||
|
function HumanoidModule:SetJumpHeight(Height: JumpHeight)
|
||||||
|
self.Humanoid.JumpHeight = Height or 7.2
|
||||||
end
|
end
|
||||||
|
|
||||||
return HumanoidModule
|
return HumanoidModule
|
||||||
@@ -36,7 +36,8 @@ local function CrouchFeature()
|
|||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
HumanoidSettings:SetWalkSpeed(10)
|
HumanoidSettings:SetWalkSpeed()
|
||||||
|
HumanoidSettings:SetJumpHeight()
|
||||||
HRPSettings:DisableRobloxSounds()
|
HRPSettings:DisableRobloxSounds()
|
||||||
CameraConsturctor:EnableBobbing()
|
CameraConsturctor:EnableBobbing()
|
||||||
|
|
||||||
|
|||||||
6
src/server/Studio/StarterPlayer.lua
Normal file
6
src/server/Studio/StarterPlayer.lua
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
local StarterPlayer = game:GetService("StarterPlayer")
|
||||||
|
|
||||||
|
return function()
|
||||||
|
StarterPlayer.CharacterWalkSpeed = 0
|
||||||
|
StarterPlayer.CharacterJumpHeight = 0
|
||||||
|
end
|
||||||
@@ -1,12 +1,10 @@
|
|||||||
local HideEditorEntities = require(script:WaitForChild("EditorEntities"))
|
local HideEditorEntities = require(script:WaitForChild("EditorEntities"))
|
||||||
local Lighting = require(script:WaitForChild("Lighting"))
|
local Lighting_Stuff = require(script:WaitForChild("Lighting"))
|
||||||
|
local Workspace_Stuff = require(script:WaitForChild("Workspace"))
|
||||||
|
local StarterPlayer_Stuff = require(script:WaitForChild("StarterPlayer"))
|
||||||
|
|
||||||
local RS = game:GetService("RunService")
|
local RS = game:GetService("RunService")
|
||||||
local Storage = game:GetService("ReplicatedStorage")
|
local Storage = game:GetService("ReplicatedStorage")
|
||||||
local StarterPlayer = game:GetService("StarterPlayer")
|
|
||||||
|
|
||||||
StarterPlayer.CharacterWalkSpeed = 0
|
|
||||||
StarterPlayer.CharacterJumpHeight = 0
|
|
||||||
|
|
||||||
local ServerStorage = Storage:WaitForChild("Server")
|
local ServerStorage = Storage:WaitForChild("Server")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user