-
Posts
106 -
Joined
-
Last visited
Everything posted by KidKoderMod033109
-
[1.15] Save data to world using WorldSavedData
KidKoderMod033109 replied to KidKoderMod033109's topic in Modder Support
I mean't create a new "config file" in the world folder, then can be read back. imacatlol said: Can't you? I believe the SERVER config type will do exactly what is desired, unless the javadocs are misleading me. @imacatlololHow do I do that? -
[1.15] Save data to world using WorldSavedData
KidKoderMod033109 replied to KidKoderMod033109's topic in Modder Support
The whole mod is based upon the logic and requires the logic to be in that class. But, I have thought to create a "config" file for each world, would that work/how would I do that? -
[1.15] Save data to world using WorldSavedData
KidKoderMod033109 replied to KidKoderMod033109's topic in Modder Support
I have a class that has the logic to decide what does into the ArrayList, and I want to save that ArrayList to data in the world, Then, when the World is loaded again, to read the data and use it. I am using WorldSavedData because it seemed like it would work. If you know any other way to do this, please tell me(Please avoid from file stuff such as creating a file for each world). -
Hi, I'm looking to save ArrayLists, in the WorldSavedData class. I already have the following: How do I save an ArrayList in to the class in a diffrent class, then retrive it when I need it? Thanks in advance, Kid Koder
-
@imacatlolol I changed my code to this: package net.kidkoder.allergies.effect; import net.minecraft.entity.LivingEntity; import net.minecraft.potion.Effect; import net.minecraft.potion.EffectType; public class EffectAllergicReaction extends Effect { public EffectAllergicReaction() { super(EffectType.HARMFUL, 255); setRegistryName("allergic_reaction"); } @Override public boolean isReady(int duration, int amplifier) { return true; } @Override public void performEffect(LivingEntity entity, int amplifier) { entity.setHealth(1); super.performEffect(entity, amplifier); } } And I got the same error. But, I also found this error: [15:36:55] [Server-Worker-15/WARN] [mojang/YggdrasilMinecraftSessionService]: Couldn't look up profile properties for com.mojang.authlib.GameProfile@60a58148[id=380df991-f603-344c-a090-369bad2a924a,name=Dev,properties={},legacy=false] com.mojang.authlib.exceptions.AuthenticationException: The client has sent too many requests within a certain amount of time at com.mojang.authlib.yggdrasil.YggdrasilAuthenticationService.makeRequest(YggdrasilAuthenticationService.java:79) ~[authlib-1.5.25.jar:?] {} at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService.fillGameProfile(YggdrasilMinecraftSessionService.java:180) ~[authlib-1.5.25.jar:?] {} at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService$1.load(YggdrasilMinecraftSessionService.java:60) ~[authlib-1.5.25.jar:?] {} at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService$1.load(YggdrasilMinecraftSessionService.java:57) ~[authlib-1.5.25.jar:?] {} at com.google.common.cache.LocalCache$LoadingValueReference.loadFuture(LocalCache.java:3716) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache$Segment.loadSync(LocalCache.java:2424) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache$Segment.lockedGetOrLoad(LocalCache.java:2298) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache$Segment.get(LocalCache.java:2211) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache.get(LocalCache.java:4154) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache.getOrLoad(LocalCache.java:4158) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache$LocalLoadingCache.get(LocalCache.java:5147) ~[guava-21.0.jar:?] {} at com.google.common.cache.LocalCache$LocalLoadingCache.getUnchecked(LocalCache.java:5153) ~[guava-21.0.jar:?] {} at com.mojang.authlib.yggdrasil.YggdrasilMinecraftSessionService.fillProfileProperties(YggdrasilMinecraftSessionService.java:170) ~[authlib-1.5.25.jar:?] {} at net.minecraft.client.Minecraft.getProfileProperties(Minecraft.java:1898) ~[?:?] {re:classloading,pl:accesstransformer:B,pl:runtimedistcleaner:A} at net.minecraft.client.resources.SkinManager.lambda$loadProfileTextures$4(SkinManager.java:90) ~[?:?] {re:classloading,pl:runtimedistcleaner:A} at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(ForkJoinTask.java:1402) [?:1.8.0_181] {} at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289) [?:1.8.0_181] {} at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056) [?:1.8.0_181] {} at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692) [?:1.8.0_181] {} at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:157) [?:1.8.0_181] {}
-
Hi, I was working on my mod, and then when I test runned, I got this error message, [20:46:15] [Render thread/ERROR] [ne.mi.fm.ne.si.IndexedMessageCodec/SIMPLENET]: Received empty payload on channel fml:handshake I don't know what caused it, but it seems that anything Entity based will not work(besides player movment). Blocks also con be placed. Thanks in advance, Kid Koder
-
Hi, I was wandering how to get the player's username as String using the PlayerEntity class. I have so far done String name = player.getName().toString(); but I just go a bunch of what I think was JSON. Thanks in advance, Kid Koder
-
Hi, In my mod, my blocks are not registering. I have tried about 100 times and nothing worked, not even the /give command. Here is my code: @Mod.EventBusSubscriber() public class Register { @SubscribeEvent public static void registerBlock(final RegistryEvent.Register<Block> event) { event.getRegistry().registerAll( BlockList.SLIME_BALL_FARM = new BlockSlimeBallFarm(Block.Properties.create(Material.IRON)).setRegistryName("slime_ball_farm") ); } @SubscribeEvent public static void registerItem(final RegistryEvent.Register<Item> event) { event.getRegistry().registerAll( BlockList.SLIME_BALL_FARM_ITEM = new BlockItem(BlockList.SLIME_BALL_FARM, new Item.Properties().group(ItemGroup.BUILDING_BLOCKS).maxStackSize(1)).setRegistryName("slime_ball_farm") ); } }
-
Good point.
-
Some I want users to be able to change and some not
-
Hi, I'm new to modding and need help making keybindings for my mods. I know there is a KeyBinding Class, but I can nor figure it out. PS. Is it possible to not show the keybinding in "controls"