Esempio n. 1
0
 private void Main()
 {
     HotkeyX   = new SavedKeyboardShortcut(nameof(HotkeyX), nameof(KK_StudioObjectMoveHotkeys), new KeyboardShortcut(KeyCode.Y));
     HotkeyY   = new SavedKeyboardShortcut(nameof(HotkeyY), nameof(KK_StudioObjectMoveHotkeys), new KeyboardShortcut(KeyCode.U));
     HotkeyZ   = new SavedKeyboardShortcut(nameof(HotkeyZ), nameof(KK_StudioObjectMoveHotkeys), new KeyboardShortcut(KeyCode.I));
     HotkeyAll = new SavedKeyboardShortcut(nameof(HotkeyAll), nameof(KK_StudioObjectMoveHotkeys), new KeyboardShortcut(KeyCode.T));
 }
Esempio n. 2
0
 public DeveloperConsole()
 {
     ShowKey  = new SavedKeyboardShortcut(Config, "Show developer console", "", new KeyboardShortcut(KeyCode.Pause));
     LogDepth = Config.Wrap("Config", "Log buffer size", "Size of the log buffer in characters", 16300);
     BepInEx.Logging.Logger.Listeners.Add(new LogListener());
     Logger = base.Logger;
 }
Esempio n. 3
0
        void Awake()
        {
            HideHotkey = new SavedKeyboardShortcut("HideHotkey", this, new KeyboardShortcut(KeyCode.Space));

            harmony = HarmonyInstance.Create("keelhauled.hideallui.harmony");
            harmony.PatchAll(GetType());
        }
        protected void Awake()
        {
            KeyCapture      = new SavedKeyboardShortcut(Config, "Take UI screenshot", "Capture a simple \"as you see it\" screenshot of the game. Not affected by settings for rendered screenshots.", new KeyboardShortcut(KeyCode.F9));
            KeyCaptureAlpha = new SavedKeyboardShortcut(Config, "Take rendered screenshot", null, new KeyboardShortcut(KeyCode.F11));
            KeyCapture360   = new SavedKeyboardShortcut(Config, "Take 360 screenshot", "Captures a 360 screenshot around current camera. The created image is in equirectangular format and can be viewed by most 360 image viewers (e.g. Google Cardboard).", new KeyboardShortcut(KeyCode.F11, KeyCode.LeftControl));
            KeyGui          = new SavedKeyboardShortcut(Config, "Open settings window", null, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            ResolutionX = Config.Wrap("Render Output Resolution", "Horizontal", "Horizontal size (width) of rendered screenshots in pixels. Doesn't affect UI and 360 screenshots.", Screen.width);
            ResolutionY = Config.Wrap("Render Output Resolution", "Vertical", "Vertical size (height) of rendered screenshots in pixels. Doesn't affect UI and 360 screenshots.", Screen.height);
            ResolutionX.SettingChanged += (sender, args) => _resolutionXBuffer = ResolutionX.Value.ToString();
            ResolutionY.SettingChanged += (sender, args) => _resolutionYBuffer = ResolutionY.Value.ToString();

            Resolution360 = Config.Wrap("360 Screenshots", "360 screenshot resolution", "Horizontal resolution (width) of 360 degree/panorama screenshots. Decrease if you have issues. WARNING: Memory usage can get VERY high - 4096 needs around 4GB of free RAM/VRAM to create, 8192 will need much more.", 4096);

            DownscalingRate     = Config.Wrap("Render Settings", "Screenshot upsampling ratio", "Capture screenshots in a higher resolution and then downscale them to desired size. Prevents aliasing, perserves small details and gives a smoother result, but takes longer to create.", 2);
            CardDownscalingRate = Config.Wrap("Render Settings", "Card image upsampling ratio", "Capture character card images in a higher resolution and then downscale them to desired size. Prevents aliasing, perserves small details and gives a smoother result, but takes longer to create.", 3);
            CaptureAlpha        = Config.Wrap("Render Settings", "Transparency in rendered screenshots", "Replaces background with transparency in rendered image. Works only if there are no 3D objects covering the background (e.g. the map). Works well in character creator and studio.", true);

            ScreenshotMessage = Config.Wrap("General", "Show messages on screen", "Whether screenshot messages will be displayed on screen. Messages will still be written to the log.", true);

            SceneManager.sceneLoaded += (s, a) => InstallSceenshotHandler();
            InstallSceenshotHandler();

            if (!Directory.Exists(ScreenshotDir))
            {
                Directory.CreateDirectory(ScreenshotDir);
            }

            Hooks.InstallHooks();

            I360Render.Init();
        }
Esempio n. 5
0
 public DynamicTranslator()
 {
     IsDumpingEnabled     = new ConfigWrapper <bool>("!Enable image dumping", this);
     DumpingAllToGlobal   = new ConfigWrapper <bool>("Dump all images to global folder", this);
     ReloadTranslations   = new SavedKeyboardShortcut("Reload translations", this, new KeyboardShortcut(KeyCode.F10));
     DumpUntranslatedText = new SavedKeyboardShortcut("Dump untranslated text", this, new KeyboardShortcut(KeyCode.F10, KeyCode.LeftShift));
 }
Esempio n. 6
0
        private void Awake()
        {
            Application.logMessageReceived += new Application.LogCallback(HandleLog);

            EyesMovement     = new ConfigWrapper <float>(nameof(EyesMovement), this, 50f);
            ForceKiss        = new ConfigWrapper <bool>(nameof(ForceKiss), this, false);
            KissNeckAngle    = new ConfigWrapper <float>(nameof(KissNeckAngle), this, 0.2f);
            GropeOverride    = new ConfigWrapper <bool>(nameof(GropeOverride), this, true);
            KissDistance     = new ConfigWrapper <float>(nameof(KissDistance), this, 0.18f);
            KissDistanceAibu = new ConfigWrapper <float>(nameof(KissDistanceAibu), this, 0.28f);
            KissMotionSpeed  = new ConfigWrapper <float>(nameof(KissMotionSpeed), this, 0.1f);
            MouthMovement    = new ConfigWrapper <Cyu.FrenchMode>(nameof(MouthMovement), this, Cyu.FrenchMode.Auto);
            MouthOffset      = new ConfigWrapper <float>(nameof(MouthOffset), this, 0.12f);
            OrgasmAfterKiss  = new ConfigWrapper <bool>(nameof(OrgasmAfterKiss), this, false);

            PluginToggleKey = new SavedKeyboardShortcut(nameof(PluginToggleKey), this, new KeyboardShortcut(KeyCode.None));

            if (!(dataPathVR = Application.dataPath.EndsWith("KoikatuVR_Data")))
            {
                return;
            }
            try
            {
                HarmonyInstance.Create("bero.cyuvr").PatchAll(typeof(Hooks));
            }
            catch (Exception ex)
            {
                Console.WriteLine(ex.ToString());
            }
        }
        protected void Awake()
        {
            if (Instance)
            {
                GameObject.DestroyImmediate(this);
                return;
            }
            Instance        = this;
            CK_Capture      = new SavedKeyboardShortcut("Take UI screenshot", this, new KeyboardShortcut(KeyCode.F9));
            CK_CaptureAlpha = new SavedKeyboardShortcut("Take rendered screenshot", this, new KeyboardShortcut(KeyCode.F11));
            CK_Gui          = new SavedKeyboardShortcut("Open settings window", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            ResolutionX         = new ConfigWrapper <int>("resolution-x", this, Screen.width);
            ResolutionY         = new ConfigWrapper <int>("resolution-y", this, Screen.height);
            DownscalingRate     = new ConfigWrapper <int>("downscalerate", this, 2);
            CardDownscalingRate = new ConfigWrapper <int>("carddownscalerate", this, 3);
            CaptureAlpha        = new ConfigWrapper <bool>("capturealpha", this, true);

            SceneManager.sceneLoaded += (s, a) => InstallSceenshotHandler();
            InstallSceenshotHandler();

            if (!Directory.Exists(screenshotDir))
            {
                Directory.CreateDirectory(screenshotDir);
            }

            Hooks.InstallHooks();
        }
        private void LoadFromModPref()
        {
            Finishcount           = new ConfigWrapper <float>(nameof(Finishcount), this, 0f);
            SetParentMode         = new ConfigWrapper <ParentMode>(nameof(SetParentMode), this, ParentMode.PositionAndAnimation);
            DisableParentInput    = new ConfigWrapper <bool>(nameof(DisableParentInput), this, true);
            StretchLimitArms      = new ConfigWrapper <float>(nameof(StretchLimitArms), this, 0.5f);
            StretchLimitLegs      = new ConfigWrapper <float>(nameof(StretchLimitLegs), this, 0.7f);
            MenuUpProximity       = new ConfigWrapper <float>(nameof(MenuUpProximity), this, 0.25f);
            SetControllerCollider = new ConfigWrapper <bool>(nameof(SetControllerCollider), this, true);
            GazeControl           = new ConfigWrapper <bool>(nameof(GazeControl), this, false);
            GropeHandsDisplay     = new ConfigWrapper <HideHandMode>(nameof(GropeHandsDisplay), this, HideHandMode.Auto);
            MenuHideDefault       = new ConfigWrapper <bool>(nameof(MenuHideDefault), this, true);
            HideParentConAlways   = new ConfigWrapper <bool>(nameof(HideParentConAlways), this, true);
            SetMaleFeetCollider   = new ConfigWrapper <bool>(nameof(SetMaleFeetCollider), this, true);
            SyncMaleHands         = new ConfigWrapper <bool>(nameof(SyncMaleHands), this, true);
            SetParentMale         = new ConfigWrapper <bool>(nameof(SetParentMale), this, true);
            CalcController        = new ConfigWrapper <ControllerAnimMode>(nameof(CalcController), this, ControllerAnimMode.SetParentController);

            LimbReleaseKey  = new SavedKeyboardShortcut(nameof(LimbReleaseKey), this, new KeyboardShortcut(KeyCode.None));
            SetParentToggle = new SavedKeyboardShortcut(nameof(SetParentToggle), this, new KeyboardShortcut(KeyCode.None));
            MaleFeetToggle  = new SavedKeyboardShortcut(nameof(MaleFeetToggle), this, new KeyboardShortcut(KeyCode.None));

            AnimMaxThreshold       = new ConfigWrapper <float>(nameof(AnimMaxThreshold), this, 0.23f);
            AnimStartThreshold     = new ConfigWrapper <float>(nameof(AnimStartThreshold), this, 0.02f);
            MoveCoordinatePoolSize = new ConfigWrapper <int>(nameof(MoveCoordinatePoolSize), this, 30);
            MoveDistancePoolSize   = new ConfigWrapper <int>(nameof(MoveDistancePoolSize), this, 55);
            MaleYaw      = new ConfigWrapper <bool>(nameof(MaleYaw), this, true);
            ParentPart   = new ConfigWrapper <BodyPart>(nameof(ParentPart), this, BodyPart.Ass);
            TrackingMode = new ConfigWrapper <bool>(nameof(TrackingMode), this, true);
            StrongThresholdMultiplier = new ConfigWrapper <float>(nameof(StrongThresholdMultiplier), this, 1.1f);
            StrongMotionThreshold     = new ConfigWrapper <float>(nameof(StrongMotionThreshold), this, 0.04f);
            WeakMotionThreshold       = new ConfigWrapper <float>(nameof(WeakMotionThreshold), this, 0.03f);
        }
Esempio n. 9
0
 TogglePOV()
 {
     POVKey       = new SavedKeyboardShortcut("POVKey", this, new KeyboardShortcut(KeyCode.Backspace));
     DefaultFov   = new ConfigWrapper <float>("DefaultFov", this, 70f);
     ShowHair     = new ConfigWrapper <bool>("ShowHair", this, false);
     MaleOffset   = new ConfigWrapper <float>("MaleOffset", this, 0.042f);
     FemaleOffset = new ConfigWrapper <float>("FemaleOffset", this, 0.0315f);
 }
Esempio n. 10
0
 public DynamicTranslator()
 {
     IsDumpingEnabled     = new ConfigWrapper <bool>("dumping", this);
     IsPastingToClipboard = new ConfigWrapper <bool>("paste-to-clipboard", this);
     DumpingAllToGlobal   = new ConfigWrapper <bool>("dump-to-global", this);
     ReloadTranslations   = new SavedKeyboardShortcut("Reload translations", this, new KeyboardShortcut(KeyCode.F10, KeyCode.LeftControl));
     DumpUntranslatedText = new SavedKeyboardShortcut("Dump untranslated text", this, new KeyboardShortcut(KeyCode.F10, KeyCode.LeftShift));
 }
Esempio n. 11
0
        void Start()
        {
            // Check for KKABMX version, not really necessary (?).
            AddAllHotkey  = new SavedKeyboardShortcut("AddAllHotkey", PluginNameInternal, new KeyboardShortcut(KeyCode.Q, UI.CtrlShift));
            LoadAllHotkey = new SavedKeyboardShortcut("GetAllHotkey", PluginNameInternal, new KeyboardShortcut(KeyCode.E, UI.CtrlShift));

            HarmonyInstance.Create(GUID).PatchAll(typeof(KK_Archetypes));
        }
Esempio n. 12
0
        void Main()
        {
            var harmony = HarmonyInstance.Create("com.deathweasel.bepinex.invisiblebody");

            harmony.PatchAll(typeof(KK_InvisibleBody));
            SceneManager.sceneLoaded += SceneLoaded;
            InvisibilityHotkey        = new SavedKeyboardShortcut("InvisibilityHotkey", "KK_InvisibleBody", new KeyboardShortcut(KeyCode.KeypadPlus));
            HideHairAccessories       = new ConfigWrapper <bool>("HideHairAccessories", "KK_InvisibleBody", true);
        }
Esempio n. 13
0
        private void Start()
        {
            var harmony = HarmonyInstance.Create(GUID);

            harmony.PatchAll(typeof(InvisibleBody));

            InvisibilityHotkey  = new SavedKeyboardShortcut("InvisibilityHotkey", PluginNameInternal, new KeyboardShortcut(KeyCode.KeypadPlus));
            HideHairAccessories = new ConfigWrapper <bool>("HideHairAccessories", PluginNameInternal, true);
        }
Esempio n. 14
0
        void Main()
        {
            var harmony = HarmonyInstance.Create(GUID);

            harmony.PatchAll(typeof(KK_InvisibleBody));
            SceneManager.sceneLoaded += SceneLoaded;
            InvisibilityHotkey        = new SavedKeyboardShortcut("InvisibilityHotkey", PluginNameInternal, new KeyboardShortcut(KeyCode.KeypadPlus));
            HideHairAccessories       = new ConfigWrapper <bool>("HideHairAccessories", PluginNameInternal, true);
        }
Esempio n. 15
0
 TitleShortcuts()
 {
     AutoStart        = new ConfigWrapper <AutoStartOption>("AutoStart", this, AutoStartOption.Disabled);
     StartFemaleMaker = new SavedKeyboardShortcut("StartFemaleMaker", this, new KeyboardShortcut(KeyCode.F));
     StartMaleMaker   = new SavedKeyboardShortcut("StartMaleMaker", this, new KeyboardShortcut(KeyCode.M));
     StartUploader    = new SavedKeyboardShortcut("StartUploader", this, new KeyboardShortcut(KeyCode.U));
     StartDownloader  = new SavedKeyboardShortcut("StartDownloader", this, new KeyboardShortcut(KeyCode.D));
     StartFreeH       = new SavedKeyboardShortcut("StartFreeH", this, new KeyboardShortcut(KeyCode.H));
     StartLiveShow    = new SavedKeyboardShortcut("StartLiveShow", this, new KeyboardShortcut(KeyCode.L));
 }
        void Main()
        {
            var harmony = HarmonyInstance.Create("com.deathweasel.bepinex.invisiblebody");

            harmony.PatchAll(typeof(KK_AnimationController));

            AnimationControllerHotkey     = new SavedKeyboardShortcut(PluginName, PluginName, new KeyboardShortcut(KeyCode.Minus));
            ExtendedSave.SceneBeingSaved += ExtendedSceneSave;
            SceneManager.sceneLoaded     += SceneLoaded;
        }
Esempio n. 17
0
 TogglePOV()
 {
     POVKey                = new SavedKeyboardShortcut("POVKey", this, new KeyboardShortcut(KeyCode.Backspace));
     DefaultFov            = new ConfigWrapper <float>("DefaultFov", this, 70f);
     ViewOffset            = new ConfigWrapper <float>("ViewOffset", this, 0.0315f);
     VerticalSensitivity   = new ConfigWrapper <float>("VerticalSensitivity", this, 0.5f);
     HorizontalSensitivity = new ConfigWrapper <float>("HorizontalSensitivity", this, 0.5f);
     NearClipPov           = new ConfigWrapper <float>("NearClipPov", this, 0.005f);
     ClampRotation         = new ConfigWrapper <bool>("ClampRotation", this, true);
 }
Esempio n. 18
0
        void Main()
        {
            var harmony = HarmonyInstance.Create(GUID);

            harmony.PatchAll(typeof(KK_HairAccessoryFix));

            MatchColor        = new ConfigWrapper <bool>("MatchColor", PluginNameInternal, false);
            MatchOutlineColor = new ConfigWrapper <bool>("MatchOutlineColor", PluginNameInternal, true);
            MatchGloss        = new ConfigWrapper <bool>("MatchGloss", PluginNameInternal, true);
            SyncHotkey        = new SavedKeyboardShortcut("SyncHotkey", PluginNameInternal, new KeyboardShortcut(KeyCode.F5));
        }
Esempio n. 19
0
        public ScreenshotManager()
        {
            CK_Capture      = new SavedKeyboardShortcut("Take screenshot", this, new KeyboardShortcut(KeyCode.F9));
            CK_CaptureAlpha = new SavedKeyboardShortcut("Take character screenshot", this, new KeyboardShortcut(KeyCode.F11));
            CK_Gui          = new SavedKeyboardShortcut("Open settings window", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            ResolutionX         = new ConfigWrapper <int>("resolution-x", this, Screen.width);
            ResolutionY         = new ConfigWrapper <int>("resolution-y", this, Screen.height);
            DownscalingRate     = new ConfigWrapper <int>("downscalerate", this, 1);
            CardDownscalingRate = new ConfigWrapper <int>("carddownscalerate", this, 1);
            CaptureAlpha        = new ConfigWrapper <bool>("capturealpha", this, true);
        }
Esempio n. 20
0
        void Awake()
        {
            LoadOnStart = new ConfigWrapper <bool>("LoadOnStart", this, false);
            ReloadKey   = new SavedKeyboardShortcut("ReloadKey", this, new KeyboardShortcut(KeyCode.F6));

            processName = Process.GetCurrentProcess().ProcessName.ToLower();

            if (LoadOnStart.Value)
            {
                ReloadPlugins();
            }
        }
Esempio n. 21
0
        public Hotkey(SavedKeyboardShortcut newKey, float newProcTime = 0f)
        {
            key = newKey;
            if (key.Value.MainKey == KeyCode.None)
            {
                enabled = false;
            }

            if (newProcTime > 0f)
            {
                procTime = newProcTime;
            }
        }
Esempio n. 22
0
        LockOnPlugin()
        {
            TrackingSpeedNormal   = new ConfigWrapper <float>("LockedTrackingSpeed", this, 0.1f);
            ScrollThroughMalesToo = new ConfigWrapper <bool>("ScrollThroughMalesToo", this, true);
            ShowInfoMsg           = new ConfigWrapper <bool>("ShowInfoMsg", this, true);
            LockLeashLength       = new ConfigWrapper <float>("LockLeashLength", this, 0f);
            AutoSwitchLock        = new ConfigWrapper <bool>("AutoSwitchLock", this, false);
            ShowDebugTargets      = new ConfigWrapper <bool>("ShowDebugTargets", this, false);

            LockOnKey    = new SavedKeyboardShortcut("LockOnKey", this, new KeyboardShortcut(KeyCode.Mouse4));
            LockOnGuiKey = new SavedKeyboardShortcut("LockOnGuiKey", this, new KeyboardShortcut(KeyCode.None));
            PrevCharaKey = new SavedKeyboardShortcut("PrevCharaKey", this, new KeyboardShortcut(KeyCode.None));
            NextCharaKey = new SavedKeyboardShortcut("NextCharaKey", this, new KeyboardShortcut(KeyCode.None));
        }
        protected void Awake()
        {
            if (Instance)
            {
                DestroyImmediate(this);
                return;
            }
            Instance = this;
            Logger   = base.Logger;

            KeyCapture      = new SavedKeyboardShortcut(Config, "Take UI screenshot", "Capture a simple \"as you see it\" screenshot of the game. Not affected by settings for rendered screenshots.", new KeyboardShortcut(KeyCode.F9));
            KeyCaptureAlpha = new SavedKeyboardShortcut(Config, "Take rendered screenshot", null, new KeyboardShortcut(KeyCode.F11));
            KeyCapture360   = new SavedKeyboardShortcut(Config, "Take 360 screenshot", "Captures a 360 screenshot around current camera. The created image is in equirectangular format and can be viewed by most 360 image viewers (e.g. Google Cardboard).", new KeyboardShortcut(KeyCode.F11, KeyCode.LeftControl));
            KeyGui          = new SavedKeyboardShortcut(Config, "Open settings window", null, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            KeyCaptureAlphaIn3D = new SavedKeyboardShortcut(Config, "Take rendered 3D screenshot", "Capture a high quality screenshot without UI in stereoscopic 3D (2 captures for each eye in one image). These images can be viewed by crossing your eyes or any stereoscopic image viewer.", new KeyboardShortcut(KeyCode.F11, KeyCode.LeftAlt));
            KeyCapture360in3D   = new SavedKeyboardShortcut(Config, "Take 360 3D screenshot", "Captures a 360 screenshot around current camera in stereoscopic 3D (2 captures for each eye in one image). These images can be viewed by image viewers supporting 3D stereo format (e.g. VR Media Player - 360° Viewer).", new KeyboardShortcut(KeyCode.F11, KeyCode.LeftControl, KeyCode.LeftShift));

            Resolution360 = Config.Wrap("360 Screenshots", "360 screenshot resolution", "Horizontal resolution (width) of 360 degree/panorama screenshots. Decrease if you have issues. WARNING: Memory usage can get VERY high - 4096 needs around 4GB of free RAM/VRAM to create, 8192 will need much more.", 4096);

            DownscalingRate       = Config.Wrap("Render Settings", "Screenshot upsampling ratio", "Capture screenshots in a higher resolution and then downscale them to desired size. Prevents aliasing, perserves small details and gives a smoother result, but takes longer to create.", 2);
            CardDownscalingRate   = Config.Wrap("Render Settings", "Card image upsampling ratio", "Capture character card images in a higher resolution and then downscale them to desired size. Prevents aliasing, perserves small details and gives a smoother result, but takes longer to create.", 3);
            CaptureAlpha          = Config.Wrap("Render Settings", "Transparency in rendered screenshots", "Replaces background with transparency in rendered image. Works only if there are no 3D objects covering the background (e.g. the map). Works well in character creator and studio.", true);
            ScreenshotMessage     = Config.Wrap("General", "Show messages on screen", "Whether screenshot messages will be displayed on screen. Messages will still be written to the log.", true);
            ResolutionX           = Config.Wrap("Render Output Resolution", "Horizontal", "Horizontal size (width) of rendered screenshots in pixels. Doesn't affect UI and 360 screenshots.", Screen.width);
            ResolutionY           = Config.Wrap("Render Output Resolution", "Vertical", "Vertical size (height) of rendered screenshots in pixels. Doesn't affect UI and 360 screenshots.", Screen.height);
            EyeSeparation         = Config.Wrap("3D Settings", "3D screenshot eye separation", "Distance between the two captured stereoscopic screenshots in arbitrary units.", 0.18f);
            ImageSeparationOffset = Config.Wrap("3D Settings", "3D screenshot image separation offset", "Move images in stereoscopic screenshots closer together by this percentage (discards overlapping parts). Useful for viewing with crossed eyes. Does not affect 360 stereoscopic screenshots.", 0.25f);
            UseJpg     = Config.Wrap("JPG Settings", "Save screenshots as .jpg instead of .png", "Save screenshots in lower quality in return for smaller file sizes. Transparency is NOT supported in .jpg screenshots. Strongly consider not using this option if you want to share your work.", false);
            JpgQuality = Config.Wrap("3D Settings", "Quality of .jpg files", "Lower quality = lower file sizes. Even 100 is worse than a .png file.", 100);
            //TODO:ScreenshotNameFormat = Config.Wrap("General", "Screenshot filename format", "Screenshots will be saved with names of the selected format. Name stands for the current game name (CharaStudio, Koikatu, etc.)", NameFormat.NameDateType);
            ScreenshotNameOverride = Config.Wrap("General", "Screenshot filename Name override", "Forces the Name part of the filename to always be this instead of varying depending on the name of the current game. Use \"Koikatsu\" to get the old filename behaviour.", "");

            ResolutionX.SettingChanged += (sender, args) => ResolutionXBuffer = ResolutionX.Value.ToString();
            ResolutionY.SettingChanged += (sender, args) => ResolutionYBuffer = ResolutionY.Value.ToString();

            SceneManager.sceneLoaded += (s, a) => InstallSceenshotHandler();
            InstallSceenshotHandler();

            if (!Directory.Exists(screenshotDir))
            {
                Directory.CreateDirectory(screenshotDir);
            }

            Hooks.InstallHooks();

            I360Render.Init();
        }
Esempio n. 24
0
        protected void Awake()
        {
            if (Instance)
            {
                DestroyImmediate(this);
                return;
            }
            Instance            = this;
            CK_Capture          = new SavedKeyboardShortcut("Take UI screenshot", this, new KeyboardShortcut(KeyCode.F9));
            CK_CaptureAlpha     = new SavedKeyboardShortcut("Take rendered screenshot", this, new KeyboardShortcut(KeyCode.F11));
            CK_Capture360       = new SavedKeyboardShortcut("Take 360 screenshot", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftControl));
            CK_CaptureAlphaIn3D = new SavedKeyboardShortcut("Take rendered 3D screenshot", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftAlt));
            CK_Capture360in3D   = new SavedKeyboardShortcut("Take 360 3D screenshot", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftControl, KeyCode.LeftShift));
            CK_Gui = new SavedKeyboardShortcut("Open settings window", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            ResolutionX           = new ConfigWrapper <int>("resolution-x", this, Screen.width);
            ResolutionY           = new ConfigWrapper <int>("resolution-y", this, Screen.height);
            Resolution360         = new ConfigWrapper <int>("resolution-360", this, 4096);
            EyeSeparation         = new ConfigWrapper <float>("3d-eye-separation", this, 0.18f);
            ImageSeparationOffset = new ConfigWrapper <float>("3d-image-stitching-offset", this, 0.25f);

            ResolutionX.SettingChanged += (sender, args) => ResolutionXBuffer = ResolutionX.Value.ToString();
            ResolutionY.SettingChanged += (sender, args) => ResolutionYBuffer = ResolutionY.Value.ToString();

            DownscalingRate     = new ConfigWrapper <int>("downscalerate", this, 2);
            CardDownscalingRate = new ConfigWrapper <int>("carddownscalerate", this, 3);
            CaptureAlpha        = new ConfigWrapper <bool>("capturealpha", this, true);

            UseJpg     = new ConfigWrapper <bool>("jpg", this, false);
            JpgQuality = new ConfigWrapper <int>("jpg-quality", this, 100);

            ScreenshotMessage      = new ConfigWrapper <bool>("screenshotmessage", this, true);
            ScreenshotNameFormat   = new ConfigWrapper <NameFormat>("screenshot-name-format", this, NameFormat.NameDateType);
            ScreenshotNameOverride = new ConfigWrapper <string>("screenshot-name-override", this, "");

            SceneManager.sceneLoaded += (s, a) => InstallSceenshotHandler();
            InstallSceenshotHandler();

            if (!Directory.Exists(screenshotDir))
            {
                Directory.CreateDirectory(screenshotDir);
            }

            Hooks.InstallHooks();

            I360Render.Init();
        }
Esempio n. 25
0
        void Awake()
        {
            ViewOffset = new ConfigWrapper <float>("ViewOffset", this, 0.03f);
            DefaultFov = new ConfigWrapper <float>("DefaultFov", this, 70f);
            MouseSens  = new ConfigWrapper <float>("MouseSens", this, 1f);
            PovHotkey  = new SavedKeyboardShortcut("PovHotkey", this, new KeyboardShortcut(KeyCode.Backspace));

            harmony = HarmonyInstance.Create("keelhauled.realpov.harmony");
            harmony.PatchAll(GetType());

            currentChara = FindObjectOfType <ChaControl>();
            currentFov   = DefaultFov.Value;

            foreach (var item in currentChara.neckLookCtrl.neckLookScript.aBones)
            {
                item.neckBone.rotation = new Quaternion();
            }
        }
Esempio n. 26
0
        StudioAddonLite()
        {
            MOVE_RATIO   = new ConfigWrapper <float>("MOVE_RATIO", this, 2.5f);
            ROTATE_RATIO = new ConfigWrapper <float>("ROTATE_RATIO", this, 90f);
            SCALE_RATIO  = new ConfigWrapper <float>("SCALE_RATIO", this, 0.5f);

            KEY_OBJ_MOVE_XZ = new SavedKeyboardShortcut("KEY_OBJ_MOVE_XZ", this, new KeyboardShortcut(KeyCode.G));
            KEY_OBJ_MOVE_Y  = new SavedKeyboardShortcut("KEY_OBJ_MOVE_Y", this, new KeyboardShortcut(KeyCode.H));

            KEY_OBJ_ROT_X   = new SavedKeyboardShortcut("KEY_OBJ_ROT_X", this, new KeyboardShortcut(KeyCode.G, KeyCode.LeftShift));
            KEY_OBJ_ROT_Y   = new SavedKeyboardShortcut("KEY_OBJ_ROT_Y", this, new KeyboardShortcut(KeyCode.H, KeyCode.LeftShift));
            KEY_OBJ_ROT_Z   = new SavedKeyboardShortcut("KEY_OBJ_ROT_Z", this, new KeyboardShortcut(KeyCode.Y, KeyCode.LeftShift));
            KEY_OBJ_ROT_X_2 = new SavedKeyboardShortcut("KEY_OBJ_ROT_X_2", this, new KeyboardShortcut(KeyCode.G));
            KEY_OBJ_ROT_Y_2 = new SavedKeyboardShortcut("KEY_OBJ_ROT_Y_2", this, new KeyboardShortcut(KeyCode.H));
            KEY_OBJ_ROT_Z_2 = new SavedKeyboardShortcut("KEY_OBJ_ROT_Z_2", this, new KeyboardShortcut(KeyCode.Y));

            KEY_OBJ_SCALE_ALL = new SavedKeyboardShortcut("KEY_OBJ_SCALE_ALL", this, new KeyboardShortcut(KeyCode.T));
            KEY_OBJ_SCALE_X   = new SavedKeyboardShortcut("KEY_OBJ_SCALE_X", this, new KeyboardShortcut(KeyCode.G));
            KEY_OBJ_SCALE_Y   = new SavedKeyboardShortcut("KEY_OBJ_SCALE_Y", this, new KeyboardShortcut(KeyCode.H));
            KEY_OBJ_SCALE_Z   = new SavedKeyboardShortcut("KEY_OBJ_SCALE_Z", this, new KeyboardShortcut(KeyCode.Y));
        }
        void Awake()
        {
            CK_Capture      = new SavedKeyboardShortcut("Take screenshot", this, new KeyboardShortcut(KeyCode.F9));
            CK_CaptureAlpha = new SavedKeyboardShortcut("Take character screenshot", this, new KeyboardShortcut(KeyCode.F11));
            CK_Gui          = new SavedKeyboardShortcut("Open settings window", this, new KeyboardShortcut(KeyCode.F11, KeyCode.LeftShift));

            ResolutionX         = new ConfigWrapper <int>("resolution-x", this, Screen.width);
            ResolutionY         = new ConfigWrapper <int>("resolution-y", this, Screen.height);
            DownscalingRate     = new ConfigWrapper <int>("downscalerate", this, 2);
            CardDownscalingRate = new ConfigWrapper <int>("carddownscalerate", this, 2);
            CaptureAlpha        = new ConfigWrapper <bool>("capturealpha", this, true);

            SceneManager.sceneLoaded += (s, a) => Install();
            Install();

            if (!Directory.Exists(screenshotDir))
            {
                Directory.CreateDirectory(screenshotDir);
            }

            Hooks.InstallHooks();
        }
Esempio n. 28
0
        private void Start()
        {
            if (!KoikatuAPI.CheckRequiredPlugin(this, KoikatuAPI.GUID, new Version("1.2")) ||
                !KoikatuAPI.CheckRequiredPlugin(this, "com.joan6694.illusionplugins.moreaccessories", new Version("1.0.3")))
            {
                return;
            }

            if (StudioAPI.InsideStudio)
            {
                enabled = false;
                return;
            }

            Show = new ConfigWrapper <bool>("Show", this, false);
            ShowCoordinateButtons = new ConfigWrapper <bool>("ShowCoordinateButtons", this, false);
            Keybind = new SavedKeyboardShortcut("keybind", this, new KeyboardShortcut(KeyCode.Tab, KeyCode.LeftShift));

            KoikatuAPI.CheckIncompatiblePlugin(this, "MoreAccessories_CSM");

            MakerAPI.RegisterCustomSubCategories += MakerAPI_Enter;
            MakerAPI.MakerExiting += MakerAPI_Exit;
        }
Esempio n. 29
0
 private void Main()
 {
     AnimationControllerHotkey = new SavedKeyboardShortcut(nameof(AnimationControllerHotkey), nameof(KK_AnimationController), new KeyboardShortcut(KeyCode.Minus));
     CharacterApi.RegisterExtraBehaviour <AnimationControllerCharaController>(GUID);
     StudioSaveLoadApi.RegisterExtraBehaviour <AnimationControllerSceneController>(GUID);
 }
Esempio n. 30
0
 MakerBridge()
 {
     SendChara = new SavedKeyboardShortcut("SendChara", this, new KeyboardShortcut(KeyCode.C));
 }