I've found the source of the issue: You were instantiating WorldGenMegaCocoa with true as the first argument, causing it to notify adjacent blocks whenever it generated a block. Vanilla trees always disable this during world gen and only enable it for sapling growth.
I realised that I gave you the wrong .gitignore earlier, it was missing some ignores for Eclipse projects. The one I linked was from my own mod, which I only develop in IDEA. This is the one I meant to link.
I've opened a pull request on GitHub with the fix for the crash and the proper .gitignore. I had to auto-format your code to make it readable, so pretty much every file was changed. If you don't want to merge the auto-formatting changes, you can close the pull request and manually make the change that fixes the crash.
If you add the new .gitignore yourself, you'll want to delete the ignored files from the repository. You can do this by opening the Git shell from GitHub for Windows (Gear Icon > Open in Git Shell with your repository selected) and then running the commands in this StackOverflow answer.
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
BiomeDecoratorChocolate never uses most of its plant generator fields
You've copied and pasted the BIomeDecorator#decorate method without changing it to reference your fields
Either assign your custom plant generators to the existing fields or change the decorate method to use your fields
BlockChocoGrass doesn't override canSustainPlant properly, so your plants won't be generated on your grass
You just need to return plantType == EnumPlantType.Plains from this method, no need to check what this is like the base method does (that's just there for vanilla compatibility)
Rollback Post to RevisionRollBack
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
I think i get what your saying about the ChocoGrass. so i changed it to this:
public boolean canSustainPlant(World world, int x, int y, int z, IPlantable plantable){
EnumPlantType plantType = plantable.getPlantType(world, x, y + 1, z);
plantType = EnumPlantType.Plains;
return true;
}
although it doesnt want to be overriden. so im guessing im still doing something wrong.
As for the decorator your telling me to either assign my custom plant generators to the existing feilds or change the decorate method to use my fields. although im not sure what you mean you mean by that, or what a field is. (this is my first time trying to make plants and a dimension and whatnot)
I think i get what your saying about the ChocoGrass. so i changed it to this:
public boolean canSustainPlant(World world, int x, int y, int z, IPlantable plantable){
EnumPlantType plantType = plantable.getPlantType(world, x, y + 1, z);
plantType = EnumPlantType.Plains;
return true;
}
although it doesnt want to be overriden. so im guessing im still doing something wrong.
As for the decorator your telling me to either assign my custom plant generators to the existing feilds or change the decorate method to use my fields. although im not sure what you mean you mean by that, or what a field is. (this is my first time trying to make plants and a dimension and whatnot)
Open the Block class in your IDE, navigate to the canSustainPlant method and look at its signature (return type, name, number and type of parameters). That is not its signature.
If Eclipse lets you auto-override a method, use that to generate the method stub and then add the logic to it.
If you don't know what a field is, you need to learn Java. This tutorial briefly explains classes and this tutorial briefly explains method overriding.
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
Open the Block class in your IDE, navigate to the canSustainPlant method and look at its signature (return type, name, number and type of parameters). That is not its signature.
If Eclipse lets you auto-override a method, use that to generate the method stub and then add the logic to it.
If you don't know what a field is, you need to learn Java. This tutorial briefly explains classes and this tutorial briefly explains method overriding.
I want to learn Java, but none of the teachers in my highschool know it, So for now im trying to teach myself and learn as a go until i go to college and hopefully learn it there. and the links dont work, i think oracle might be down though.
Question : do you create a newworld when u make changes to the generation code ? this can cause errors, i hvae looked at your code and it runs, the trees look like MC tress though ?
No, i do not create a new world, i explore the existing one. and when I first made the trees (over a year ago) I didnt know how to make them and tried following a tutorial (they didnt work) so i used minecraft's trees instead. Now i know how to make a custom tree and i could probably do it, but Chocolate Trees dont exist and im not sure what they would even look like if they did (theyre trees made out of chocolate) so i just decided to keep them they way they are.
i mean you have veriables named plantYellowGen1, plantYellowGen2 etc, change them to your flowers to make it eaiser to read
Yea, im not sure what i was thinking a year ago, but my code was very messy. It made me realize that i should probably clean up some of the variable names.
also after a little playing around i have made the biomes in you r dimension spawn floweers, grass etc, just need them to use your grass ansd flowers etc
Flowers are already in the code, custom grass im still working on, im trying to get it to stop dropping seeds, maybe have it drop cocoa powder instead.
BlockChocoGrass : in this class you dont Override the canSustainPlant method, if u overrdie it and set it true grass and flowers will spawn.
Your Biome Decorator should have the veriables chnaged to make coding better and eaiser to understand.
Your Flowers Should extend BlockFlower not BlockBush.
i will play around later to get the flowers to spawn and let yoiu know what i find, at the moment all your trees spawn, MC tall grass and flowers spawn and ur mushrooms spawn aswell, hope shortley should have the flowers spawning aswell
Im still not the best at coding java, I can understand it a little bit and know what im doing now but compare to many many other people who make mods or tutorials, im still a novice compared to them. I have changed the variables and have my custom flowers extend the BlockFlower. And it seems like making all of my messed up code is easy for you, i wish i had that kind of skill, but im still trying my best to learn java.
Im not sure if i want to see the code that you played around with. on one hand i'll finally be able to finish updating my mod to 1.7.10. but on the other hand im not sure if i would learn anything from that. But if i try to learn it myself it could take a long time before i get the same results....
Ive finally gotten canSustainPlant working and now grass and flowers spawn in my dimension. the only problem is that its mojang's flowers, not my custom flowers. although on the bright side my custom grass works
I've found the source of the issue: You were instantiating WorldGenMegaCocoa with true as the first argument, causing it to notify adjacent blocks whenever it generated a block. Vanilla trees always disable this during world gen and only enable it for sapling growth.
I realised that I gave you the wrong .gitignore earlier, it was missing some ignores for Eclipse projects. The one I linked was from my own mod, which I only develop in IDEA. This is the one I meant to link.
I've opened a pull request on GitHub with the fix for the crash and the proper .gitignore. I had to auto-format your code to make it readable, so pretty much every file was changed. If you don't want to merge the auto-formatting changes, you can close the pull request and manually make the change that fixes the crash.
If you add the new .gitignore yourself, you'll want to delete the ignored files from the repository. You can do this by opening the Git shell from GitHub for Windows (Gear Icon > Open in Git Shell with your repository selected) and then running the commands in this StackOverflow answer.
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
ohhh, so thats what that boolean does. xD I never realized that i had set it to true. thanks for fixing it for me.
although im still not sure how to get my custom flower to spawn on my custom block. I know that im able to place it on the custom block though.
You have two main issues here:
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
I think i get what your saying about the ChocoGrass. so i changed it to this:
public boolean canSustainPlant(World world, int x, int y, int z, IPlantable plantable){
EnumPlantType plantType = plantable.getPlantType(world, x, y + 1, z);
plantType = EnumPlantType.Plains;
return true;
}
although it doesnt want to be overriden. so im guessing im still doing something wrong.
As for the decorator your telling me to either assign my custom plant generators to the existing feilds or change the decorate method to use my fields. although im not sure what you mean you mean by that, or what a field is. (this is my first time trying to make plants and a dimension and whatnot)
Open the Block class in your IDE, navigate to the canSustainPlant method and look at its signature (return type, name, number and type of parameters). That is not its signature.
If Eclipse lets you auto-override a method, use that to generate the method stub and then add the logic to it.
If you don't know what a field is, you need to learn Java. This tutorial briefly explains classes and this tutorial briefly explains method overriding.
Chisel Facades: For all your decorative pipe-hiding needs.
Please don't PM me to ask for help or to join your mod development team. Asking your question in a public thread preserves it for people who are having the same problem in the future. I'm not interested in developing mods with people.
I want to learn Java, but none of the teachers in my highschool know it, So for now im trying to teach myself and learn as a go until i go to college and hopefully learn it there. and the links dont work, i think oracle might be down though.
No, i do not create a new world, i explore the existing one. and when I first made the trees (over a year ago) I didnt know how to make them and tried following a tutorial (they didnt work) so i used minecraft's trees instead. Now i know how to make a custom tree and i could probably do it, but Chocolate Trees dont exist and im not sure what they would even look like if they did (theyre trees made out of chocolate) so i just decided to keep them they way they are.
Yea, im not sure what i was thinking a year ago, but my code was very messy. It made me realize that i should probably clean up some of the variable names.
Flowers are already in the code, custom grass im still working on, im trying to get it to stop dropping seeds, maybe have it drop cocoa powder instead.
Im still not the best at coding java, I can understand it a little bit and know what im doing now but compare to many many other people who make mods or tutorials, im still a novice compared to them. I have changed the variables and have my custom flowers extend the BlockFlower. And it seems like making all of my messed up code is easy for you, i wish i had that kind of skill, but im still trying my best to learn java.
Im not sure if i want to see the code that you played around with. on one hand i'll finally be able to finish updating my mod to 1.7.10. but on the other hand im not sure if i would learn anything from that. But if i try to learn it myself it could take a long time before i get the same results....
Hey, jimmy04creeper. Do think you could post or send me the code that you got to work? I still can't figure it out.
Ive finally gotten canSustainPlant working and now grass and flowers spawn in my dimension. the only problem is that its mojang's flowers, not my custom flowers. although on the bright side my custom grass works