Everything posted by Draco18s
-
[Forge 1.8.9] Alternative to thread.sleep?
That seems really complicated, is there any simpler way? I've seen stuff about scheduled executor delays? There is no "simpler" way.
-
My capabilities REFUSE to work. 5 devs checked it and all failed to find a clue.
And that is why I think passing off the init events to the proxy is stupid.
-
[1.10.2] Blockstates
Metadata is blockstate. It's just the internal representation of the blockstate (for some values). If you want to have a texture change based on an integer, you need an integer blockstate property.
-
[1.8.9] Creating a txt file, and accessing with a command.
Oh jesus christ. You can't just do this: public static String absolutePath = preevent.getSourceFile().getAbsolutePath(); Also, "preevent" doesn't even exist in your event methods. public static String absolutePath; public void preInit(FMLPreInitializationEvent event) { absolutePath = event.getSourceFile().getAbsolutePath(); } Go learn Java.
-
Applying a potion effect through armor?
And now you know that to Override a method you should always let your IDE do it or find the method you want to override and copy it, and then never touch its signature.
-
[1.8.9] Creating a txt file, and accessing with a command.
"preevent cannot be resolved" This error without any code is meaningless.
-
Applying a potion effect through armor?
Go to ItemArmor and find the onArmorTick method, copy its signature, paste it over your method.
-
[SOLVED] GUI Graphics
Or you could count pixels. The 0,0 point is the upper left corner.
-
Custom shears not working 1.10.2
Enchantments should works fine, it's the "shear sheep" bit I expect to break. If not that, then harvesting leaves.
-
[1.10.2] Animated model not updating in first person. (possibly bug)
That's why you use ItemStack.areStacksEqual. Because it gives no shits about instances. However, it DOES check NBT tags, which if those are different it's going to say the items are different. You're going to have to replicatethe functionality to check what you want it to check and ignore what you want it to ignore.
-
[Solved] [1.10.2] Can't color custom armor with ItemArmor#getColor
Unrelated, don't use "§4" use the EnumChatFormatting constants.
-
[1.10.2] Animated model not updating in first person. (possibly bug)
You need to use ItemStack.areStackEqual
-
[1.10.2] Making a render pass be full-bright
Yes it does. It goes inside "elements":{}
-
[1.10.2] Making a render pass be full-bright
You can still specify a model. "model": "item/generated"
-
[1.9] Connected models
Your files are safe, the project is a gradle project. All you need to do is change the version of Forge in your gradle file and rerun the gradle commands.
-
[1.10.2]Failure to recompile mc
Yes. And it's not:
-
[1.9] Connected models
I'm not sure how much changes, but 1.9.4 is the "definitive" version of 1.9 from Mojang, so there's no reason to develop on an old version. 1.9.4 mods are 99.99% compatible with 1.10.2 as well (and vice versa) so you may even wish to use a more recent Forge version (2011 or 2065 (recommended/latest)).
-
[1.9] Connected models
1) Update, you should be using 1.9.4 at the very least. 2) http://mcforge.readthedocs.io/en/latest/blockstates/forgeBlockstates/#sub-models
-
[1.10.2]Failure to recompile mc
Perhaps JAVA_HOME does not point to the JDK.
-
Get direction to Entity
Step 1: assume the player is at 0,0,0 Step 2: trigonometry
-
custom bars not modeled like web issue
Look at the model for IronBars
-
[1.9] Render custom item
Stuff like this is going away in Java 9. That's probably a good thing, but it still amuses me. This is my most favorite question, I think: http://codegolf.stackexchange.com/questions/61115/make-your-language-unusable The Java solution "redirects stdin and stdout to null streams and replaces args with an empty array. Also uses enormous amounts of reflection hacks to make sure the standard IO is truly hidden. Finally, it sets a security manager to make sure the standard IO can't be recreated and that makes sure programs can't set the exit code."
-
JSON Modles
JSON models cannot have non-cuboid shapes. If you want curved faces (which are a lie anyway) you need to use OBJ.
-
how to ask for stone variant? [solved]
Don't ever invoke metadata directly. If you want to make a block have the same blockstate at another position... IBlockState thatState = world.getBlockState(thatPos); world.setBlockState(thisPos, thatState, 3); Your problem is that you invoked getBaseState() which overwrote whatever state was already in the world with a default state.
-
Helper APIs
TL;DR: No one is going to provide you with copy/paste code solutions. I will provide my client proxy class that I'm using as it wraps several Forge class down into 1 so that it looks more like the 1.7.10 method (create item, call proxy.register for it) of registering items/blocks rather than four duplicated lines for every single one (create item, set registry name, set unlocalized name, call GameRegistry.register for it, call proxy.registerRenderer). https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/ores/client/ClientProxy.java
IPS spam blocked by CleanTalk.