Everything posted by Draco18s
-
[SOLVED][1.8.9] Crop not dropping seeds?
The last two lines in the ModItems and ModBlocks are important here. We need to know what order those are called in. Because you have them as part of the static class initialization, rather than as a method, we cannot know what order they are called in nor can we change that order. Secondly, you do this: ItemPPSeed tomatoseed = new(ModBlocks.tomatocrop); BlockPPCrop tomatocrop = new(ModItems.tomatoseed); Each of those lines is referencing the other ONE OF THEM WILL BE NULL! So you're storing null in a private field. There's a much better way of doing this. protected Item getSeed() { return ModItems.tomatoseed; //magic }
-
Is there a list of overridable functions on the Block class?
Yes! In Eclipse, hover over the class declaration of Block and then click the little green button in the tooltip that pops up (aka "Jump to Definition") Magic! Or you can do: Block b; b. And another tooltip will pop up called the intellisense autocomplete which will list every god damn method and property available for that object. Events, by the way, are not functions. They're events and you need to write an Event Handler to handle them (which is a class containing methods). Search Google for "Forge Events" and the first link will be a link to the wiki called "Forge Event Reference."
-
exporting mod .. having some problems.
...Minecraft Development Kit
-
[1.8.9] Overriding Vanilla Block Properties
Hand doesn't have a harvest level. There's simply a check to see if the player is allowed to harvest a material without needing a tool. If so, the block is always harvested, regardless of how the player broke it (hand, wrong tool, correct tool, or with a random item), and is harvested with a x5 speed bonus (this is why it takes so long to break stone by hand, even though Stone and Wood have the same hardness). Setting the harvest level to 0 (or higher) is for the tool-speed-multiplier lookup. This is why digging with a wooden shovel is faster than by hand but not by much: dirt can already be harvested by hand and already benefits from the "can harvest: x5 speed" bonus, whereas using a wooden shovel adds another x2 (taking it from 0.9 seconds to 0.45 per block).
-
[1.8.9] Overriding Vanilla Block Properties
Do note that a harvest level of 0 (wood tools) is not sufficient to prevent blocks from being dropped when mined by hand.
-
[1.7.10] Right Click Event..
There are a few concepts that aren't making it across the translation barrier. The first has to do with programming in general (not that I think that jmylifecolor doesn't know java or how to program, but rather that the terminology itself may not be translating correctly). The second has to deal with event handlers, which are a little arcane if you haven't used them before.
-
[1.7.10] Right Click Event..
someVariable.class ?
-
How do I slow down a velocity jump?
Please go into your airplane and flip the red lever.
-
[1.7.10]Dedicated server error
Well, some of us don't have time to read your mind. It's a lot of work.
-
How do I slow down a velocity jump?
...really?
-
[1.8.9] [Forge 1722] Custom ore not generating
0) use github 1) yoir json is malformed
-
[1.7.10]Dedicated server error
I so not need your code because I am psychic. Your widget is missing a thingamajig and it's vomiting all over the processor. (Hint: always post code, especially the class mentioned in the crash, ScreenCompressor)
-
custom block that prevents spawning of mobs in a certain perimeter
So if light is 0 to 15, and 1.0f corresponds to 15 and it bit-overflows, what happens is we double that?
-
[1.7.10] Cannot delete item from player.inventory
Are you doing it client side or server side?
-
[1.8] Why does my block have 2 tile entities?
In fact, returning null is a bad idea.
-
[Resolved | 1.8.9] How to check if an itemstack in a slot is a certain item.
What happens when the player does not have an item in that slot?
-
[1.8] Why does my block have 2 tile entities?
The log knows all. One on the client, one on the server. SSP does still have both.
-
custom block that prevents spawning of mobs in a certain perimeter
Ooh, you want it to LOOK like it is fully lit without actually emitting light. That's trickier, but involves rendering the block yourself.
-
How do I slow down a velocity jump?
Null error exceptions are ready to fix. He even told you what object is null.
-
[1.7.10] How do I draw 2 textures on the same face of a block
M-m-m-multipass rendering!
-
[1.8.9] Changes.
So where can I read about those types? I am GL noob in terms of conventions. Everything I know i learned from scratch (a lot actually). Look for some GL tutorials. If you hover over GL11.GL_QUADS you can do a jump-to-definition which will take you to the GL11 class and you can look at the other modes there (I can't find a list online). QUADS is more or less deprecated because it's inefficient, but no one in Minecraft modding cares (it's faster to draw two triangles than making the CPU calculate said triangles). The other options I can remember are... LINES (may not work, use instead...), LINE_STRIP, and TRIANGLE_STRIP.
-
[1.8.9] Re: Arrays of Blocks, Items, etc
Save the config to a static variable in your main class. Access it from anywhere.
-
[1.8.9] Changes.
I know that one of the parameters for WorldRenderer is the GL draw type. GL11.GL_QUADS, etc.
-
[1.8.9] Fluids don't render. Did the system change?
Lighter than air fluids are hilarious~ (I've got one, but its also finite and flammable. We've had so much fun with it.)
-
custom block that prevents spawning of mobs in a certain perimeter
Even SSP there are still multiple dimensions loaded (the game automagically generates and holds a portion of the Nether active if you have a Nether portal).
IPS spam blocked by CleanTalk.