forked from Terkoiz/Freecam
fixes terk asked for + a few things
This commit is contained in:
parent
944bb7d135
commit
0c90ab215a
1
.gitignore
vendored
1
.gitignore
vendored
@ -244,6 +244,7 @@ orleans.codegen.cs
|
||||
.idea
|
||||
Freecam.sln.DotSettings.user
|
||||
Project/.idea/
|
||||
Project/Shared/*
|
||||
|
||||
# Including strong name files can present a security risk
|
||||
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
|
||||
|
@ -1,3 +1,4 @@
|
||||
using JetBrains.Annotations;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Terkoiz.Freecam
|
||||
@ -13,6 +14,7 @@ namespace Terkoiz.Freecam
|
||||
{
|
||||
public bool IsActive = false;
|
||||
|
||||
[UsedImplicitly]
|
||||
public void Update()
|
||||
{
|
||||
if (!IsActive)
|
||||
@ -81,6 +83,7 @@ namespace Terkoiz.Freecam
|
||||
}
|
||||
}
|
||||
|
||||
[UsedImplicitly]
|
||||
private void OnDestroy()
|
||||
{
|
||||
Destroy(this);
|
||||
|
@ -3,6 +3,7 @@ using EFT;
|
||||
using EFT.CameraControl;
|
||||
using EFT.UI;
|
||||
using HarmonyLib;
|
||||
using JetBrains.Annotations;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Terkoiz.Freecam
|
||||
@ -26,6 +27,7 @@ namespace Terkoiz.Freecam
|
||||
// Button to toggle between camera and player movement
|
||||
// Independent FoV setting for Freecam mode (_mainCamera.GetComponent<Camera>().fieldOfView = ...)
|
||||
|
||||
[UsedImplicitly]
|
||||
public void Start()
|
||||
{
|
||||
// Find Main Camera
|
||||
@ -44,6 +46,7 @@ namespace Terkoiz.Freecam
|
||||
FreecamPlugin.Logger.LogError("Failed to locate GamePlayerOwner");
|
||||
}
|
||||
|
||||
[UsedImplicitly]
|
||||
public void Update()
|
||||
{
|
||||
if (FreecamPlugin.ToggleUi.Value.IsDown())
|
||||
@ -227,6 +230,7 @@ namespace Terkoiz.Freecam
|
||||
return gameWorld.MainPlayer;
|
||||
}
|
||||
|
||||
[UsedImplicitly]
|
||||
private void OnDestroy()
|
||||
{
|
||||
// Destroy FreeCamScript before FreeCamController if exists
|
||||
|
@ -21,7 +21,7 @@ namespace Terkoiz.Freecam
|
||||
return;
|
||||
|
||||
// Add FreeCamController to GameWorld GameObject
|
||||
gameworld.GetOrAddComponent<FreecamController>();
|
||||
gameworld.gameObject.AddComponent<FreecamController>();
|
||||
}
|
||||
}
|
||||
}
|
@ -1,6 +1,7 @@
|
||||
using BepInEx;
|
||||
using BepInEx.Configuration;
|
||||
using BepInEx.Logging;
|
||||
using JetBrains.Annotations;
|
||||
using UnityEngine;
|
||||
using KeyboardShortcut = BepInEx.Configuration.KeyboardShortcut;
|
||||
|
||||
@ -32,6 +33,7 @@ namespace Terkoiz.Freecam
|
||||
internal static ConfigEntry<bool> CameraRememberLastPosition;
|
||||
public static ConfigEntry<bool> FallDamageToggle;
|
||||
|
||||
[UsedImplicitly]
|
||||
internal void Start()
|
||||
{
|
||||
new FreecamPatch().Enable();
|
||||
@ -123,7 +125,7 @@ namespace Terkoiz.Freecam
|
||||
TogglesSectionName,
|
||||
"FallHeightToggle",
|
||||
true,
|
||||
"True disables fall damage, False doesn't simplez");
|
||||
"If enabled, will disable all fall damage for the player.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
36
project/Terkoiz.Freecam/Properties/AssemblyInfo.cs
Normal file
36
project/Terkoiz.Freecam/Properties/AssemblyInfo.cs
Normal file
@ -0,0 +1,36 @@
|
||||
using System.Reflection;
|
||||
using System.Runtime.CompilerServices;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
// General Information about an assembly is controlled through the following
|
||||
// set of attributes. Change these attribute values to modify the information
|
||||
// associated with an assembly.
|
||||
[assembly: AssemblyTitle("Terkoiz.Freecam")]
|
||||
[assembly: AssemblyDescription("")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCompany("")]
|
||||
[assembly: AssemblyProduct("Terkoiz.Freecam")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2021")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
|
||||
// Setting ComVisible to false makes the types in this assembly not visible
|
||||
// to COM components. If you need to access a type in this assembly from
|
||||
// COM, set the ComVisible attribute to true on that type.
|
||||
[assembly: ComVisible(false)]
|
||||
|
||||
// The following GUID is for the ID of the typelib if this project is exposed to COM
|
||||
[assembly: Guid("be2de623-48ff-4807-9696-167a17787718")]
|
||||
|
||||
// Version information for an assembly consists of the following four values:
|
||||
//
|
||||
// Major Version
|
||||
// Minor Version
|
||||
// Build Number
|
||||
// Revision
|
||||
//
|
||||
// You can specify all the values or you can default the Build and Revision Numbers
|
||||
// by using the '*' as shown below:
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
@ -7,38 +7,46 @@
|
||||
|
||||
<ItemGroup>
|
||||
<Reference Include="0Harmony">
|
||||
<HintPath>..\..\Shared\0Harmony.dll</HintPath>
|
||||
<HintPath>..\Shared\0Harmony.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Aki.Reflection">
|
||||
<HintPath>..\..\Shared\Aki.Reflection.dll</HintPath>
|
||||
<HintPath>..\Shared\Aki.Reflection.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Assembly-CSharp">
|
||||
<HintPath>..\..\Shared\Assembly-CSharp.dll</HintPath>
|
||||
<HintPath>..\Shared\Assembly-CSharp.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="BepInEx">
|
||||
<HintPath>..\..\Shared\BepInEx.dll</HintPath>
|
||||
<HintPath>..\Shared\BepInEx.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Comfort">
|
||||
<HintPath>..\..\Shared\Comfort.dll</HintPath>
|
||||
<HintPath>..\Shared\Comfort.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="ConfigurationManager">
|
||||
<HintPath>..\..\Shared\ConfigurationManager.dll</HintPath>
|
||||
<HintPath>..\Shared\ConfigurationManager.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="ItemComponent.Types">
|
||||
<HintPath>..\..\Shared\ItemComponent.Types.dll</HintPath>
|
||||
<HintPath>..\Shared\ItemComponent.Types.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEngine">
|
||||
<HintPath>..\..\Shared\UnityEngine.dll</HintPath>
|
||||
<HintPath>..\Shared\UnityEngine.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEngine.CoreModule">
|
||||
<HintPath>..\..\Shared\UnityEngine.CoreModule.dll</HintPath>
|
||||
<HintPath>..\Shared\UnityEngine.CoreModule.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEngine.InputLegacyModule">
|
||||
<HintPath>..\..\Shared\UnityEngine.InputLegacyModule.dll</HintPath>
|
||||
<HintPath>..\Shared\UnityEngine.InputLegacyModule.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="UnityEngine.UIModule">
|
||||
<HintPath>..\..\Shared\UnityEngine.UIModule.dll</HintPath>
|
||||
<HintPath>..\Shared\UnityEngine.UIModule.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="Freecam.cs" />
|
||||
<Compile Include="FreecamController.cs" />
|
||||
<Compile Include="FreecamPlugin.cs" />
|
||||
<Compile Include="FreecamPatch.cs" />
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
||||
|
Loading…
x
Reference in New Issue
Block a user