From b04fd79132675dd68bd63bdfe91faaa28fc50fc1 Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Sat, 10 Dec 2022 22:36:52 -0600 Subject: [PATCH 1/6] Initial commit --- .gitattributes | 2 + .gitignore | 398 +++++++++++++++++++++++++++++++++++++++++++++++++ LICENSE | 21 +++ README.md | 2 + 4 files changed, 423 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 LICENSE create mode 100644 README.md diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..dfe0770 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Auto detect text files and perform LF normalization +* text=auto diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..426d76d --- /dev/null +++ b/.gitignore @@ -0,0 +1,398 @@ +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. +## +## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore + +# User-specific files +*.rsuser +*.suo +*.user +*.userosscache +*.sln.docstates + +# User-specific files (MonoDevelop/Xamarin Studio) +*.userprefs + +# Mono auto generated files +mono_crash.* + +# Build results +[Dd]ebug/ +[Dd]ebugPublic/ +[Rr]elease/ +[Rr]eleases/ +x64/ +x86/ +[Ww][Ii][Nn]32/ +[Aa][Rr][Mm]/ +[Aa][Rr][Mm]64/ +bld/ +[Bb]in/ +[Oo]bj/ +[Ll]og/ +[Ll]ogs/ + +# Visual Studio 2015/2017 cache/options directory +.vs/ +# Uncomment if you have tasks that create the project's static files in wwwroot +#wwwroot/ + +# Visual Studio 2017 auto generated files +Generated\ Files/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +# NUnit +*.VisualState.xml +TestResult.xml +nunit-*.xml + +# Build Results of an ATL Project +[Dd]ebugPS/ +[Rr]eleasePS/ +dlldata.c + +# Benchmark Results +BenchmarkDotNet.Artifacts/ + +# .NET Core +project.lock.json +project.fragment.lock.json +artifacts/ + +# ASP.NET Scaffolding +ScaffoldingReadMe.txt + +# StyleCop +StyleCopReport.xml + +# Files built by Visual Studio +*_i.c +*_p.c +*_h.h +*.ilk +*.meta +*.obj +*.iobj +*.pch +*.pdb +*.ipdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*_wpftmp.csproj +*.log +*.tlog +*.vspscc +*.vssscc +.builds +*.pidb +*.svclog +*.scc + +# Chutzpah Test files +_Chutzpah* + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opendb +*.opensdf +*.sdf +*.cachefile +*.VC.db +*.VC.VC.opendb + +# Visual Studio profiler +*.psess +*.vsp +*.vspx +*.sap + +# Visual Studio Trace Files +*.e2e + +# TFS 2012 Local Workspace +$tf/ + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper +*.DotSettings.user + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# AxoCover is a Code Coverage Tool +.axoCover/* +!.axoCover/settings.json + +# Coverlet is a free, cross platform Code Coverage Tool +coverage*.json +coverage*.xml +coverage*.info + +# Visual Studio code coverage results +*.coverage +*.coveragexml + +# NCrunch +_NCrunch_* +.*crunch*.local.xml +nCrunchTemp_* + +# MightyMoose +*.mm.* +AutoTest.Net/ + +# Web workbench (sass) +.sass-cache/ + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.[Pp]ublish.xml +*.azurePubxml +# Note: Comment the next line if you want to checkin your web deploy settings, +# but database connection strings (with potential passwords) will be unencrypted +*.pubxml +*.publishproj + +# Microsoft Azure Web App publish settings. Comment the next line if you want to +# checkin your Azure Web App publish settings, but sensitive information contained +# in these scripts will be unencrypted +PublishScripts/ + +# NuGet Packages +*.nupkg +# NuGet Symbol Packages +*.snupkg +# The packages folder can be ignored because of Package Restore +**/[Pp]ackages/* +# except build/, which is used as an MSBuild target. +!**/[Pp]ackages/build/ +# Uncomment if necessary however generally it will be regenerated when needed +#!**/[Pp]ackages/repositories.config +# NuGet v3's project.json files produces more ignorable files +*.nuget.props +*.nuget.targets + +# Microsoft Azure Build Output +csx/ +*.build.csdef + +# Microsoft Azure Emulator +ecf/ +rcf/ + +# Windows Store app package directories and files +AppPackages/ +BundleArtifacts/ +Package.StoreAssociation.xml +_pkginfo.txt +*.appx +*.appxbundle +*.appxupload + +# Visual Studio cache files +# files ending in .cache can be ignored +*.[Cc]ache +# but keep track of directories ending in .cache +!?*.[Cc]ache/ + +# Others +ClientBin/ +~$* +*~ +*.dbmdl +*.dbproj.schemaview +*.jfm +*.pfx +*.publishsettings +orleans.codegen.cs + +# Including strong name files can present a security risk +# (https://github.com/github/gitignore/pull/2483#issue-259490424) +#*.snk + +# Since there are multiple workflows, uncomment next line to ignore bower_components +# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) +#bower_components/ + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file +# to a newer Visual Studio version. Backup files are not needed, +# because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm +ServiceFabricBackup/ +*.rptproj.bak + +# SQL Server files +*.mdf +*.ldf +*.ndf + +# Business Intelligence projects +*.rdl.data +*.bim.layout +*.bim_*.settings +*.rptproj.rsuser +*- [Bb]ackup.rdl +*- [Bb]ackup ([0-9]).rdl +*- [Bb]ackup ([0-9][0-9]).rdl + +# Microsoft Fakes +FakesAssemblies/ + +# GhostDoc plugin setting file +*.GhostDoc.xml + +# Node.js Tools for Visual Studio +.ntvs_analysis.dat +node_modules/ + +# Visual Studio 6 build log +*.plg + +# Visual Studio 6 workspace options file +*.opt + +# Visual Studio 6 auto-generated workspace file (contains which files were open etc.) +*.vbw + +# Visual Studio 6 auto-generated project file (contains which files were open etc.) +*.vbp + +# Visual Studio 6 workspace and project file (working project files containing files to include in project) +*.dsw +*.dsp + +# Visual Studio 6 technical files +*.ncb +*.aps + +# Visual Studio LightSwitch build output +**/*.HTMLClient/GeneratedArtifacts +**/*.DesktopClient/GeneratedArtifacts +**/*.DesktopClient/ModelManifest.xml +**/*.Server/GeneratedArtifacts +**/*.Server/ModelManifest.xml +_Pvt_Extensions + +# Paket dependency manager +.paket/paket.exe +paket-files/ + +# FAKE - F# Make +.fake/ + +# CodeRush personal settings +.cr/personal + +# Python Tools for Visual Studio (PTVS) +__pycache__/ +*.pyc + +# Cake - Uncomment if you are using it +# tools/** +# !tools/packages.config + +# Tabs Studio +*.tss + +# Telerik's JustMock configuration file +*.jmconfig + +# BizTalk build output +*.btp.cs +*.btm.cs +*.odx.cs +*.xsd.cs + +# OpenCover UI analysis results +OpenCover/ + +# Azure Stream Analytics local run output +ASALocalRun/ + +# MSBuild Binary and Structured Log +*.binlog + +# NVidia Nsight GPU debugger configuration file +*.nvuser + +# MFractors (Xamarin productivity tool) working folder +.mfractor/ + +# Local History for Visual Studio +.localhistory/ + +# Visual Studio History (VSHistory) files +.vshistory/ + +# BeatPulse healthcheck temp database +healthchecksdb + +# Backup folder for Package Reference Convert tool in Visual Studio 2017 +MigrationBackup/ + +# Ionide (cross platform F# VS Code tools) working folder +.ionide/ + +# Fody - auto-generated XML schema +FodyWeavers.xsd + +# VS Code files for those working on multiple tools +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json +*.code-workspace + +# Local History for Visual Studio Code +.history/ + +# Windows Installer files from build outputs +*.cab +*.msi +*.msix +*.msm +*.msp + +# JetBrains Rider +*.sln.iml diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..262b1ec --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2022 NotAKidoS + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..06f02c1 --- /dev/null +++ b/README.md @@ -0,0 +1,2 @@ +# PathCamDisabler + From ffa50bee02d962a3030b13a1363f03fa1bbaf3a1 Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Sat, 10 Dec 2022 23:02:32 -0600 Subject: [PATCH 2/6] initial Allows for disabling the CVRPathCamController monobehavior. Lets players to use the numpad keys without being interrupted by the path camera. Also additional setting to disable the flight bind, as that is handled by the CVRPathCamController...? --- PathCamDisabler/Main.cs | 52 +++++++++++++++ PathCamDisabler/PathCamDisabler.csproj | 76 ++++++++++++++++++++++ PathCamDisabler/PathCamDisabler.sln | 25 +++++++ PathCamDisabler/Properties/AssemblyInfo.cs | 30 +++++++++ PathCamDisabler/format.json | 23 +++++++ 5 files changed, 206 insertions(+) create mode 100644 PathCamDisabler/Main.cs create mode 100644 PathCamDisabler/PathCamDisabler.csproj create mode 100644 PathCamDisabler/PathCamDisabler.sln create mode 100644 PathCamDisabler/Properties/AssemblyInfo.cs create mode 100644 PathCamDisabler/format.json diff --git a/PathCamDisabler/Main.cs b/PathCamDisabler/Main.cs new file mode 100644 index 0000000..4d21597 --- /dev/null +++ b/PathCamDisabler/Main.cs @@ -0,0 +1,52 @@ +using ABI_RC.Core.Player; +using ABI_RC.Core.IO; +using MelonLoader; +using UnityEngine; + +namespace PathCamDisabler; + +public class PathCamDisabler : MelonMod +{ + private static MelonPreferences_Category m_categoryPathCamDisabler; + private static MelonPreferences_Entry m_entryDisablePathCam, m_entryDisableFlightBind; + + public override void OnInitializeMelon() + { + m_categoryPathCamDisabler = MelonPreferences.CreateCategory(nameof(PathCamDisabler)); + m_entryDisablePathCam = m_categoryPathCamDisabler.CreateEntry("Disable Path Camera Controller.", true, description: "Disable path camera controller so you can use your numpad keys without funky shit."); + m_entryDisableFlightBind = m_categoryPathCamDisabler.CreateEntry("Disable Flight Binding (if controller off).", false, description: "Disables the flight binding as the path camera controller handles that...?"); + m_categoryPathCamDisabler.SaveToFile(false); + + foreach (var setting in m_categoryPathCamDisabler.Entries) + { + setting.OnEntryValueChangedUntyped.Subscribe(OnUpdateSettings); + } + + MelonLoader.MelonCoroutines.Start(WaitForLocalPlayer()); + } + + System.Collections.IEnumerator WaitForLocalPlayer() + { + while (CVRPathCamController.Instance == null) + yield return null; + UpdateSettings(); + } + + private void UpdateSettings() + { + CVRPathCamController.Instance.enabled = !m_entryDisablePathCam.Value; + } + + private void OnUpdateSettings(object arg1, object arg2) => UpdateSettings(); + + public override void OnUpdate() + { + if (m_entryDisablePathCam.Value && !m_entryDisableFlightBind.Value) + { + if (Input.GetKeyDown(KeyCode.Keypad5)) + { + PlayerSetup.Instance._movementSystem.ToggleFlight(); + } + } + } +} \ No newline at end of file diff --git a/PathCamDisabler/PathCamDisabler.csproj b/PathCamDisabler/PathCamDisabler.csproj new file mode 100644 index 0000000..703e8cc --- /dev/null +++ b/PathCamDisabler/PathCamDisabler.csproj @@ -0,0 +1,76 @@ + + + + + net472 + enable + latest + false + + + + + + + + + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\MelonLoader\0Harmony.dll + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\Assembly-CSharp.dll + + + ..\..\..\..\..\..\..\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\Assembly-CSharp-firstpass.dll + + + ..\..\..\..\..\..\..\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\Cohtml.Runtime.dll + + + ..\..\Giamoz\Giamoz\bin\Debug\net472\Giamoz.dll + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\MelonLoader\MelonLoader.dll + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\SteamVR.dll + + + ..\..\..\..\..\..\..\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\UnityEngine.AnimationModule.dll + + + ..\..\..\..\..\..\..\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\UnityEngine.AssetBundleModule.dll + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\UnityEngine.CoreModule.dll + + + C:\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\UnityEngine.InputLegacyModule.dll + + + ..\..\..\..\..\..\..\Program Files (x86)\Steam\steamapps\common\ChilloutVR\ChilloutVR_Data\Managed\UnityEngine.PhysicsModule.dll + + + + + + True + True + Resource1.resx + + + + + + ResXFileCodeGenerator + Resource1.Designer.cs + + + + + + + + + diff --git a/PathCamDisabler/PathCamDisabler.sln b/PathCamDisabler/PathCamDisabler.sln new file mode 100644 index 0000000..1f80bd8 --- /dev/null +++ b/PathCamDisabler/PathCamDisabler.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 17 +VisualStudioVersion = 17.2.32630.192 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "PathCamDisabler", "PathCamDisabler.csproj", "{010592B6-9D1E-49D8-B4B2-6D5A6BCF5405}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {010592B6-9D1E-49D8-B4B2-6D5A6BCF5405}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {010592B6-9D1E-49D8-B4B2-6D5A6BCF5405}.Debug|Any CPU.Build.0 = Debug|Any CPU + {010592B6-9D1E-49D8-B4B2-6D5A6BCF5405}.Release|Any CPU.ActiveCfg = Release|Any CPU + {010592B6-9D1E-49D8-B4B2-6D5A6BCF5405}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {116A47FE-B7C5-4C2A-8437-5D5357FE783F} + EndGlobalSection +EndGlobal diff --git a/PathCamDisabler/Properties/AssemblyInfo.cs b/PathCamDisabler/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..652ae4d --- /dev/null +++ b/PathCamDisabler/Properties/AssemblyInfo.cs @@ -0,0 +1,30 @@ +using PathCamDisabler.Properties; +using MelonLoader; +using System.Reflection; + + +[assembly: AssemblyVersion(AssemblyInfoParams.Version)] +[assembly: AssemblyFileVersion(AssemblyInfoParams.Version)] +[assembly: AssemblyInformationalVersion(AssemblyInfoParams.Version)] +[assembly: AssemblyTitle(nameof(PathCamDisabler))] +[assembly: AssemblyCompany(AssemblyInfoParams.Author)] +[assembly: AssemblyProduct(nameof(PathCamDisabler))] + +[assembly: MelonInfo( + typeof(PathCamDisabler.PathCamDisabler), + nameof(PathCamDisabler), + AssemblyInfoParams.Version, + AssemblyInfoParams.Author, + downloadLink: "https://github.com/NotAKidOnSteam/PathCamDisabler" +)] + +[assembly: MelonGame("Alpha Blend Interactive", "ChilloutVR")] +[assembly: MelonPlatform(MelonPlatformAttribute.CompatiblePlatforms.WINDOWS_X64)] +[assembly: MelonPlatformDomain(MelonPlatformDomainAttribute.CompatibleDomains.MONO)] + +namespace PathCamDisabler.Properties; +internal static class AssemblyInfoParams +{ + public const string Version = "1.0.0"; + public const string Author = "NotAKidoS"; +} \ No newline at end of file diff --git a/PathCamDisabler/format.json b/PathCamDisabler/format.json new file mode 100644 index 0000000..b493eea --- /dev/null +++ b/PathCamDisabler/format.json @@ -0,0 +1,23 @@ +{ + "_id": -1, + "name": "PathCamDisabler", + "modversion": "1.0.0", + "gameversion": "2022r169", + "loaderversion": "0.5.7", + "modtype": "Mod", + "author": "NotAKidoS", + "description": "Disables path camera controller to free up your numkeys. Additional option to disable the flight binding. \n\n Won't do much for VR. Can toggle with UIExpansionKit or similar.", + "searchtags": [ + "numpad", + "camera", + "pathing", + "path" + ], + "requirements": [ + "None" + ], + "downloadlink": "https://github.com/NotAKidOnSteam/PathCamDisabler/releases/download/r1/PathCamDisabler.dll", + "sourcelink": "https://github.com/NotAKidOnSteam/PathCamDisabler/", + "changelog": "sign initials here", + "embedcolor": "#9b59b6" +} \ No newline at end of file From a355f6ae4554a32948acaefc30fbc3d2463678a7 Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Sat, 10 Dec 2022 23:12:59 -0600 Subject: [PATCH 3/6] Update README.md --- README.md | 55 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/README.md b/README.md index 06f02c1..0c25ae6 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,57 @@ # PathCamDisabler +> In the midst of a party, with friends all around +> The player chatted and laughed, a joyous sound +> +> But then, oh no, a cruel twist of fate +> Their numpad keys spawned path camera points, a terrible fate +> +> The camera shifted, spinning out of control +> Distracting and disorienting, taking its toll +> +> The player struggled, trying to focus and socialize +> But the path camera points just wouldn't let up, a never-ending surprise +> +> But then, at last, a glimmer of hope +> The player installed a mod, PathCamDisabler, with a single stroke +> +> The path camera points vanished, gone in a flash +> And the player breathed a sigh of relief, their struggles now past +> +> With camera control restored, the player socialized on +> Having a great time, their struggles now gone +> +> Thanks to PathCamDisabler, their troubles were through +> And the player could focus on the party, finally feeling brand new. +> +> Sincerely, +> Assistant (OpenAI) + +Disables the CVRPathCameraController by default while keeping the flight binding. + +Using UIExpansionKit or similar you can toggle both while in game. + +--- + +Here is the block of text where I tell you this mod is not affiliated or endorsed by ABI. +https://documentation.abinteractive.net/official/legal/tos/#7-modding-our-games + +> I am not affiliated with ABI in any official capacity, these mods are not endorsed or outright permitted by ABI and are subject to scrutiny. + +> Neither I nor these mods are in any way affiliated with Alpha Blend Interactive and/or ChilloutVR. Using these modifications might cause issues with the performance, security or stability of the game. Use at your own risk. + +> Any modifications that are not approved can get your ABI account terminated and such this modification is following the "modding guidelines" at the best it could be. +> They reserve the right to punish users using my mod. +> If you are scared of using modifications in your game do not install mods. + +> I do not affiliate ABI and the mod is not supported by ABI. + +> Me and this modification are in no affiliation with ABI and not supported by ABI. + +> This mod is not affiliated with Alpha Blend Interactive. The mod comes with no warranty. Use at your own risk, as I am not responsible for any misuse. + +> I'm not affiliated with Alpha Blend Interactive and this mod is not officially supported by the game. + +> When releasing mods to the public, it is required to state, that the mod authors and modification are in no affiliation with ABI and not supported by ABI. :trollface: + +> i ran out of places to steal disclaimers from From 214c15051157da1e538f7eadfa81f789eeb65b56 Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Sat, 10 Dec 2022 23:17:39 -0600 Subject: [PATCH 4/6] Update format.json --- PathCamDisabler/format.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/PathCamDisabler/format.json b/PathCamDisabler/format.json index b493eea..83fe58a 100644 --- a/PathCamDisabler/format.json +++ b/PathCamDisabler/format.json @@ -1,5 +1,5 @@ { - "_id": -1, + "_id": 110, "name": "PathCamDisabler", "modversion": "1.0.0", "gameversion": "2022r169", @@ -18,6 +18,6 @@ ], "downloadlink": "https://github.com/NotAKidOnSteam/PathCamDisabler/releases/download/r1/PathCamDisabler.dll", "sourcelink": "https://github.com/NotAKidOnSteam/PathCamDisabler/", - "changelog": "sign initials here", + "changelog": "initial release\n(i made this in 5 minutes after months of annoyances)", "embedcolor": "#9b59b6" } \ No newline at end of file From 1b188433a2f9d38bb355b63eaf33a05d74a5fe7b Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Thu, 9 Feb 2023 21:29:06 -0600 Subject: [PATCH 5/6] wasd --- PathCamDisabler/Main.cs | 71 +++++++++++----------- PathCamDisabler/Properties/AssemblyInfo.cs | 17 +++--- PathCamDisabler/format.json | 10 +-- 3 files changed, 47 insertions(+), 51 deletions(-) diff --git a/PathCamDisabler/Main.cs b/PathCamDisabler/Main.cs index 4d21597..0087741 100644 --- a/PathCamDisabler/Main.cs +++ b/PathCamDisabler/Main.cs @@ -1,51 +1,48 @@ -using ABI_RC.Core.Player; -using ABI_RC.Core.IO; +using ABI_RC.Core.IO; +using ABI_RC.Core.Player; using MelonLoader; using UnityEngine; -namespace PathCamDisabler; - -public class PathCamDisabler : MelonMod +namespace NAK.Melons.PathCamDisabler { - private static MelonPreferences_Category m_categoryPathCamDisabler; - private static MelonPreferences_Entry m_entryDisablePathCam, m_entryDisableFlightBind; - - public override void OnInitializeMelon() + public class PathCamDisablerMod : MelonMod { - m_categoryPathCamDisabler = MelonPreferences.CreateCategory(nameof(PathCamDisabler)); - m_entryDisablePathCam = m_categoryPathCamDisabler.CreateEntry("Disable Path Camera Controller.", true, description: "Disable path camera controller so you can use your numpad keys without funky shit."); - m_entryDisableFlightBind = m_categoryPathCamDisabler.CreateEntry("Disable Flight Binding (if controller off).", false, description: "Disables the flight binding as the path camera controller handles that...?"); - m_categoryPathCamDisabler.SaveToFile(false); + internal const string SettingsCategory = "PathCamDisabler"; + internal static MelonPreferences_Category m_categoryPathCamDisabler; + internal static MelonPreferences_Entry m_entryDisablePathCam, m_entryDisableFlightBind; - foreach (var setting in m_categoryPathCamDisabler.Entries) + public override void OnInitializeMelon() { - setting.OnEntryValueChangedUntyped.Subscribe(OnUpdateSettings); + m_categoryPathCamDisabler = MelonPreferences.CreateCategory(SettingsCategory); + m_entryDisablePathCam = m_categoryPathCamDisabler.CreateEntry("Disable Path Camera Controller.", true, description: "Disable Path Camera Controller."); + m_entryDisableFlightBind = m_categoryPathCamDisabler.CreateEntry("Disable Flight Binding (if controller off).", false, description: "Disable flight bind if Path Camera Controller is also disabled."); + + m_entryDisablePathCam.OnEntryValueChangedUntyped.Subscribe(OnUpdateSettings); + + MelonLoader.MelonCoroutines.Start(WaitForCVRPathCamController()); } - MelonLoader.MelonCoroutines.Start(WaitForLocalPlayer()); - } - - System.Collections.IEnumerator WaitForLocalPlayer() - { - while (CVRPathCamController.Instance == null) - yield return null; - UpdateSettings(); - } - - private void UpdateSettings() - { - CVRPathCamController.Instance.enabled = !m_entryDisablePathCam.Value; - } - - private void OnUpdateSettings(object arg1, object arg2) => UpdateSettings(); - - public override void OnUpdate() - { - if (m_entryDisablePathCam.Value && !m_entryDisableFlightBind.Value) + private System.Collections.IEnumerator WaitForCVRPathCamController() { - if (Input.GetKeyDown(KeyCode.Keypad5)) + while (CVRPathCamController.Instance == null) + yield return null; + UpdateSettings(); + } + + private void UpdateSettings() + { + CVRPathCamController.Instance.enabled = !m_entryDisablePathCam.Value; + } + private void OnUpdateSettings(object arg1, object arg2) => UpdateSettings(); + + public override void OnUpdate() + { + if (m_entryDisablePathCam.Value && !m_entryDisableFlightBind.Value) { - PlayerSetup.Instance._movementSystem.ToggleFlight(); + if (Input.GetKeyDown(KeyCode.Keypad5)) + { + PlayerSetup.Instance._movementSystem.ToggleFlight(); + } } } } diff --git a/PathCamDisabler/Properties/AssemblyInfo.cs b/PathCamDisabler/Properties/AssemblyInfo.cs index 652ae4d..6de051d 100644 --- a/PathCamDisabler/Properties/AssemblyInfo.cs +++ b/PathCamDisabler/Properties/AssemblyInfo.cs @@ -1,18 +1,17 @@ -using PathCamDisabler.Properties; -using MelonLoader; +using MelonLoader; using System.Reflection; - +using NAK.Melons.PathCamDisabler.Properties; [assembly: AssemblyVersion(AssemblyInfoParams.Version)] [assembly: AssemblyFileVersion(AssemblyInfoParams.Version)] [assembly: AssemblyInformationalVersion(AssemblyInfoParams.Version)] -[assembly: AssemblyTitle(nameof(PathCamDisabler))] +[assembly: AssemblyTitle(nameof(NAK.Melons.PathCamDisabler))] [assembly: AssemblyCompany(AssemblyInfoParams.Author)] -[assembly: AssemblyProduct(nameof(PathCamDisabler))] +[assembly: AssemblyProduct(nameof(NAK.Melons.PathCamDisabler))] [assembly: MelonInfo( - typeof(PathCamDisabler.PathCamDisabler), - nameof(PathCamDisabler), + typeof(NAK.Melons.PathCamDisabler.PathCamDisablerMod), + nameof(NAK.Melons.PathCamDisabler), AssemblyInfoParams.Version, AssemblyInfoParams.Author, downloadLink: "https://github.com/NotAKidOnSteam/PathCamDisabler" @@ -22,9 +21,9 @@ using System.Reflection; [assembly: MelonPlatform(MelonPlatformAttribute.CompatiblePlatforms.WINDOWS_X64)] [assembly: MelonPlatformDomain(MelonPlatformDomainAttribute.CompatibleDomains.MONO)] -namespace PathCamDisabler.Properties; +namespace NAK.Melons.PathCamDisabler.Properties; internal static class AssemblyInfoParams { - public const string Version = "1.0.0"; + public const string Version = "1.0.1"; public const string Author = "NotAKidoS"; } \ No newline at end of file diff --git a/PathCamDisabler/format.json b/PathCamDisabler/format.json index 83fe58a..b8a4315 100644 --- a/PathCamDisabler/format.json +++ b/PathCamDisabler/format.json @@ -1,12 +1,12 @@ { "_id": 110, "name": "PathCamDisabler", - "modversion": "1.0.0", - "gameversion": "2022r169", + "modversion": "1.0.1", + "gameversion": "2022r170", "loaderversion": "0.5.7", "modtype": "Mod", "author": "NotAKidoS", - "description": "Disables path camera controller to free up your numkeys. Additional option to disable the flight binding. \n\n Won't do much for VR. Can toggle with UIExpansionKit or similar.", + "description": "Adds option to disable the Path Camera Controller to free up your numkeys.\nAdditional option to disable flight binding.", "searchtags": [ "numpad", "camera", @@ -16,8 +16,8 @@ "requirements": [ "None" ], - "downloadlink": "https://github.com/NotAKidOnSteam/PathCamDisabler/releases/download/r1/PathCamDisabler.dll", + "downloadlink": "https://github.com/NotAKidOnSteam/PathCamDisabler/releases/download/v1.0.1/PathCamDisabler.dll", "sourcelink": "https://github.com/NotAKidOnSteam/PathCamDisabler/", - "changelog": "initial release\n(i made this in 5 minutes after months of annoyances)", + "changelog": "- Organizational changes.\n- No longer using SaveToFile().", "embedcolor": "#9b59b6" } \ No newline at end of file From 12e0a230ae6094c8c5947385aab4f0c1e0da6c05 Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Thu, 9 Feb 2023 22:58:42 -0600 Subject: [PATCH 6/6] Update README.md --- README.md | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index 0c25ae6..9ae12a8 100644 --- a/README.md +++ b/README.md @@ -36,22 +36,8 @@ Using UIExpansionKit or similar you can toggle both while in game. Here is the block of text where I tell you this mod is not affiliated or endorsed by ABI. https://documentation.abinteractive.net/official/legal/tos/#7-modding-our-games -> I am not affiliated with ABI in any official capacity, these mods are not endorsed or outright permitted by ABI and are subject to scrutiny. +> This mod is an independent creation and is not affiliated with, supported by or approved by Alpha Blend Interactive. -> Neither I nor these mods are in any way affiliated with Alpha Blend Interactive and/or ChilloutVR. Using these modifications might cause issues with the performance, security or stability of the game. Use at your own risk. +> Use of this mod is done so at the user's own risk and the creator cannot be held responsible for any issues arising from its use. -> Any modifications that are not approved can get your ABI account terminated and such this modification is following the "modding guidelines" at the best it could be. -> They reserve the right to punish users using my mod. -> If you are scared of using modifications in your game do not install mods. - -> I do not affiliate ABI and the mod is not supported by ABI. - -> Me and this modification are in no affiliation with ABI and not supported by ABI. - -> This mod is not affiliated with Alpha Blend Interactive. The mod comes with no warranty. Use at your own risk, as I am not responsible for any misuse. - -> I'm not affiliated with Alpha Blend Interactive and this mod is not officially supported by the game. - -> When releasing mods to the public, it is required to state, that the mod authors and modification are in no affiliation with ABI and not supported by ABI. :trollface: - -> i ran out of places to steal disclaimers from +> To the best of my knowledge, I have adhered to the Modding Guidelines established by Alpha Blend Interactive.