Everything posted by Draco18s
-
[1.8]Make booleans stay after quitting Minecraft
Congradulations, you did nothing with your boolean. You got the current value from the save file, then wrote it back. Good jorb.
-
[1.11] Rendering an Textured Overlay
I don't see anything obvious, but it's been a while since I tried to render any GUI stuff.
-
[1.11] Rendering an Textured Overlay
Why do people keep checking event.isCancelable() ? That's only ever going to return true or false based on the event class and won't ever change. Are you mistaking it for event.isCanceled() ?
-
(Solved)1.11 Item not rendering texture
No, its because Windows is lying to you. Change the name to "asdfasdf.json" and then back to "testitem.json" and resync with Github.
-
[1.11] Spawning Items When Block Is Broken
Assign it to a variable and print it out or use the debugger to figure out what value is coming out of it every time. Odds are you've messed up initializing your random object.
-
[1.11] Spawning Items When Block Is Broken
By "not even the cobble" you mean that you're not getting two cobble stone (the statement outside the if(rand) statement)?
-
[1.11] Spawning Items When Block Is Broken
for(ItemStack stack : event.getDrops()) { //loop over everyting if(stack.getItem() == Item.getItemFromBlock(Blocks.COBBLESTONE)) { //check if each item is cobblestone } }
-
[1.11] Spawning Items When Block Is Broken
You can't use contains in this context. ItemStack does not override equals so it will never find a match.
-
[1.11] Compass with NBT tags to store where it points is getting reset
setCompassSpawn is only called from the client side. You're then saving the NBT client side. When you open the inventory you're requesting the server's copy, which does not contain the NBT. Something something this is why you were using packets before.
-
[1.11] Spawning Items When Block Is Broken
event.getDrops().add(...) Seriously, look at the event object and see what's there.
-
[Unsolved] UnlocalizedName, RegistryName, and ItemArmor
Option 1: pass the string to the class constructor, for example, this. Option 2: call setUnlocalizedName and setRegistryName on the item after it's constructed, for example, this. Both of those are 1.7 (my 1.10 code is set up differently) but give you an idea of what I mean. Btw, the crash reason is obvious: java.lang.IllegalArgumentException: The name tmm:escapemc_ingot has been registered twice
-
[1.10.2][SOLVED]Exception loading model [model] with loader Variant
Because you are trying to register a block that has variants and trying to register those variants for the item model, you can't construct your variant string that way ( "variant="+variant ). You need to get the statemapper property string. Something like this: StateMapperBase b = new DefaultStateMapper(); BlockStateContainer bsc = block.getBlockState(); ImmutableList<IBlockState> values = bsc.getValidStates(); for(IBlockState state : values) { String str = b.getPropertyString(state.getProperties()); registerBlockItemModelForMeta(block, block.getMetaFromState(state), str); } Additionally, your BlockPlainTable has two different properties. You can't just loop over one of those properties and create an item for it: the other property is still required. If you don't want that property to be included, then you need a custom IStateMapper implementation as well.
-
[SOLVED][1.10.2] Rendering Block's Animated Texture
Considering that's where he started....no, no he can't. Block and item textures are animated with vanilla internals (there's no mod-based code involved) and his attempts to latch onto that system hasn't resulted in a clean result.
-
[1.8]Make booleans stay after quitting Minecraft
1) What I gave you is borderline copy-paste-able. 2) Your main mod is still using config1.getBoolean not config1.get 3) If you want to CHANGE THE VALUE DURING THE GAME the code needs to go inside the BUTTON action.
-
[1.10.2][SOLVED]Exception loading model [model] with loader Variant
Do this: Because, as I said, there are multiple possible problems and I made the most informed suggestion that I could. I even explained why you see the error you do. But as I can't see your code, I'm taking shots in the dark.
-
Creating more Minecraft hooks
It should be noted that they are not accepting new features for 1.10 anymore, only 1.11
-
[SOLVED][1.10.2] Gui input handled multiple times
Or not remove the buttons from the screen and readd them all the time, and instead do it once, during initGui... https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/industry/client/gui/GuiContainerFilter.java#L48-L49
-
[1.10.2][SOLVED]Exception loading model [model] with loader Variant
Like I said: Caused by: java.io.FileNotFoundException: arpgf:models/item/BlockPlainTable.json Basically all missing variant problems will come with two (or more) errors. The first one is just "we failed to load a variant" followed by another error, which can be a missing model, a malformed json, or that the blockstate file actually didn't have the variant in it. And its possible for more than one of these to be thrown as well (for example, the item variant of a block will throw both the "missing variant in blockstate" error AND the "file not found" error because the game attempts to locate it in both places, if it finds one, no error is thrown, but if it finds neither, then both errors are thrown).
-
Method for finding client instance of server entity?
Jesus freaking christ, use a [nobbc]
-
json not working 1.10.2
[me=Draco18s]Looks at his own code[/me] No, no it does not.
-
[1.10.2][SOLVED]Exception loading model [model] with loader Variant
Post the WHOLE error. The first line about missing variants is a generic problem that's caused by one of several other errors, such as FileNotFound. Also, your blockstate.json does not contain an "inventory" variant, which would be used for--you guessed it--items.
-
[1.11] Detecting TEs that are not horizontal / vertical from the orginal
That entirely depends on what you're trying to do. Right now you're searching a 7x7x7 cube centered on this block. Facing values would search only the 6 directly adjacent blocks.
-
(1.11)(SOLVED)ItemBlock Models Acting Strangely
For situations like this, Minecraft should log an error loading the model/texture. Please provide that info.
-
[1.10.2] Model acting different depending on dimension
That's called z-fighting and that is not what is happening here.
-
Rotating A Block's Texture
Yes, but you can't rotate the texture based on block state. It's baked in.
IPS spam blocked by CleanTalk.