The fucking 3rd time i had to upload this project to git

This commit is contained in:
Madhav Kapa
2023-10-06 20:18:29 -04:00
commit 5658acfe16
2689 changed files with 1259400 additions and 0 deletions

View File

@ -0,0 +1,60 @@
// using Player.Interactions;
using UnityEngine;
using UnityEngine.Scripting;
using Player.Information;
using Player.Movement;
namespace IngameDebugConsole.Commands
{
public class PlayerCommands
{
[ConsoleMethod("player.jetpack", "Sets Jetpack Active State")]
[Preserve]
public static void PlayerJetpack(bool boolValue)
{
var player = GameObject.Find("Player");
if (player != null)
{
// set jetpack component active
player.GetComponent<PlayerStats>().jetpackEnabled = boolValue;
Debug.Log("Jetpack set to " + boolValue);
}
else
{
Debug.Log("Player not found");
}
}
[ConsoleMethod("player.grapple", "Sets Grapple Active State")]
[Preserve]
public static void PlayerGrapple(bool boolValue)
{
var player = GameObject.Find("Player");
if (player != null)
{
player.GetComponent<PlayerStats>().grappleEnabled = boolValue;
Debug.Log("Grapple set to " + boolValue);
}
else
{
Debug.Log("Player not found");
}
}
[ConsoleMethod("player.sensitivity", "Sets Mouse Sensitivity")]
[Preserve]
public static void PlayerSensitivity(float sensitivity)
{
var player = GameObject.Find("Player");
if (player != null)
{
Camera.main.GetComponent<MouseLook>().mouseSensitivity = sensitivity;
PlayerPrefs.SetFloat("Sensitivity", sensitivity);
Debug.Log("Mouse Sensitivity set to " + sensitivity);
}
else
{
Debug.Log("Player not found");
}
}
}
}

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: ed03242f9d95d614b8dbb178cc9ce59b
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,65 @@
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.Scripting;
namespace IngameDebugConsole.Commands
{
public class SceneCommands
{
[ConsoleMethod("scene.load", "Loads a scene")]
[Preserve]
public static void LoadScene(string sceneName)
{
LoadSceneInternal(sceneName, false, LoadSceneMode.Single);
}
[ConsoleMethod("scene.load", "Loads a scene")]
[Preserve]
public static void LoadScene(string sceneName, LoadSceneMode mode)
{
LoadSceneInternal(sceneName, false, mode);
}
[ConsoleMethod("scene.loadasync", "Loads a scene asynchronously")]
[Preserve]
public static void LoadSceneAsync(string sceneName)
{
LoadSceneInternal(sceneName, true, LoadSceneMode.Single);
}
[ConsoleMethod("scene.loadasync", "Loads a scene asynchronously")]
[Preserve]
public static void LoadSceneAsync(string sceneName, LoadSceneMode mode)
{
LoadSceneInternal(sceneName, true, mode);
}
private static void LoadSceneInternal(string sceneName, bool isAsync, LoadSceneMode mode)
{
if (SceneManager.GetSceneByName(sceneName).IsValid())
{
Debug.Log("Scene " + sceneName + " is already loaded");
return;
}
if (isAsync)
SceneManager.LoadSceneAsync(sceneName, mode);
else
SceneManager.LoadScene(sceneName, mode);
}
[ConsoleMethod("scene.unload", "Unloads a scene")]
[Preserve]
public static void UnloadScene(string sceneName)
{
SceneManager.UnloadSceneAsync(sceneName);
}
[ConsoleMethod("scene.restart", "Restarts the active scene")]
[Preserve]
public static void RestartScene()
{
SceneManager.LoadScene(SceneManager.GetActiveScene().name, LoadSceneMode.Single);
}
}
}

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 73f6112b4a7e5624583195aa8af9e548
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,22 @@
using UnityEngine;
using UnityEngine.Scripting;
namespace IngameDebugConsole.Commands
{
public class TimeCommands
{
[ConsoleMethod("time.scale", "Sets the Time.timeScale value")]
[Preserve]
public static void SetTimeScale(float value)
{
Time.timeScale = Mathf.Max(value, 0f);
}
[ConsoleMethod("time.scale", "Returns the current Time.timeScale value")]
[Preserve]
public static float GetTimeScale()
{
return Time.timeScale;
}
}
}

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: c5061e3b82c469c4d9ee288d4ec03d5e
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant: