-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
45 changed files
with
582 additions
and
190 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,7 +6,7 @@ | |
/** | ||
* Public math utilities. | ||
* | ||
* @author Qboi123 | ||
* @author XyperCode | ||
*/ | ||
public class MathUtil { | ||
/** | ||
|
76 changes: 29 additions & 47 deletions
76
common/src/main/java/com/ultreon/mods/advanceddebug/client/Config.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,50 +1,32 @@ | ||
package com.ultreon.mods.advanceddebug.client; | ||
|
||
import com.ultreon.libs.commons.v0.Identifier; | ||
import com.ultreon.mods.advanceddebug.api.client.menu.DebugPage; | ||
import com.ultreon.mods.advanceddebug.client.menu.DebugGui; | ||
import dev.architectury.injectables.annotations.ExpectPlatform; | ||
import net.minecraft.resources.ResourceLocation; | ||
import net.minecraftforge.common.ForgeConfigSpec; | ||
|
||
import java.util.ArrayList; | ||
import java.util.List; | ||
|
||
public class Config { | ||
public static final ForgeConfigSpec.BooleanValue SHOW_FPS_ON_DEFAULT_PAGE; | ||
public static final ForgeConfigSpec.BooleanValue SHOW_CURRENT_PAGE; | ||
public static final ForgeConfigSpec.BooleanValue USE_CUSTOM_SCALE; | ||
public static final ForgeConfigSpec.IntValue CUSTOM_SCALE; | ||
public static final ForgeConfigSpec.BooleanValue SPACED_NAMESPACES; | ||
public static final ForgeConfigSpec.BooleanValue SPACED_ENUM_CONSTANTS; | ||
public static final ForgeConfigSpec.BooleanValue ENABLE_BUBBLE_BLASTER_ID; | ||
public static final ForgeConfigSpec.ConfigValue<List<? extends String>> ENABLED_PAGES; | ||
|
||
static final ForgeConfigSpec.Builder CLIENT_BUILDER = new ForgeConfigSpec.Builder(); | ||
|
||
|
||
static { | ||
SHOW_FPS_ON_DEFAULT_PAGE = CLIENT_BUILDER.comment("Show FPS on default page").define("show_fps_on_default_page", false); | ||
SHOW_CURRENT_PAGE = CLIENT_BUILDER.comment("Show current page").define("show_current_page", true); | ||
USE_CUSTOM_SCALE = CLIENT_BUILDER.comment("Use scale other than in options").define("use_custom_scale", false); | ||
CUSTOM_SCALE = CLIENT_BUILDER.comment("Custom scale to set").defineInRange("custom_scale", 2, 1, 4); | ||
|
||
List<String> pages = DebugGui.get().getPages().stream().map(DebugPage::getId).map(Identifier::toString).toList(); | ||
ENABLED_PAGES = CLIENT_BUILDER.comment("Enabled pages").defineList("enabled_pages", new ArrayList<>(pages), page -> page instanceof String pageName && pages.contains(pageName)); | ||
|
||
CLIENT_BUILDER.push("formatting"); | ||
SPACED_NAMESPACES = CLIENT_BUILDER.comment("Spaced namespaces").define("spaced_namespaces", true); | ||
SPACED_ENUM_CONSTANTS = CLIENT_BUILDER.comment("Spaced enum constants").define("spaced_enum_constants", true); | ||
ENABLE_BUBBLE_BLASTER_ID = CLIENT_BUILDER.comment("Enable Bubble Blaster ID (Easter Egg)").define("enable_bubble_blaster_id", false); | ||
CLIENT_BUILDER.pop(); | ||
} | ||
|
||
@ExpectPlatform | ||
public static void register(Object context) { | ||
|
||
} | ||
|
||
public static ForgeConfigSpec build() { | ||
return CLIENT_BUILDER.build(); | ||
} | ||
import com.ultreon.mods.advanceddebug.api.IAdvancedDebug; | ||
import io.github.xypercode.craftyconfig.ConfigEntry; | ||
import io.github.xypercode.craftyconfig.ConfigInfo; | ||
import io.github.xypercode.craftyconfig.CraftyConfig; | ||
import io.github.xypercode.craftyconfig.Ranged; | ||
|
||
@ConfigInfo(fileName = "advanced-debug", modId = IAdvancedDebug.MOD_ID) | ||
public class Config extends CraftyConfig { | ||
@ConfigEntry(path = "showFpsOnDefaultPage", comment = "Show FPS on default page") | ||
public static boolean showFpsOnDefaultPage = false; | ||
|
||
@ConfigEntry(path = "showCurrentPage", comment = "Show current page") | ||
public static boolean showCurrentPage = true; | ||
|
||
@ConfigEntry(path = "useCustomScale", comment = "Use scale other than in options") | ||
public static boolean useCustomScale = false; | ||
|
||
@ConfigEntry(path = "customScale", comment = "Custom scale to set") | ||
@Ranged(min = 1, max = 4) | ||
public static int customScale = 2; | ||
|
||
@ConfigEntry(path = "spacedNamespaces", comment = "Spaced namespaces") | ||
public static boolean spacedNamespaces = true; | ||
|
||
@ConfigEntry(path = "spacedEnumConstants", comment = "Spaced enum constants") | ||
public static boolean spacedEnumConstants = true; | ||
|
||
@ConfigEntry(path = "enableBubbleBlasterId", comment = "Enable Bubble Blaster ID") | ||
public static boolean enableBubbleBlasterId = false; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.