Disabled loss of speed in the roll (switchable), separate activation of the speedometer, you can disable the voice Totsugeki, moved parameters in the menu. Localization is in English and Russian

This commit is contained in:
shen 2024-06-06 12:13:26 +03:00
parent fa800eb51f
commit 9d10aae001
6 changed files with 73 additions and 11 deletions

View file

@ -41,6 +41,9 @@ beatrun.convars.disablegrapple=Disables grapple ability
beatrun.convars.puristmode=Purist mode is a clientside preference that severely weakens the ability to strafe while in the air, which is how ME games handle this.\n0 = No restrictions\n1 = Reduced move speed in the air beatrun.convars.puristmode=Purist mode is a clientside preference that severely weakens the ability to strafe while in the air, which is how ME games handle this.\n0 = No restrictions\n1 = Reduced move speed in the air
beatrun.convars.quickturnground=Enables quickturning with secondary attack while on the ground beatrun.convars.quickturnground=Enables quickturning with secondary attack while on the ground
beatrun.convars.quickturnhandsonly=Enables quickturning with "Runner Hands" only beatrun.convars.quickturnhandsonly=Enables quickturning with "Runner Hands" only
beatrun.convars.loseSpeedOnRoll=Whether or not the player will lose speed when rolling (similar to ME:Catalyst)
beatrun.convars.showSpeedometer=Nothing to say
beatrun.convars.totsugekiAudio=Enable "Totsugeki" voice
# HUD # HUD
beatrun.hud.course=Course: %s beatrun.hud.course=Course: %s
@ -109,6 +112,9 @@ beatrun.toolsmenu.hud.nametagsdesc=Toggles nametags above players
beatrun.toolsmenu.hud.hudxp=Show HUD XP beatrun.toolsmenu.hud.hudxp=Show HUD XP
beatrun.toolsmenu.hud.hudxpdesc=Show total XP near your nickname beatrun.toolsmenu.hud.hudxpdesc=Show total XP near your nickname
beatrun.toolsmenu.hud.showSpeedometer=Show Speedometer
beatrun.toolsmenu.hud.showSpeedometerDesc=Shows the speedometer on HUD (hiding HUD does not affect visibility)
beatrun.toolsmenu.hud.wind=Wind Effect beatrun.toolsmenu.hud.wind=Wind Effect
beatrun.toolsmenu.hud.winddesc=Wind noises when running beatrun.toolsmenu.hud.winddesc=Wind noises when running
@ -123,8 +129,8 @@ beatrun.toolsmenu.hud.cornercolor=HUD Corner Color
beatrun.toolsmenu.hud.floatxpcolor=HUD Floating XP Color beatrun.toolsmenu.hud.floatxpcolor=HUD Floating XP Color
# Tools Menu Viewbob Section # Tools Menu Viewbob Section
beatrun.toolsmenu.viewbob.name=Viewbob beatrun.toolsmenu.viewbob.name=Camera
beatrun.toolsmenu.viewbob.desc=Viewbob Settings beatrun.toolsmenu.viewbob.desc=Camera Settings
beatrun.toolsmenu.viewbob.stabilization=Viewbob Stabilization beatrun.toolsmenu.viewbob.stabilization=Viewbob Stabilization
beatrun.toolsmenu.viewbob.stabilizationdesc=Turn on to reduce motion sickness by making viewbobbing keep the player's look position centered beatrun.toolsmenu.viewbob.stabilizationdesc=Turn on to reduce motion sickness by making viewbobbing keep the player's look position centered
@ -146,6 +152,9 @@ beatrun.toolsmenu.gameplay.puristmodedesc=Purist mode is a clientside preference
beatrun.toolsmenu.gameplay.disablegrapple=Disable Grapple Ability beatrun.toolsmenu.gameplay.disablegrapple=Disable Grapple Ability
beatrun.toolsmenu.gameplay.disablegrappledesc=Disables grapple ability beatrun.toolsmenu.gameplay.disablegrappledesc=Disables grapple ability
beatrun.toolsmenu.gameplay.rollLoseSpeed=Lose Speed on Roll
beatrun.toolsmenu.gameplay.rollLoseSpeedDesc=Literally whether or not the player will lose speed on roll (similar to ME:Catalyst)
# Tools Menu Misc Section # Tools Menu Misc Section
beatrun.toolsmenu.misc.name=Misc beatrun.toolsmenu.misc.name=Misc
beatrun.toolsmenu.misc.desc=Misc Settings beatrun.toolsmenu.misc.desc=Misc Settings
@ -202,6 +211,9 @@ beatrun.toolsmenu.moves.totsugekiheadingdesc=Allows to Totsugeki on X axis (up/d
beatrun.toolsmenu.moves.totsugekidirection=Totsugeki Direction beatrun.toolsmenu.moves.totsugekidirection=Totsugeki Direction
beatrun.toolsmenu.moves.totsugekidirectiondesc=Allows to Totsugeki into Another Direction\nCombined with Spam and Heading Allows You to Fly =) beatrun.toolsmenu.moves.totsugekidirectiondesc=Allows to Totsugeki into Another Direction\nCombined with Spam and Heading Allows You to Fly =)
beatrun.toolsmenu.moves.totsugekiaudio=Totsugeki Audio
beatrun.toolsmenu.moves.totsugekiaudiodesc=Enable "Totsugeki" voice
# Tools Menu Gamemodes Section # Tools Menu Gamemodes Section
beatrun.toolsmenu.gamemodes.name=Gamemodes beatrun.toolsmenu.gamemodes.name=Gamemodes
beatrun.toolsmenu.gamemodes.desc=Gamemodes Settings beatrun.toolsmenu.gamemodes.desc=Gamemodes Settings

View file

@ -41,6 +41,8 @@ beatrun.convars.disablegrapple=Переключить крюк-кошку
beatrun.convars.puristmode=Режим Purist это клиентский параметр который сильно снижает движение игрока в стороны будучи в воздухе, прямо как в оригинальное ME.\n0 = Нет ограничений\n1 = Снижает движение игрока в воздухе в стороны beatrun.convars.puristmode=Режим Purist это клиентский параметр который сильно снижает движение игрока в стороны будучи в воздухе, прямо как в оригинальное ME.\n0 = Нет ограничений\n1 = Снижает движение игрока в воздухе в стороны
beatrun.convars.quickturnground=Переключить Quickturn будучи на земле beatrun.convars.quickturnground=Переключить Quickturn будучи на земле
beatrun.convars.quickturnhandsonly=Переключить Quickturn только с "Runner Hands" beatrun.convars.quickturnhandsonly=Переключить Quickturn только с "Runner Hands"
beatrun.convars.showSpeedometer=Нечего сказать
beatrun.convars.totsugekiAudio=Включить голос "Totsugeki"
# HUD # HUD
beatrun.hud.course=Курс: %s beatrun.hud.course=Курс: %s
@ -109,6 +111,9 @@ beatrun.toolsmenu.hud.nametagsdesc=Показывает ники над игро
beatrun.toolsmenu.hud.hudxp=Показать XP в HUD beatrun.toolsmenu.hud.hudxp=Показать XP в HUD
beatrun.toolsmenu.hud.hudxpdesc=Показывает весь XP в HUD beatrun.toolsmenu.hud.hudxpdesc=Показывает весь XP в HUD
beatrun.toolsmenu.hud.showSpeedometer=Показывать скорость (спидометр)
beatrun.toolsmenu.hud.showSpeedometerDesc=Показывает спидометр на HUD (скрытие HUD не влияет на видимость)
beatrun.toolsmenu.hud.wind=Эффект Ветра beatrun.toolsmenu.hud.wind=Эффект Ветра
beatrun.toolsmenu.hud.winddesc=Шум ветра во время бега beatrun.toolsmenu.hud.winddesc=Шум ветра во время бега
@ -146,6 +151,9 @@ beatrun.toolsmenu.gameplay.puristmodedesc=Режим Purist это клиент
beatrun.toolsmenu.gameplay.disablegrapple=Отключить Крюк-Кошку beatrun.toolsmenu.gameplay.disablegrapple=Отключить Крюк-Кошку
beatrun.toolsmenu.gameplay.disablegrappledesc=Отключает использование крюка-кошки beatrun.toolsmenu.gameplay.disablegrappledesc=Отключает использование крюка-кошки
beatrun.toolsmenu.gameplay.rollLoseSpeed=Потеря скорости при перекате
beatrun.toolsmenu.gameplay.rollLoseSpeedDesc=Будет ли игрок терять скорость при перекате или нет (как в ME:Catalyst)
# Tools Menu Misc Section # Tools Menu Misc Section
beatrun.toolsmenu.misc.name=Другое beatrun.toolsmenu.misc.name=Другое
beatrun.toolsmenu.misc.desc=Другие настройки beatrun.toolsmenu.misc.desc=Другие настройки
@ -202,6 +210,9 @@ beatrun.toolsmenu.moves.totsugekiheadingdesc=Позволяет делать Tot
beatrun.toolsmenu.moves.totsugekidirection=Направление Totsugeki beatrun.toolsmenu.moves.totsugekidirection=Направление Totsugeki
beatrun.toolsmenu.moves.totsugekidirectiondesc=Позволяет делать Totsugeki в направлении глаз\nCombined with Spam and Heading Allows You to Fly =) beatrun.toolsmenu.moves.totsugekidirectiondesc=Позволяет делать Totsugeki в направлении глаз\nCombined with Spam and Heading Allows You to Fly =)
beatrun.toolsmenu.moves.totsugekiaudio=Totsugeki Звук
beatrun.toolsmenu.moves.totsugekiaudiodesc=Включить голос "Totsugeki"
# Tools Menu Gamemodes Section # Tools Menu Gamemodes Section
beatrun.toolsmenu.gamemodes.name=Режимы beatrun.toolsmenu.gamemodes.name=Режимы
beatrun.toolsmenu.gamemodes.desc=Настройка режимов beatrun.toolsmenu.gamemodes.desc=Настройка режимов

View file

@ -166,12 +166,12 @@ hook.Add("PopulateToolMenu", "Beatrun_ToolMenu", function()
panel:CheckBox("#beatrun.toolsmenu.hud.hudxp", "Beatrun_HUDXP") panel:CheckBox("#beatrun.toolsmenu.hud.hudxp", "Beatrun_HUDXP")
panel:ControlHelp("#beatrun.toolsmenu.hud.hudxpdesc") panel:ControlHelp("#beatrun.toolsmenu.hud.hudxpdesc")
panel:CheckBox("#beatrun.toolsmenu.hud.showSpeedometer", "Beatrun_ShowSpeedometer")
panel:ControlHelp("#beatrun.toolsmenu.hud.showSpeedometerDesc")
panel:CheckBox("#beatrun.toolsmenu.hud.wind", "Beatrun_Wind") panel:CheckBox("#beatrun.toolsmenu.hud.wind", "Beatrun_Wind")
panel:ControlHelp("#beatrun.toolsmenu.hud.winddesc") panel:ControlHelp("#beatrun.toolsmenu.hud.winddesc")
panel:NumSlider("#beatrun.toolsmenu.hud.fov", "Beatrun_FOV", 90, 120, 0)
panel:Help("#beatrun.toolsmenu.hud.fovdesc")
panel:NumSlider("#beatrun.toolsmenu.hud.hidden", "Beatrun_HUDHidden", 0, 2, 0) panel:NumSlider("#beatrun.toolsmenu.hud.hidden", "Beatrun_HUDHidden", 0, 2, 0)
panel:ControlHelp(language.GetPhrase("beatrun.toolsmenu.hud.hiddendesc")) panel:ControlHelp(language.GetPhrase("beatrun.toolsmenu.hud.hiddendesc"))
@ -223,6 +223,9 @@ hook.Add("PopulateToolMenu", "Beatrun_ToolMenu", function()
panel:ControlHelp("#beatrun.toolsmenu.viewbob.stabilizationdesc") panel:ControlHelp("#beatrun.toolsmenu.viewbob.stabilizationdesc")
panel:NumSlider("#beatrun.toolsmenu.viewbob.intensity", "Beatrun_ViewbobIntensity", -100, 100, 0) panel:NumSlider("#beatrun.toolsmenu.viewbob.intensity", "Beatrun_ViewbobIntensity", -100, 100, 0)
panel:NumSlider("#beatrun.toolsmenu.hud.fov", "Beatrun_FOV", 90, 120, 0)
panel:Help("#beatrun.toolsmenu.hud.fovdesc")
end) end)
spawnmenu.AddToolMenuOption("Beatrun", "Client", "beatrun_gameplay", "#beatrun.toolsmenu.gameplay.name", "", "", function(panel) spawnmenu.AddToolMenuOption("Beatrun", "Client", "beatrun_gameplay", "#beatrun.toolsmenu.gameplay.name", "", "", function(panel)
@ -240,6 +243,12 @@ hook.Add("PopulateToolMenu", "Beatrun_ToolMenu", function()
panel:CheckBox("#beatrun.toolsmenu.gameplay.disablegrapple", "Beatrun_DisableGrapple") panel:CheckBox("#beatrun.toolsmenu.gameplay.disablegrapple", "Beatrun_DisableGrapple")
panel:ControlHelp("#beatrun.toolsmenu.gameplay.disablegrappledesc") panel:ControlHelp("#beatrun.toolsmenu.gameplay.disablegrappledesc")
panel:CheckBox("#beatrun.toolsmenu.gameplay.rollLoseSpeed", "Beatrun_LoseSpeedOnRoll")
panel:ControlHelp("#beatrun.toolsmenu.gameplay.rollLoseSpeedDesc")
panel:CheckBox("#beatrun.toolsmenu.moves.totsugekiaudio", "Beatrun_TotsugekiAudio")
panel:ControlHelp(language.GetPhrase("beatrun.toolsmenu.moves.totsugekiaudiodesc"))
end) end)
spawnmenu.AddToolMenuOption("Beatrun", "Server", "beatrun_misc", "#beatrun.toolsmenu.misc.name", "", "", function(panel) spawnmenu.AddToolMenuOption("Beatrun", "Server", "beatrun_misc", "#beatrun.toolsmenu.misc.name", "", "", function(panel)

View file

@ -17,6 +17,10 @@ local timetext = ""
local timealpha = 1000 local timealpha = 1000
local timecolor = color_neutral local timecolor = color_neutral
if CLIENT then
local showSpeed = CreateClientConVar("Beatrun_ShowSpeedometer", 1, true, true, language.GetPhrase("#beatrun.convars.showSpeedometer"), 0, 1)
end
if SERVER then if SERVER then
util.AddNetworkString("Checkpoint_Hit") util.AddNetworkString("Checkpoint_Hit")
util.AddNetworkString("Checkpoint_Finish") util.AddNetworkString("Checkpoint_Finish")
@ -240,7 +244,7 @@ function CourseHUD()
surface.DrawText(text) surface.DrawText(text)
end end
if GetConVar("Beatrun_HUDHidden") and not GetConVar("Beatrun_HUDHidden"):GetBool() and not BuildMode and hook.Run("BeatrunDrawHUD") ~= false and not ply.InReplay then if GetConVar("Beatrun_ShowSpeedometer"):GetBool() then
local speed = math.Round(ply:GetVelocity():Length() * 0.06858125) local speed = math.Round(ply:GetVelocity():Length() * 0.06858125)
if speed < 10 then if speed < 10 then

View file

@ -3,6 +3,10 @@ local totsugekispam = CreateConVar("Beatrun_TotsugekiSpam", 0, {FCVAR_REPLICATED
local totsugekiheading = CreateConVar("Beatrun_TotsugekiHeading", 0, {FCVAR_REPLICATED, FCVAR_ARCHIVE}, "", 0, 1) local totsugekiheading = CreateConVar("Beatrun_TotsugekiHeading", 0, {FCVAR_REPLICATED, FCVAR_ARCHIVE}, "", 0, 1)
local totsugekidir = CreateConVar("Beatrun_TotsugekiDir", 0, {FCVAR_REPLICATED, FCVAR_ARCHIVE}, "", 0, 1) local totsugekidir = CreateConVar("Beatrun_TotsugekiDir", 0, {FCVAR_REPLICATED, FCVAR_ARCHIVE}, "", 0, 1)
if CLIENT then
local tutsugekiAudio = CreateClientConVar("Beatrun_TotsugekiAudio", 1, true, true, language.GetPhrase("beatrun.convars.totsugekiAudio"), 0, 1)
end
local function Dive(ply, mv, cmd) local function Dive(ply, mv, cmd)
if (not ply:GetDive() or ply:GetDive() and ply.QuakeJumping and totsugeki:GetBool() and totsugekispam:GetBool()) and ply:GetCrouchJump() and mv:KeyPressed(IN_ATTACK2) then if (not ply:GetDive() or ply:GetDive() and ply.QuakeJumping and totsugeki:GetBool() and totsugekispam:GetBool()) and ply:GetCrouchJump() and mv:KeyPressed(IN_ATTACK2) then
local vel = mv:GetVelocity() local vel = mv:GetVelocity()
@ -29,7 +33,9 @@ local function Dive(ply, mv, cmd)
if ply:UsingRH() and ply:GetActiveWeapon():GetQuakeJumping() and totsugeki:GetBool() then if ply:UsingRH() and ply:GetActiveWeapon():GetQuakeJumping() and totsugeki:GetBool() then
if SERVER then if SERVER then
ply:EmitSound("misc/totsugeki" .. math.random(1, 2) .. ".mp3", 60, 100, 1, CHAN_VOICE) if GetConVar("Beatrun_TotsugekiAudio"):GetBool() then
ply:EmitSound("misc/totsugeki" .. math.random(1, 2) .. ".mp3", 60, 100, 1, CHAN_VOICE)
end
local vPoint = mv:GetOrigin() local vPoint = mv:GetOrigin()
local effectdata = EffectData() local effectdata = EffectData()

View file

@ -3,6 +3,11 @@ if game.SinglePlayer() and SERVER then
end end
local landang = Angle(0, 0, 0) local landang = Angle(0, 0, 0)
local lastGroundSpeed = 0
if CLIENT then
local loseSpeed = CreateClientConVar("Beatrun_LoseSpeedOnRoll", 1, true, true, language.GetPhrase("beatrun.convars.loseSpeedOnRoll"), 0, 1)
end
local function SafetyRollThink(ply, mv, cmd) local function SafetyRollThink(ply, mv, cmd)
local speed = mv:GetVelocity().z local speed = mv:GetVelocity().z
@ -12,13 +17,18 @@ local function SafetyRollThink(ply, mv, cmd)
mv:SetButtons(bit.band(mv:GetButtons(), bit.bnot(IN_DUCK))) mv:SetButtons(bit.band(mv:GetButtons(), bit.bnot(IN_DUCK)))
end end
local isRolling = CurTime() < ply:GetSafetyRollKeyTime()
if ply:OnGround() and not isRolling then
lastGroundSpeed = mv:GetVelocity():Length()
end
if CurTime() < ply:GetSafetyRollTime() then if CurTime() < ply:GetSafetyRollTime() then
ply.FootstepLand = false ply.FootstepLand = false
local ang = ply:GetSafetyRollAng() local ang = ply:GetSafetyRollAng()
mv:SetSideSpeed(0) mv:SetSideSpeed(0)
mv:SetForwardSpeed(0) mv:SetForwardSpeed(0)
mv:AddKey(IN_DUCK) mv:AddKey(IN_DUCK)
@ -28,9 +38,17 @@ local function SafetyRollThink(ply, mv, cmd)
vel.x = 0 vel.x = 0
vel.y = 0 vel.y = 0
mv:SetVelocity(ply:GetSafetyRollAng():Forward() * 200 + vel) local con = GetConVar("Beatrun_LoseSpeedOnRoll")
ply:SetMEMoveLimit(400) if (con:GetBool()) then
mv:SetVelocity(ang:Forward() * 225 + vel)
else
local speedLimit = GetConVar("Beatrun_SpeedLimit"):GetFloat()
local max = math.max(250, math.Clamp(lastGroundSpeed, 200, speedLimit + 50))
mv:SetVelocity(ang:Forward() * (max + 40))
end
ply:SetMEMoveLimit(450)
else else
mv:SetVelocity(vector_origin) mv:SetVelocity(vector_origin)
end end
@ -93,7 +111,7 @@ hook.Add("SetupMove", "EvadeRoll", function(ply, mv, cmd)
ang.x = 0 ang.x = 0
ang.z = 0 ang.z = 0
ang:RotateAroundAxis(Vector(0, 0, 1), 180) ang:RotateAroundAxis(Vector(0, 0, 1), 180)
ply:SetJumpTurn(false) ply:SetJumpTurn(false)
ply:SetSafetyRollAng(ang) ply:SetSafetyRollAng(ang)
ply:SetSafetyRollTime(CurTime() + 0.9) ply:SetSafetyRollTime(CurTime() + 0.9)
@ -110,6 +128,8 @@ hook.Add("SetupMove", "EvadeRoll", function(ply, mv, cmd)
ply:EmitSound("Land.Concrete") ply:EmitSound("Land.Concrete")
end end
BodyAnim:SetAngles(Angle(0, ply:EyeAngles().y, 0))
if CLIENT and IsFirstTimePredicted() then if CLIENT and IsFirstTimePredicted() then
CacheBodyAnim() CacheBodyAnim()
RemoveBodyAnim() RemoveBodyAnim()