diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/en/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/en/beatrun.properties index e9b9b81..ea2b1eb 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/en/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/en/beatrun.properties @@ -42,6 +42,7 @@ beatrun.convars.puristmode=Purist mode is a clientside preference that severely beatrun.convars.quickturnground=Toggles quickturning with secondary attack while on the ground beatrun.convars.quickturnhandsonly=Toggles quickturning with "Runner Hands" only beatrun.convars.showspeedometer=Toggle speedometer visibility +beatrun.convars.speedometermode=Change speedometer mode # HUD beatrun.hud.course=Course: %s @@ -111,6 +112,9 @@ beatrun.toolsmenu.hud.hudxpdesc=Shows total XP near your nickname beatrun.toolsmenu.hud.showspeedometer=Show Speedometer beatrun.toolsmenu.hud.showspeedometerdesc=Shows the speedometer on HUD +beatrun.toolsmenu.hud.speedometermode=Speedometer Mode +beatrun.toolsmenu.hud.speedometermodedesc=0 - km/h, 1 - mph, 2 - hu/h + beatrun.toolsmenu.hud.showSpeedometer=Show Speedometer beatrun.toolsmenu.hud.showSpeedometerDesc=Shows the speedometer on HUD (hiding HUD does not affect visibility) @@ -172,6 +176,9 @@ beatrun.toolsmenu.misc.overdrivempdesc=Allows Overdrive usage on the server beatrun.toolsmenu.misc.healthregen=Health Regen beatrun.toolsmenu.misc.healthregendesc=Toggles Health Regeneration +beatrun.toolsmenu.misc.lerealisticclimbing=Realistic climbing +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Doesn't allow you to wallrun or climb unless you have your runnerhands on. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Moves beatrun.toolsmenu.moves.desc=Moves Settings @@ -245,6 +252,8 @@ beatrun.checkpoints.countdown1=Ready beatrun.checkpoints.countdown2=Set beatrun.checkpoints.countdown3=GO! beatrun.checkpoints.speedometer=%s km/h +beatrun.checkpoints.speedometer_miles=%s mph +beatrun.checkpoints.speedometer_hammerunits=%s hu/h # DataTheft beatrun.datatheft.name=Data Theft (%s) diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/it/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/it/beatrun.properties index a43c364..4e748d1 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/it/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/it/beatrun.properties @@ -149,8 +149,13 @@ beatrun.toolsmenu.misc.desc=Impostazioni Varie beatrun.toolsmenu.misc.propspawn=Prop Spawning beatrun.toolsmenu.misc.propspawndesc=Consente ai giocatori senza diritti di amministratore di generare oggetti di scena, entità e armi + beatrun.toolsmenu.misc.overdrivemp=Overdrive in Multiplayer beatrun.toolsmenu.misc.overdrivempdesc=Consente l'utilizzo dell'Overdrive sul server + +beatrun.toolsmenu.misc.lerealisticclimbing=Arrampicata realistica +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Non ti consente di correre sui muri o di arrampicarti se non hai le mani da corridore. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Mosse beatrun.toolsmenu.moves.desc=Impostazioni Mosse @@ -211,6 +216,8 @@ beatrun.checkpoints.countdown1=Pronti! beatrun.checkpoints.countdown2=Partenza... beatrun.checkpoints.countdown3=VIA!! beatrun.checkpoints.speedometer=%s km/h +beatrun.checkpoints.speedometer_miles=%s mph +beatrun.checkpoints.speedometer_hammerunits=%s hu/h # DataTheft beatrun.datatheft.name=Furto di dati (%s) diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/pl/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/pl/beatrun.properties index 16b751f..42c12b6 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/pl/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/pl/beatrun.properties @@ -42,6 +42,7 @@ beatrun.convars.puristmode=Tryb purystyczny to opcja po stronie klienta, która beatrun.convars.quickturnground=Umożliwia szybki obrót za pomocą ataku drugorzędnego na ziemi beatrun.convars.quickturnhandsonly=Umożliwia szybki obrót tylko w trybie "Rąk biegacza" beatrun.convars.showspeedometer=Przełącz widoczność prędkościomierza +beatrun.convars.speedometermode=Zmień tryb prędkościomierza # HUD beatrun.hud.course=Bieg: %s @@ -111,6 +112,9 @@ beatrun.toolsmenu.hud.hudxpdesc=Pokaż całkowitą liczbę PD w pobliżu swojego beatrun.toolsmenu.hud.showspeedometer=Pokaż prędkościomierz beatrun.toolsmenu.hud.showspeedometerdesc=Pokazuje prędkościomierz na interfejsie +beatrun.toolsmenu.hud.speedometermode=Tryb prędkościomierza +beatrun.toolsmenu.hud.speedometermodedesc=0 - km/h, 1 - mph, 2 - hu/h + beatrun.toolsmenu.hud.showSpeedometer=Pokaż prędkościomierz beatrun.toolsmenu.hud.showSpeedometerDesc=Pokazuje prędkościomierz na interfejsie (ukrycie interfejsu nie wpływa na to ustawienie) @@ -172,6 +176,9 @@ beatrun.toolsmenu.misc.overdrivempdesc=Umożliwia korzystanie z dopalenia na ser beatrun.toolsmenu.misc.healthregen=Regeneracja zdrowia beatrun.toolsmenu.misc.healthregendesc=Włącz/Wyłącz regenerację zdrowia +beatrun.toolsmenu.misc.lerealisticclimbing=Realistyczna wspinaczka +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Nie pozwala na bieganie po ścianach ani wspinaczkę, jeśli nie masz na sobie rąk przystosowanych do biegania. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Ruchy beatrun.toolsmenu.moves.desc=Ustawienia ruchów @@ -245,6 +252,8 @@ beatrun.checkpoints.countdown1=Gotowy beatrun.checkpoints.countdown2=Do startu beatrun.checkpoints.countdown3=START! beatrun.checkpoints.speedometer=%s km/h +beatrun.checkpoints.speedometer_miles=%s mph +beatrun.checkpoints.speedometer_hammerunits=%s hu/h # DataTheft beatrun.datatheft.name=Kradzież danych (%s) diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/pt-BR/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/pt-BR/beatrun.properties index b4a6875..d2785a2 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/pt-BR/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/pt-BR/beatrun.properties @@ -155,6 +155,9 @@ beatrun.toolsmenu.misc.propspawndesc=Permite Jogadores sem privilegios adiminist beatrun.toolsmenu.misc.overdrivemp=Overdrive No Multijogador beatrun.toolsmenu.misc.overdrivempdesc=Permite o uso de Overdrive no servidor +beatrun.toolsmenu.misc.lerealisticclimbing=Escalada realista +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Não permite que você corra na parede ou escale, a menos que você esteja com as mãos de corredor. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Movimentos beatrun.toolsmenu.moves.desc=Configurações de Movimentos @@ -215,7 +218,8 @@ beatrun.checkpoints.countdown1=Preparar beatrun.checkpoints.countdown2=Apontar beatrun.checkpoints.countdown3=VAI! beatrun.checkpoints.speedometer=%s km/h - +beatrun.checkpoints.speedometer_miles=%s mph +beatrun.checkpoints.speedometer_hammerunits=%s hu/h # DataTheft beatrun.datatheft.name=Roubo de Data (%s) beatrun.datatheft.start=Roubo de Data! Mate Jogadores para coletar Data, deposite data em bancos diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/ru/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/ru/beatrun.properties index fe90302..7f5ce00 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/ru/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/ru/beatrun.properties @@ -42,6 +42,7 @@ beatrun.convars.puristmode=Режим Purist это клиентский пар beatrun.convars.quickturnground=Переключает Quickturn будучи на земле beatrun.convars.quickturnhandsonly=Переключает Quickturn только с "Runner Hands" beatrun.convars.showspeedometer=Переключает спидометр +beatrun.convars.speedometermode=Меняет режим спидометра # HUD beatrun.hud.course=Курс: %s @@ -111,6 +112,9 @@ beatrun.toolsmenu.hud.hudxpdesc=Показывает весь XP в HUD beatrun.toolsmenu.hud.showspeedometer=Показать спидометр beatrun.toolsmenu.hud.showspeedometerdesc=Показывает спидометр в HUD +beatrun.toolsmenu.hud.speedometermode=Режим спидометра +beatrun.toolsmenu.hud.speedometermodedesc=0 - км/ч, 1 - миль/ч, 2 - хе/ч + beatrun.toolsmenu.hud.keystrokes=Показывать клавиши beatrun.toolsmenu.hud.keystrokesdesc=Показывает нажатие клавиш в HUD @@ -169,6 +173,9 @@ beatrun.toolsmenu.misc.overdrivempdesc=Разрешает использован beatrun.toolsmenu.misc.healthregen=Регенерация здоровья beatrun.toolsmenu.misc.healthregendesc=Переключает регенерацию здоровья +beatrun.toolsmenu.misc.lerealisticclimbing=Реалистичный паркур +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Не даёт бегать по стенам и подниматься за края, если не взяты в руки... бегающие руки. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Движения beatrun.toolsmenu.moves.desc=Настройки движений @@ -242,6 +249,9 @@ beatrun.checkpoints.countdown1=Раз beatrun.checkpoints.countdown2=Два beatrun.checkpoints.countdown3=ПОШЁЛ! beatrun.checkpoints.speedometer=%s км/ч +beatrun.checkpoints.speedometer_miles=%s миля/ч +beatrun.checkpoints.speedometer_hammerunits=%s хе/ч +# хе/ч - ну и бред) # DataTheft beatrun.datatheft.name=Data Theft (%s) diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/tr/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/tr/beatrun.properties index a9c9fc3..5dcf3e7 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/tr/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/tr/beatrun.properties @@ -155,6 +155,9 @@ beatrun.toolsmenu.misc.propspawndesc=Yönetici hakları olmayan oyuncuların nes beatrun.toolsmenu.misc.overdrivemp=Çok Oyunculuda Aşım beatrun.toolsmenu.misc.overdrivempdesc=Sunucuda aşım kullanımına izin verir +beatrun.toolsmenu.misc.lerealisticclimbing=Gerçekçi tırmanma +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Koşu eldivenlerinizi takmadığınız sürece duvar koşusu yapmanıza veya tırmanmanıza izin vermez. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Hareketler beatrun.toolsmenu.moves.desc=Hareket Ayarları diff --git a/beatrun/gamemodes/beatrun/content/resource/localization/uk/beatrun.properties b/beatrun/gamemodes/beatrun/content/resource/localization/uk/beatrun.properties index e616b40..a75bd0a 100644 --- a/beatrun/gamemodes/beatrun/content/resource/localization/uk/beatrun.properties +++ b/beatrun/gamemodes/beatrun/content/resource/localization/uk/beatrun.properties @@ -165,6 +165,9 @@ beatrun.toolsmenu.misc.overdrivempdesc=Дозволяє використання beatrun.toolsmenu.misc.healthregen=Регенерація здоров'я beatrun.toolsmenu.misc.healthregendesc=Перемикає регенерацію здоров'я +beatrun.toolsmenu.misc.lerealisticclimbing=Реалістичний паркур +beatrun.toolsmenu.misc.lerealisticclimbingdesc=Не дає бігати по стінах і підніматися за краї, якщо не взяті в руки... руки, що бігають. + # Tools Menu Moves Section beatrun.toolsmenu.moves.name=Рухи beatrun.toolsmenu.moves.desc=Налаштування рухів diff --git a/beatrun/gamemodes/beatrun/gamemode/cl/BodyAnim.lua b/beatrun/gamemodes/beatrun/gamemode/cl/BodyAnim.lua index c3eb69b..ad1010f 100644 --- a/beatrun/gamemodes/beatrun/gamemode/cl/BodyAnim.lua +++ b/beatrun/gamemodes/beatrun/gamemode/cl/BodyAnim.lua @@ -670,19 +670,20 @@ function BodyAnimCalcView2(ply, pos, angles, fov) end if not ply:ShouldDrawLocalPlayer() and not ply:InVehicle() then - local ang = ply:GetAngles() + local ang = Vector(view.angles:Unpack()) local FT = RealFrameTime() ang[1] = 0 ang[3] = 0 - local MEAng = math.Truncate(ang.y, 2) + local MEAng = ang.y local target = not lockang and MEAng or ply.OrigEyeAng.y - viewtiltlerp.y = math.ApproachAngle(viewtiltlerp.y, target, FT * (1 + math.abs(math.AngleDifference(viewtiltlerp.y, target)) * 5)) + viewtiltlerp.y = math.ApproachAngle(viewtiltlerp.y, target, FrameTime() * (1 + math.abs(math.AngleDifference(viewtiltlerp.y, target)) * 5)) local MEAngDiff = math.AngleDifference(viewtiltlerp.y, not lockang and lastangy or ply.OrigEyeAng.y) * 0.15 ViewTiltAngle = Angle(0, 0, MEAngDiff + viewtiltlerp.z) + view.angles:Add(ViewTiltAngle) ply:SetNoDraw(false) diff --git a/beatrun/gamemodes/beatrun/gamemode/cl/ToolMenuSettings.lua b/beatrun/gamemodes/beatrun/gamemode/cl/ToolMenuSettings.lua index 16ae891..edd9669 100644 --- a/beatrun/gamemodes/beatrun/gamemode/cl/ToolMenuSettings.lua +++ b/beatrun/gamemodes/beatrun/gamemode/cl/ToolMenuSettings.lua @@ -170,6 +170,9 @@ hook.Add("PopulateToolMenu", "Beatrun_ToolMenu", function() panel:CheckBox("#beatrun.toolsmenu.hud.keystrokes", "Beatrun_ShowKeystrokes") panel:ControlHelp("#beatrun.toolsmenu.hud.keystrokesdesc") + panel:NumSlider("#beatrun.toolsmenu.hud.speedometermode", "Beatrun_SpeedometerMode", 0, 2, 0) + panel:ControlHelp("#beatrun.toolsmenu.hud.speedometermodedesc") + panel:NumSlider("#beatrun.toolsmenu.hud.hidden", "Beatrun_HUDHidden", 0, 2, 0) panel:ControlHelp(language.GetPhrase("beatrun.toolsmenu.hud.hiddendesc")) @@ -267,6 +270,11 @@ hook.Add("PopulateToolMenu", "Beatrun_ToolMenu", function() panel:CheckBox("#beatrun.toolsmenu.misc.healthregen", "Beatrun_HealthRegen") panel:ControlHelp("#beatrun.toolsmenu.misc.healthregendesc") + + panel:CheckBox("#beatrun.toolsmenu.misc.lerealisticclimbing", "Beatrun_LeRealisticClimbing") + panel:ControlHelp("#beatrun.toolsmenu.misc.lerealisticclimbingdesc") + + end) spawnmenu.AddToolMenuOption("Beatrun", "Server", "beatrun_moves", "#beatrun.toolsmenu.moves.name", "", "", function(panel) diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Checkpoints.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Checkpoints.lua index e02fcb2..a9f0465 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Checkpoints.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Checkpoints.lua @@ -20,6 +20,7 @@ local timecolor = color_neutral if CLIENT then CreateClientConVar("Beatrun_ShowSpeedometer", 1, true, true, language.GetPhrase("#beatrun.convars.showspeedometer"), 0, 1) CreateClientConVar("Beatrun_HUDStats", "0", true, false, "", 0, 1) + CreateClientConVar("Beatrun_SpeedometerMode", 0, true, true, language.GetPhrase("#beatrun.convars.showspeedometer"), 0, 2) end if SERVER then @@ -247,13 +248,30 @@ function CourseHUD() end if GetConVar("Beatrun_ShowSpeedometer"):GetBool() and GetConVar("Beatrun_HUDHidden"):GetInt() ~= 2 then - local speed = math.Round(ply:GetVelocity():Length() * 0.06858125) + local speed = 0 + + local mode = GetConVar("Beatrun_SpeedometerMode"):GetInt() + if mode == 0 then // km/h + speed = math.Round(ply:GetVelocity():Length() * 0.06858125) + elseif mode == 1 then // mph + speed = math.Round(ply:GetVelocity():Length() * 0.11037055) + elseif mode == 2 then // hu/h + speed = math.Round(ply:GetVelocity():Length()) + end if speed < 10 then speed = "0" .. speed end - text = language.GetPhrase("beatrun.checkpoints.speedometer"):format(speed) + local text = "" + + if mode == 0 then // km/h + text = language.GetPhrase("beatrun.checkpoints.speedometer"):format(speed) + elseif mode == 1 then // mph + text = language.GetPhrase("beatrun.checkpoints.speedometer_miles"):format(speed) + elseif mode == 2 then // hu/h + text = language.GetPhrase("beatrun.checkpoints.speedometer_hammerunits"):format(speed) + end local w, _ = surface.GetTextSize(text) w = w or 0 diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua index 0d70075..a1fe372 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Climb.lua @@ -398,7 +398,11 @@ end hook.Add("StartCommand", "ClimbingRemoveInput", ClimbingRemoveInput) +local realistic = CreateConVar("Beatrun_LeRealisticClimbing", "0", FCVAR_ARCHIVE, "Makes you be able to climb and wallrun only if you have runnerhands equipped.") + local function ClimbingCheck(ply, mv, cmd) + if realistic:GetBool() and not ply:UsingRH() then return end + local mins, maxs = ply:GetHull() if not ply.ClimbingTrace then diff --git a/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua b/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua index b956f17..a85036f 100644 --- a/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua +++ b/beatrun/gamemodes/beatrun/gamemode/sh/Wallrun.lua @@ -342,7 +342,11 @@ end -- local upcheck = Vector(0, 0, 75) +local realistic = GetConVar("Beatrun_LeRealisticClimbing") + local function WallrunningCheck(ply, mv, cmd) + if realistic:GetBool() and not ply:UsingRH() then return end + if not ply.WallrunTrace then ply.WallrunTrace = {} ply.WallrunTraceOut = {} diff --git a/version.txt b/version.txt index 2fa3901..1c2de38 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -1.0.22 \ No newline at end of file +1.0.23 \ No newline at end of file