Everything posted by Draco18s
-
MC 1.10+ How to set different hardness for different block type
Something something, this is why I have to try-catch a chunk of my code, because I specifically want to know what the hardness of a block (and its harvest tool/level) is without having a valid world position to look at (so I pass null for the world and catch the null pointer exception).
-
[1.10.2] Changing Item compound tag removes damage?
How are you damaging the item?
-
[SOLVED] GUI not working
Probably the while loops. Like, their entire existence.
-
[1.10.2] Alter beacon behavior when base is certain material
No that's-- User was banned for coremodding
-
[1.10.2] Assigning data to a chunk?
TL;DR: Chunk data needs to exist in its own native class object during runtime. You only need to save to NBT when the chunk is saved (and then read it when its loaded again). You'll need these events: https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/flowers/FlowerEventHandler.java#L74 (CogOreGenEvent is just a deferred chunk generation event that I must use; you can use the vanilla chunk generation events) And this is what I do with them: https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/flowers/util/OreDataHooks.java There's a lot going on for me (because my data is complex) but the basics is that when the chunk is generated I create some data that gets stored. There's a "get" method for retrieving the stored value as well. Then during ChunkSave the data is added to the chunk's nbt, and on ChunkLoad it's read. At ChunkUnload the data is removed from the runtime storage (so memory isn't leaked by a player flying through the world).
-
[Solved] [1.10.2] Making sword deal extra damage to certain mobs
An "is this my sword?" check is super cheap. Don't even worry about it.
-
Dynamically change inventories size of a chest.
Ok, then you're going to have to initialize your own Item handler. It's not hard. https://github.com/Draco18s/ReasonableRealism/blob/master/src/main/java/com/draco18s/ores/entities/TileEntitySifter.java#L40
-
Dynamically change inventories size of a chest.
In the constructor, yes.
-
Dynamically change inventories size of a chest.
Then you're probably going to have to initialize the item handler capability's size to the maximum you're ever going to need.
-
Dynamically change inventories size of a chest.
That entirely depends on what you're doing and how you're doing it. Did the array that holds all the times increase in size?
-
forge 1.10+ creating slabs and stairs
Unable to resolve texture reference is that there is an unspecified texture in the model/blockstate.
-
Dynamically change inventories size of a chest.
if(slot < getSizeInventory()) ?
-
[1.10.2] Water (Liquid) Block Model?
Oh sweet. That's exactly what I needed. Hell, I'd have been sufficed with ModelLoaderRegistry.getModel( location ); and been left to figure the rest out. THAT is the class I could not find out about. Naw, we good. Oak planks.
-
[Solved] [1.10.2] Making sword deal extra damage to certain mobs
I think the point is that hitEntity is called even while the cooldown is active. So you get full bonus damage even if the sword itself is dealing 0.1 damage.
-
Dynamically change inventories size of a chest.
You have to make sure that the requested slot is writing the inventory size before you call super.
-
Where can i find "Funtions like: func_130014_f_ etc... "
http://export.mcpbot.bspk.rs/
-
[1.8.9] How to change a Block's texture to that of another Block on the fly?
Not having done this, my guess is that you would have to create your own IBakedModel implementation that gets the quads from another baked model. In any case it is likely not going to be easy.
-
[1.10.2] Water (Liquid) Block Model?
Mucho gracias. https://s17.postimg.org/5c7zad6lb/2016_10_09_18_03_42.png[/img] Need to create a bottom model now (the carpet is placeholder; just wanted something about the right height that already existed). Last question: How to I register a model that isn't associated with a block?
-
[1.10.2] Water (Liquid) Block Model?
Ok, back to this. Questions: 1) Am I registering the block with a model as normal, then that model gets loaded and baked, then retrieve it? 2) How do I tell the model registry to use my new baked model? I took a look at your repo, but I couldn't find where you actually do this stuff (I found your @SubscribeEvent handler, but it made calls off to arbitrary objects via an API, so I couldn't follow what it did).
-
[1.9.4]Registration JSON model
1) Why aren't you using the registry name? 2) What is the value of "file"? 3) What is the block's registry name?
-
How to create a forge .json file for meta items
Yes, I have one there, it works fine. https://github.com/Draco18s/ReasonableRealism/tree/master/src/main/resources/assets/harderores/models/block/item { "__comment": "Allows blockstates files to use basic item models", "parent": "minecraft:item/generated" }
-
[1.10.2] RightClickBlock event ocurring twice.
The event fires once for each hand.
-
How to create a forge .json file for meta items
Blockstate folder Take a look through my git repo https://github.com/Draco18s/ReasonableRealism Might want to go back to the Jul 28, 2016 commit, there's less stuff in there at that point.
-
How to create a forge .json file for meta items
{ "forge_marker": 1, "defaults": { "model": "harderores:item/generated" }, "variants": { "ore_type": { "iron": {"textures": {"layer0": "harderores:items/irondust_sm"} }, "gold": {"textures": {"layer0": "harderores:items/golddust_sm"} }, "flour": {"textures": {"layer0": "harderores:items/flourdust_sm"} }, "sugar": {"textures": {"layer0": "harderores:items/sugardust_sm"} }, "tin": {"textures": {"layer0": "harderores:items/tindust_sm"} }, "copper": {"textures": {"layer0": "harderores:items/copperdust_sm"} }, "lead": {"textures": {"layer0": "harderores:items/leaddust_sm"} }, "silver": {"textures": {"layer0": "harderores:items/silverdust_sm"} }, "nickel": {"textures": {"layer0": "harderores:items/nickeldust_sm"} }, "aluminum": {"textures": {"layer0": "harderores:items/aluminumdust_sm"} }, "osmium": {"textures": {"layer0": "harderores:items/osmiumdust_sm"} } } } } And you're not limited to 16, either. "Osmium" there is meta-data value 24.
-
[1.10.2] Water (Liquid) Block Model?
Noted for later. Struggling through getting the liquid portion to do what I want (slowly, oh so slowly). At the moment 3 facings work correctly, south doesn't. Nevermind, I had "sorth" in my blockstate file. I'm an idiot. Next step is to get the water level working at the desired heights. @..@
IPS spam blocked by CleanTalk.