Jump to content

Forge config gui


fuzzybat23

Recommended Posts

33 minutes ago, fuzzybat23 said:

Oh, the full path as it appears in the config.cfg file, then?

 

Yes.

 

17 minutes ago, fuzzybat23 said:

Ok... I did something and I have no idea what, but the game crashes as Forge begins to load.  It generates the cfg file, but it's blank.

 


net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from Custom Selection Box Revised (csbr)
Caused by: net.minecraftforge.fml.common.LoaderException: java.lang.RuntimeException: Error syncing field 'Red' of class 'com.fuzzybat23.csbr.ModConfig$Frame'!
	at net.minecraftforge.common.config.ConfigManager.sync(ConfigManager.java:192)
	at net.minecraftforge.fml.common.FMLModContainer.constructMod(FMLModContainer.java:609)
	...
Caused by: java.lang.RuntimeException: Error syncing field 'Red' of class 'com.fuzzybat23.csbr.ModConfig$Frame'!
	...
Caused by: java.util.regex.PatternSyntaxException: Unmatched closing ')' near index 8
general.1) custom selection box frame.
        ^
	at java.util.regex.Pattern.error(Pattern.java:1955)
	at java.util.regex.Pattern.compile(Pattern.java:1700)
	at java.util.regex.Pattern.<init>(Pattern.java:1351)
	at java.util.regex.Pattern.compile(Pattern.java:1028)
	at java.lang.String.replaceFirst(String.java:2178)
	at net.minecraftforge.common.config.ConfigManager.sync(ConfigManager.java:252)
	... 45 more

 

Forge uses your category names in a regular expression (for String#replaceFirst), so they can't contain any characters that have a special meaning in regular expressions (e.g parentheses).

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

Well, whatever it was I did with those (), that was keeping the cycle string box from saving.  Everything in my config file saves as it should, now.  Weird.  Anyway,

 

        ConfigCategory cat = config.getCategory("general.aFrame");
        Property prop = cat.get("Red");

 

for getting the category and prop, right, if the ModConfig is structured as so

 

@Config(modid = CSBR.MODID)
@LangKey("csbr.config.title")
public class ModConfig
{
    @Name("Custom Selection Box Frame")
    @Comment("Color and opacity for custom selection box wire frame.")
    public static final Frame aFrame = new Frame();

    @Name("Custom Selection Box Cube")
    @Comment("Color and opacity for custom selection box inner cube.")
    public static final BlinkAnimation bBlink = new BlinkAnimation();

    @Name("Custom Selection Box Animation")
    @Comment({"Break animation style and toggle the depth", "buffer for the custom selection box wire frame.."})
    public static final BreakAnimation cBreak = new BreakAnimation();

    public static class Frame
    {
        @Name("1) Red")
        @Comment("Choose a value for red between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Red = 255;

        @Name("2) Green")
        @Comment("Choose a value for green between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Green = 255;

        @Name("3) Blue")
        @Comment("Choose a value for blue between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Blue = 255;

        @Name("4) Alpha Channel")
        @Comment("Choose a value for the opacity between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Alpha = 255;

        @Name("5) Wire Thickness")
        @Comment("Choose a value for the wire frame thickness between 1 and 7.")
        @RangeInt(min = 1, max = 7)
        public int Width = 2;
    }

    public static class BlinkAnimation
    {
        @Name("1) Red")
        @Comment("Choose a value for red between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Red = 255;

        @Name("2) Green")
        @Comment("Choose a value for green between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Green = 255;

        @Name("3) Blue")
        @Comment("Choose a value for blue between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Blue = 255;

        @Name("4) Alpha Channel")
        @Comment("Choose a value for the opacity between 0 and 255.")
        @RangeInt(min = 0, max = 255)
        public int Alpha = 255;
    }

    public static class BreakAnimation
    {
        @Name("2) Break Animation")
        @Comment("Break Animation")
        public enumAnimation animation = enumAnimation.NONE;

        @Name("2) Blink Animation Speed")
        @Comment("Choose how fast the custom selection box blinks.")
        @RangeInt(min = 0, max = 100)
        public int Speed = 0;

        @Name("3) Depth Buffer")
        @Comment("Enable or disable the depth buffer for the custom selection box wire frame.")
        public boolean dBuffer = false;

        public enum enumAnimation
        {
            NONE,
            SHRINK,
            DOWN,
            ALPHA
        }
    }

 

Link to comment
Share on other sites

30 minutes ago, fuzzybat23 said:

Weird.  Anyway,

 


        ConfigCategory cat = config.getCategory("general.aFrame");
        Property prop = cat.get("Red");

 

for getting the category and prop, right, if the ModConfig is structured as so

 

That looks correct, yes.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

And if I want all the props in aFrame to have the slider, I'd need to set it up more like this, right?

 

	ConfigCategory cat = config.getCategory("general.aFrame");
	Property propRed = cat.get("Red");
	Property propGreen = cat.get("Green");
	Property propBlue = cat.get("Blue");
	Property propAlpha = cat.get("Alpha");
	Property propWidth = cat.get("Width");

 

Link to comment
Share on other sites

2 minutes ago, fuzzybat23 said:

Now that we have the prop, how do we set NumberSliderEntry as its config GUI entry type?

 

Call Property#setConfigEntryClass with NumberSliderEntry.class as the argument.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

1 minute ago, fuzzybat23 said:

And if I want all the props in aFrame to have the slider, I'd need to set it up more like this, right?

 


	ConfigCategory cat = config.getCategory("general.aFrame");
	Property propRed = cat.get("Red");
	Property propGreen = cat.get("Green");
	Property propBlue = cat.get("Blue");
	Property propAlpha = cat.get("Alpha");
	Property propWidth = cat.get("Width");

 

You'll need to call Property#setConfigEntryClass on each of those Property objects, yes.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

I'm going to try to get a little fancy here.  Like this, right?

        ConfigCategory cat = config.getCategory("general.aFrame");
        Property propaFrame[] = new Property[5];
        propaFrame[0] = cat.get("Red");
        propaFrame[1] = cat.get("Green");
        propaFrame[2] = cat.get("Blue");
        propaFrame[3] = cat.get("Alpha");
        propaFrame[4] = cat.get("Width");

        for(Property p:propaFrame)
        {
            p.setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
        }

 

Link to comment
Share on other sites

8 minutes ago, fuzzybat23 said:

I'm going to try to get a little fancy here.  Like this, right?


        ConfigCategory cat = config.getCategory("general.aFrame");
        Property propaFrame[] = new Property[5];
        propaFrame[0] = cat.get("Red");
        propaFrame[1] = cat.get("Green");
        propaFrame[2] = cat.get("Blue");
        propaFrame[3] = cat.get("Alpha");
        propaFrame[4] = cat.get("Width");

        for(Property p:propaFrame)
        {
            p.setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
        }

 

 

That should work, yes. You can also use ConfigCategory#getValues to get an immutable copy of the category's property names and properties (and use Map#getValues to get a collection of the Map's values) or ConfigCategory#getOrderedValues to get an ordered immutable copy of the category's properties.

Edited by Choonster

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

Just now, fuzzybat23 said:

I don't have much experience with the immutable..  Something like this?

 


        List<Property> props = new ArrayList<Property>(cat.getOrderedValues());
        for(Property p:props)
        {
            p.setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
        }

 

 

You don't need to create a new List, ConfigCategory#getOrderedValues already returns a List; just iterate through it directly.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

I don't suppose there's a way to get a block at the bottom, under Wire Thickness, that will change colors according to the slider values? ;D  Kind of like the chat color picker.  In that case, I'd probably drop the red green blue entirely and just go with the basic, what is it.. 16 colors that Minecraft uses?  Either way, this is exactly what I was looking for.  Thanks!  More in depth tutorials on the @config system need to me made for this reason xD 

 

I did find the source for that, too.  I guess if I went that route, it would be a cycle value button instead of a number slider.  The number slider would still be used for the animation speed, frame thickness and alpha channels, though.

 

 

/**
 * ChatColorEntry
 *
 * Provides a GuiButton that cycles through the list of chat color codes.
 */
public static class ChatColorEntry extends CycleValueEntry
{
    ChatColorEntry(GuiConfig owningScreen, GuiConfigEntries owningEntryList, IConfigElement configElement)
    {
        super(owningScreen, owningEntryList, configElement);
        this.btnValue.enabled = enabled();
        updateValueButtonText();
    }

    @Override
    public void drawEntry(int slotIndex, int x, int y, int listWidth, int slotHeight, int mouseX, int mouseY, boolean isSelected, float partial)
    {
        this.btnValue.packedFGColour = GuiUtils.getColorCode(this.configElement.getValidValues()[currentIndex].charAt(0), true);
        super.drawEntry(slotIndex, x, y, listWidth, slotHeight, mouseX, mouseY, isSelected, partial);
    }

    @Override
    public void updateValueButtonText()
    {
        this.btnValue.displayString = I18n.format(configElement.getValidValues()[currentIndex]) + " - " + I18n.format("fml.configgui.sampletext");
    }
}

Capture.JPG

Edited by fuzzybat23
Link to comment
Share on other sites

48 minutes ago, fuzzybat23 said:

I think I see.


        for(int i = 0; i < cat.getOrderedValues().size(); i++)
        {
            cat.getOrderedValues().get(i).setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
        }

 

Why are you using an indexed for loop? Use a for-each/enhanced for loop like you were before, but iterate through the returned List directly instead of creating a new one.

 

Each call to ConfigCategory#getOrderedValues creates a new copy of the List, so you should call it once and store the result in a local variable rather than calling it every iteration of the loop.

 

 

33 minutes ago, fuzzybat23 said:

I don't suppose there's a way to get a block at the bottom, under Wire Thickness, that will change colors according to the slider values? ;D

 

You'd need to implement this yourself, I can't really help you with much GUI-related stuff. Using ChatColorEntry is probably easier.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

It didn't work before xD  I just tried this again and tested it and it does seem to work.  Little cleaner looking, too, I think.

        for(Property p: cat.getOrderedValues())
        {
            p.setConfigEntryClass(GuiConfigEntries.NumberSliderEntry.class);
        }

 

Anyway, yeah, I was thinking about ChatColorEntry too.  I tried to test it with the enum I already had setup.

 ConfigCategory cat2 = config.getCategory("general.custom selection box animation");
 Property prop = cat2.get("animation");
 prop.setConfigEntryClass(GuiConfigEntries.ChatColorEntry.class);

 

but all that did was throw an error.

Time: 7/15/17 9:23 AM
Description: There was a severe problem during mod loading that has caused the game to fail

net.minecraftforge.fml.common.LoaderExceptionModCrash: Caught exception from Custom Selection Box Revised (csbr)
Caused by: java.lang.NullPointerException
	at com.fuzzybat23.csbr.CSBR.preInit(CSBR.java:82)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at net.minecraftforge.fml.common.FMLModContainer.handleModStateEvent(FMLModContainer.java:630)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
	at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
	at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
	at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
	at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
	at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
	at com.google.common.eventbus.EventBus.post(EventBus.java:217)
	at net.minecraftforge.fml.common.LoadController.sendEventToModContainer(LoadController.java:252)
	at net.minecraftforge.fml.common.LoadController.propogateStateMessage(LoadController.java:230)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at com.google.common.eventbus.Subscriber.invokeSubscriberMethod(Subscriber.java:91)
	at com.google.common.eventbus.Subscriber$SynchronizedSubscriber.invokeSubscriberMethod(Subscriber.java:150)
	at com.google.common.eventbus.Subscriber$1.run(Subscriber.java:76)
	at com.google.common.util.concurrent.MoreExecutors$DirectExecutor.execute(MoreExecutors.java:399)
	at com.google.common.eventbus.Subscriber.dispatchEvent(Subscriber.java:71)
	at com.google.common.eventbus.Dispatcher$PerThreadQueuedDispatcher.dispatch(Dispatcher.java:116)
	at com.google.common.eventbus.EventBus.post(EventBus.java:217)
	at net.minecraftforge.fml.common.LoadController.distributeStateMessage(LoadController.java:147)
	at net.minecraftforge.fml.common.Loader.preinitializeMods(Loader.java:604)
	at net.minecraftforge.fml.client.FMLClientHandler.beginMinecraftLoading(FMLClientHandler.java:266)
	at net.minecraft.client.Minecraft.init(Minecraft.java:508)
	at net.minecraft.client.Minecraft.run(Minecraft.java:416)
	at net.minecraft.client.main.Main.main(Main.java:118)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at net.minecraft.launchwrapper.Launch.launch(Launch.java:135)
	at net.minecraft.launchwrapper.Launch.main(Launch.java:28)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at net.minecraftforge.gradle.GradleStartCommon.launch(GradleStartCommon.java:97)
	at GradleStart.main(GradleStart.java:26)


A detailed walkthrough of the error, its code path and all known details is as follows:
---------------------------------------------------------------------------------------

-- System Details --
Details:
	Minecraft Version: 1.12
	Operating System: Windows 10 (amd64) version 10.0
	Java Version: 1.8.0_131, Oracle Corporation
	Java VM Version: Java HotSpot(TM) 64-Bit Server VM (mixed mode), Oracle Corporation
	Memory: 891752248 bytes (850 MB) / 1135607808 bytes (1083 MB) up to 3808428032 bytes (3632 MB)
	JVM Flags: 0 total; 
	IntCache: cache: 0, tcache: 0, allocated: 0, tallocated: 0
	FML: MCP 9.40 Powered by Forge 14.21.1.2387 6 mods loaded, 6 mods active
	States: 'U' = Unloaded 'L' = Loaded 'C' = Constructed 'H' = Pre-initialized 'I' = Initialized 'J' = Post-initialized 'A' = Available 'D' = Disabled 'E' = Errored
	UCH	minecraft{1.12} [Minecraft] (minecraft.jar) 
	UCH	mcp{9.19} [Minecraft Coder Pack] (minecraft.jar) 
	UCH	FML{8.0.99.99} [Forge Mod Loader] (forgeSrc-1.12-14.21.1.2387.jar) 
	UCH	forge{14.21.1.2387} [Minecraft Forge] (forgeSrc-1.12-14.21.1.2387.jar) 
	UCE	csbr{1.0} [Custom Selection Box Revised] (CSBR_main) 
	UCH	squeedometer{1.0.3} [Squeedometer] (Squeedometer-mc1.12.x-1.0.3.jar) 
	Loaded coremods (and transformers): 
	GL info: ' Vendor: 'NVIDIA Corporation' Version: '4.5.0 NVIDIA 384.76' Renderer: 'GeForce GTX 770/PCIe/SSE2'
[09:23:11] [main/INFO] [STDOUT]: [net.minecraft.init.Bootstrap:printToSYSOUT:629]: #@!@# Game crashed! Crash report saved to: #@!@# E:\Users\RigAlpha\Documents\My Projects\Minecraft\Git\CSBR\run\.\crash-reports\crash-2017-07-15_09.23.11-client.txt

Process finished with exit code -1

 

Link to comment
Share on other sites

Instead of an Enum, I should instead use an array

@Name("2) Break Animation")
@Comment("Break Animation")
public String[] animation = new String[] {"NONE", "SHRINK", "DOWN", "ALPHA"};

 

and use GuiConfigEntries.ChatColorEntry.class on that?

Edited by fuzzybat23
Link to comment
Share on other sites

1 hour ago, fuzzybat23 said:

Caused by: java.lang.NullPointerException

at com.fuzzybat23.csbr.CSBR.preInit(CSBR.java:82)

 

Something was null on line 82 of CSBR (in the preInit method). If line 82 is the Property#setConfigEntryClass call, the Property is null. This is probably because you renamed it with @Config.Name, so it's not called animation.

 

1 hour ago, fuzzybat23 said:

Instead of an Enum, I should instead use an array


@Name("2) Break Animation")
@Comment("Break Animation")
public String[] animation = new String[] {"NONE", "SHRINK", "DOWN", "ALPHA"};

 

and use GuiConfigEntries.ChatColorEntry.class on that?

 

No. You want a single value chosen from a fixed set, so use an enum. If you wanted an arbitrary number of Strings, you'd use a String array.

 

 

I've just discovered that Property#setConfigEntryClass doesn't actually work with GuiConfigEntries.ChatColorEntry because the constructor isn't public. I'll report this shortly, so hopefully it will be fixed.

 

I've reported this here.

Edited by Choonster

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

Well crap, this was doomed to failure from the start then xD  Hope they do get that fixed soon.  For now, I'll just keep it in the rgb slider system.  Now I need to plug in the main guts of my mod to test it out fully.  Thanks again :>  Hopefully this thread will help out anyone else looking up the annotation system.  There really should be a section in Docs detailing everything that the annotation @Config system can do.  Doesn't make sense to introduce a powerful and simple modding tool and not tell anyone about it :P

Link to comment
Share on other sites

Oh yeah!  There was one other thing I just thought of.  With the enum control (None, shrink, down, alpha)  If any but NONE are selected, how can I force it to set DepthBuffer boolean to true in real time.  Say, the cycle button is on NONE by default.  You click it to SHRINK and the button for Depth Buffer immediately greens with true being set.

Caputure 1.JPG

Capture 2.JPG

Link to comment
Share on other sites

9 hours ago, fuzzybat23 said:

There really should be a section in Docs detailing everything that the annotation @Config system can do.  Doesn't make sense to introduce a powerful and simple modding tool and not tell anyone about it :P

 

Forge is documented by the community, you can submit a Pull Request here to add/modify documentation.

 

 

9 hours ago, fuzzybat23 said:

If any but NONE are selected, how can I force it to set DepthBuffer boolean to true in real time.  Say, the cycle button is on NONE by default.  You click it to SHRINK and the button for Depth Buffer immediately greens with true being set.

 

I think you'd need to make your own IConfigEntry for this.

 

If the Depth Buffer setting is solely controlled by the Break Animation setting, is there any reason to have it user-configurable at all?

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

6 minutes ago, fuzzybat23 said:

So what would this IConfigEntry look like?

 

You could copy CycleValueEntry (since you can't extend it) and override CycleValueEntry#valueButtonPressed and CycleValueEntry#setToDefault to call the super methods and then modify the Depth Buffer setting. I'm not sure exactly how you'd do this, you'd need to work this out yourself.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

I suppose that when I load the values from the config file into the variables located in my main class, I could have it set the value of the config file to true if any animation is selected but NONE.  That way, no matter what is picked in the config file, for the depth buffer, it will default to having the depth buffer disabled for those animations.

public class CSBR
{
    public static float Red;
    public static float Green;
    public static float Blue;
    public static float Alpha;
    public static float Width;

    public static float bRed;
    public static float bGreen;
    public static float bBlue;
    public static float bAlpha;
    public static float Speed;

    public static int Animation;
    public static boolean DepthBuffer;

	@Mod.EventHandler
    @SideOnly(Side.CLIENT)
    public void preInit(FMLPreInitializationEvent event) throws InvocationTargetException, IllegalAccessException
    {
        Red = ModConfig.aFrame.Red;
        Green = ModConfig.aFrame.Green;
        Blue = ModConfig.aFrame.Blue;
        Alpha = ModConfig.aFrame.Alpha;
        Width = ModConfig.aFrame.Width;

        bRed = ModConfig.bBlink.Red;
        bGreen = ModConfig.bBlink.Green;
        bBlue = ModConfig.bBlink.Blue;
        bAlpha = ModConfig.bBlink.Alpha;

		ConfigCategory csba = config.getCategory("general.custom selection box animation");
        Property csba_depth_prop = csba.get("3) Depth Buffer");
        switch(ModConfig.cBreak.Animation)
        {
            case NONE:
                Animation = 0;
                break;

            case SHRINK:
			{
                Animation = 1;
				csba_depth_prop.setValue(true);
				break;

            case DOWN:
                Animation = 2;
				csba_depth_prop.setValue(true);
                break;

            case ALPHA:
                Animation = 3;
				csba_depth_prop.setValue(true);
                break;

            default:
                Animation = 0;
        }

        DepthBuffer = ModConfig.cBreak.dBuffer;
        Speed = ModConfig.cBreak.Speed;
}

 

It wouldn't change the state of the Depth Buffer button on the config screen as the animation is picked, but I don't really care about that.  As long as the internal code knows to turn it off if those animations are set is what's important.

Edited by fuzzybat23
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements




  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • This honestly might just work for you @SubscribeEvent public static void onScreenRender(ScreenEvent.Render.Post event) { final var player = Minecraft.getInstance().player; if(!hasMyEffect(player)) return; // TODO: You provide hasMyEffect float f = Mth.lerp(p_109094_, this.minecraft.player.oSpinningEffectIntensity, this.minecraft.player.spinningEffectIntensity); float f1 = ((Double)this.minecraft.options.screenEffectScale().get()).floatValue(); if(f <= 0F || f1 >= 1F) return; float p_282656_ = ?; final var p_282460_ = event.getGuiGraphics(); int i = p_282460_.guiWidth(); int j = p_282460_.guiHeight(); p_282460_.pose().pushPose(); float f = Mth.lerp(p_282656_, 2.0F, 1.0F); p_282460_.pose().translate((float)i / 2.0F, (float)j / 2.0F, 0.0F); p_282460_.pose().scale(f, f, f); p_282460_.pose().translate((float)(-i) / 2.0F, (float)(-j) / 2.0F, 0.0F); float f1 = 0.2F * p_282656_; float f2 = 0.4F * p_282656_; float f3 = 0.2F * p_282656_; RenderSystem.disableDepthTest(); RenderSystem.depthMask(false); RenderSystem.enableBlend(); RenderSystem.blendFuncSeparate(SourceFactor.ONE, DestFactor.ONE, SourceFactor.ONE, DestFactor.ONE); p_282460_.setColor(f1, f2, f3, 1.0F); p_282460_.blit(NAUSEA_LOCATION, 0, 0, -90, 0.0F, 0.0F, i, j, i, j); p_282460_.setColor(1.0F, 1.0F, 1.0F, 1.0F); RenderSystem.defaultBlendFunc(); RenderSystem.disableBlend(); RenderSystem.depthMask(true); RenderSystem.enableDepthTest(); p_282460_.pose().popPose(); }   Note: Most of this is directly copied from GameRenderer as you pointed out you found. The only thing you'll have to likely do is update the `oSpinningEffectIntensity` + `spinningEffectIntensity` variables on the player when your effect is applied. Which values should be there? Not 100% sure, might be a game of guess and check, but `handleNetherPortalClient` in LocalPlayer has some hard coded you might be able to start with.
    • Dalam dunia perjudian online yang berkembang pesat, mencari platform yang dapat memberikan kemenangan maksimal dan hasil terbaik adalah impian setiap penjudi. OLXTOTO, dengan bangga, mempersembahkan dirinya sebagai jawaban atas pencarian itu. Sebagai platform terbesar untuk kemenangan maksimal dan hasil optimal, OLXTOTO telah menciptakan gelombang besar di komunitas perjudian online. Satu dari banyak keunggulan yang dimiliki OLXTOTO adalah koleksi permainan yang luas dan beragam. Dari togel hingga slot online, dari live casino hingga permainan kartu klasik, OLXTOTO memiliki sesuatu untuk setiap pemain. Dibangun dengan teknologi terkini dan dikembangkan oleh para ahli industri, setiap permainan di platform ini dirancang untuk memberikan pengalaman yang tak tertandingi bagi para penjudi. Namun, keunggulan OLXTOTO tidak hanya terletak pada variasi permainan yang mereka tawarkan. Mereka juga menonjol karena komitmen mereka terhadap keamanan dan keadilan. Dengan sistem keamanan tingkat tinggi dan proses audit yang ketat, OLXTOTO memastikan bahwa setiap putaran permainan berjalan dengan adil dan transparan. Para pemain dapat merasa aman dan yakin bahwa pengalaman berjudi mereka di OLXTOTO tidak akan terganggu oleh masalah keamanan atau keadilan. Tak hanya itu, OLXTOTO juga terkenal karena layanan pelanggan yang luar biasa. Tim dukungan mereka selalu siap sedia untuk membantu para pemain dengan segala pertanyaan atau masalah yang mereka hadapi. Dengan respon cepat dan solusi yang efisien, OLXTOTO memastikan bahwa pengalaman berjudi para pemain tetap mulus dan menyenangkan. Dengan semua fitur dan keunggulan yang ditawarkannya, tidak mengherankan bahwa OLXTOTO telah menjadi pilihan utama bagi jutaan penjudi online di seluruh dunia. Jika Anda mencari platform yang dapat memberikan kemenangan maksimal dan hasil optimal, tidak perlu mencari lebih jauh dari OLXTOTO. Bergabunglah dengan OLXTOTO hari ini dan mulailah petualangan Anda menuju kemenangan besar dan hasil terbaik!
    • Selamat datang di OLXTOTO, situs slot gacor terpanas yang sedang booming di industri perjudian online. Jika Anda mencari pengalaman bermain yang luar biasa, maka OLXTOTO adalah tempat yang tepat untuk Anda. Dapatkan sensasi tidak biasa dengan variasi slot online terlengkap dan peluang memenangkan jackpot slot maxwin yang sering. Di sini, Anda akan merasakan keseruan yang luar biasa dalam bermain judi slot. DAFTAR OLXTOTO DISINI LOGIN OLXTOTO DISINI AKUN PRO OLXTOTO DISINI   Jackpot Slot Maxwin Sering Untuk Peluang Besar Di OLXTOTO, kami tidak hanya memberikan hadiah slot biasa, tapi juga memberikan kesempatan kepada pemain untuk memenangkan jackpot slot maxwin yang sering. Dengan demikian, Anda dapat meraih keberuntungan besar dan memenangkan ribuan rupiah sebagai hadiah jackpot slot maxwin kami. Jackpot slot maxwin merupakan peluang besar bagi para pemain judi slot untuk meraih keuntungan yang lebih besar. Dalam permainan kami, Anda tidak harus terpaku pada kemenangan biasa saja. Kami hadir dengan jackpot slot maxwin yang sering, sehingga Anda memiliki peluang yang lebih besar untuk meraih kemenangan besar dengan hadiah yang menggiurkan. Dalam permainan judi slot, pengalaman bermain bukan hanya tentang keseruan dan hiburan semata. Kami memahami bahwa para pemain juga menginginkan kesempatan untuk meraih keberuntungan besar. Oleh karena itu, OLXTOTO hadir dengan jackpot slot maxwin yang sering untuk memberikan peluang besar kepada para pemain kami. Peluang Besar Menang Jackpot Slot Maxwin Peluang menang jackpot slot maxwin di OLXTOTO sangatlah besar. Anda tidak perlu khawatir tentang batasan atau pembatasan dalam meraih jackpot tersebut. Kami ingin memberikan kesempatan kepada semua pemain kami untuk merasakan sensasi menang dalam jumlah yang luar biasa. Jackpot slot maxwin kami dibuka untuk semua pemain judi slot di OLXTOTO. Anda memiliki peluang yang sama dengan pemain lainnya untuk memenangkan hadiah jackpot yang besar. Kami percaya bahwa semua orang memiliki kesempatan untuk meraih keberuntungan besar, dan itulah mengapa kami menyediakan jackpot slot maxwin yang sering untuk memenuhi harapan dan keinginan Anda.   Kesimpulan OLXTOTO adalah situs slot gacor terbaik yang memberikan pengalaman bermain judi slot online yang tak terlupakan. Dengan variasi slot online terlengkap dan peluang memenangkan jackpot slot maxwin yang sering, OLXTOTO menjadi pilihan terbaik bagi para pemain yang mencari kesenangan dan kemenangan besar dalam perjudian online. Di samping itu, OLXTOTO juga menawarkan layanan pelanggan yang ramah dan responsif, siap membantu setiap pemain dalam mengatasi masalah teknis atau pertanyaan seputar perjudian online. Kami menjaga integritas game dan memberikan lingkungan bermain yang adil serta menjalankan kebijakan perlindungan pelanggan yang cermat. Bergabunglah dengan OLXTOTO sekarang dan nikmati pengalaman bermain slot online yang luar biasa. Jadilah bagian dari komunitas perjudian yang mengagumkan ini dan raih kesempatan untuk meraih kemenangan besar. Dapatkan akses mudah dan praktis ke situs OLXTOTO dan rasakan sensasi bermain judi slot yang tak terlupakan.  
    • OLXTOTO: Platform Maxwin dan Gacor Terbesar Sepanjang Masa Di dunia perjudian online yang begitu kompetitif, mencari platform yang dapat memberikan kemenangan maksimal (Maxwin) dan hasil terbaik (Gacor) adalah prioritas bagi para penjudi yang cerdas. Dalam upaya ini, OLXTOTO telah muncul sebagai pemain kunci yang mengubah lanskap perjudian online dengan menawarkan pengalaman tanpa tandingan.     Sejak diluncurkan, OLXTOTO telah menjadi sorotan industri perjudian online. Dikenal sebagai "Platform Maxwin dan Gacor Terbesar Sepanjang Masa", OLXTOTO telah menarik perhatian pemain dari seluruh dunia dengan reputasinya yang solid dan kinerja yang luar biasa. Salah satu fitur utama yang membedakan OLXTOTO dari pesaingnya adalah komitmen mereka untuk memberikan pengalaman berjudi yang unik dan memuaskan. Dengan koleksi game yang luas dan beragam, termasuk togel, slot online, live casino, dan banyak lagi, OLXTOTO menawarkan sesuatu untuk semua orang. Dibangun dengan teknologi terkini dan didukung oleh tim ahli yang berdedikasi, platform ini memastikan bahwa setiap pengalaman berjudi di OLXTOTO tidak hanya menghibur, tetapi juga menguntungkan. Namun, keunggulan OLXTOTO tidak hanya terletak pada permainan yang mereka tawarkan. Mereka juga terkenal karena keamanan dan keadilan yang mereka berikan kepada para pemain mereka. Dengan sistem keamanan tingkat tinggi dan audit rutin yang dilakukan oleh otoritas regulasi independen, para pemain dapat yakin bahwa setiap putaran permainan di OLXTOTO adalah adil dan transparan. Tidak hanya itu, OLXTOTO juga dikenal karena layanan pelanggan yang luar biasa. Dengan tim dukungan yang ramah dan responsif, para pemain dapat yakin bahwa setiap pertanyaan atau masalah mereka akan ditangani dengan cepat dan efisien. Dengan semua fitur dan keunggulan yang ditawarkannya, tidak mengherankan bahwa OLXTOTO telah menjadi platform pilihan bagi para penjudi online yang mencari kemenangan maksimal dan hasil terbaik. Jadi, jika Anda ingin bergabung dengan jutaan pemain yang telah merasakan keajaiban OLXTOTO, jangan ragu untuk mendaftar dan mulai bermain hari ini!  
    • OLXTOTO adalah bandar slot yang terkenal dan terpercaya di Indonesia. Mereka menawarkan berbagai jenis permainan slot yang menarik dan menghibur. Dengan tampilan yang menarik dan grafis yang berkualitas tinggi, pemain akan merasa seperti berada di kasino sungguhan. OLXTOTO juga menyediakan layanan pelanggan yang ramah dan responsif, siap membantu pemain dengan segala pertanyaan atau masalah yang mereka hadapi. Daftar =  https://surkale.me/Olxtotodotcom1
  • Topics

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.