All right what’s going on guys and welcome back to another let’s make a forge mod episode 6 and today we are going to be going over or generation that’s right or generation not tools because i decided to do or generation before tools because you want to be able to get your Your resource um i guess you can say like naturally and not just like have to spawn it in and stuff and this will actually make your mod a little bit more playable uh so anyways uh the first thing you’re going to want to do is you are going to come down to your Game registry down here you’re going to do backslash backslash world generators world gen rogens and then underneath this you’re going to do game registry dot add world generator or no not add dot register world generator my bad and then uh new uh world generator and then go to ut for tutorial And there you go and put that on the end and you’re good now as you can see right here you don’t have this class now this class is going to have to be um is gonna have to be made so that’s all you have to do in your main class file Uh now you’re gonna come down here and you’re gonna scroll over this right here and you’re going to do create class world generator tut and then uh we’re just going to get rid of all this and start from scratch so the first thing you’re going to do is Package and then our package so rush you rg dot tutorial mod right there and then the next thing you’re going to do is your import so import java dot util dot random and then you’re gonna come again and you’re gonna do import net dot minecraft dot world dot world and then import Um oh it wasn’t working for a second net dot minecraft dot world dot chunk dot i chunk provider don’t ask what all these do i don’t know i just know you have to have them for imports i know that the world one actually imports all of your world gen features and you net Dot minecraft dot world dot gen dot feature dot world gen minable i think that’s it yes well gen minable world gen mine oh no e there we go world gen minerable and you’re going to come down here and you do public class world generator and then tut implements i world generate tour And then open brackets here you come down here and you’re also going to have to import your iworld generator and then you’re going to do an at override and then public void generate and then parenthesis random random this is going to be a lot of typing by the way guys so random random Initiate chunk x oh that’s trunk c chunk x and then int chunk chunk z and then world world comma whoops comma i chunk provider chunk generator and then i chunk provider and then chunk provider and you’re going to go out of the parentheses and you do an open bracket like so Go down and you have your closed bracket i’m gonna do switch and then world dot provider dot diamond chin id and then another open bracket and then um you’re gonna do case zero and then generate surface tons of typing i know generate surface and then world oh wait whoops world random chunk X 16 and then chunk z star 16 and you’re going to end on one of those okay and then yeah so that should work generate surface and then oh whoops so now we’re gonna have to come down here out of all of them except for This one so our main one is still intact and you do private void generate surface surface cool you’re gonna do world world oh whoops no comma world world and then you’re going to do random random a lot of typing i know int block x int block z and then open bracket And then four int i space equals 0 and then semicolon i and then a less than sign 10 another semicolon and then uh i and plus plus plus plus and then another open bracket and then and then you do int x chord equals block x plus random dot next int and then 16 And then int z chord and then equals block z plus random dot next int parentheses 16 semicolon and you do int y chord equals uh random dot next int 16 semicolon and then uh you do you come down here and you do in a parenthesis world gen oh new world gen Mine a bull and then world generator t-u-t oh wait no duh uh tutorial mod dot block oh i guess we need to make our block well it’s going to be block it’s going to be or ruby and then dot block id comma 4 dot generate world random and then Hold on let me just move this over i just don’t like these pre-made stub things they’re annoying and then world random x chord and then y chord and then z chord and then at the end of that and you’re done yeah done kid next oh this needs to be a capital i and There needs to be an i in there and then we are going to have to come here and we have to create our block so we’re going to do public final static block or ruby equals new or ruby and then 2002 material dot rock dot set hardness Um hold on one second so i’m actually going to pull up a hardness scale right here as you can see right here on the screen it shows all of the hardest hardeness so as you can see all the ores are three so we are going to follow in that pattern And make it 3.0 f and then right here we’re going to do dot set step sound and then block dot set sound that sound stone foot step dot set creative tab creative tabs dot tab blocks dot tab block and then once again we’re going to set our texture file that func uh Underscore 1 one one zero two two underscore d and then uh brushed u r g t u t and ruby or done okay now we are going to come here and create our ruby ore class finish and then we are going to go to our block.ruby and we’re just going to Copy everything and we’re going to paste and we’re going to rename to or ruby so there you go you’re just going to save and then we’re going back to our okay so all that is good now this is where you actually uh make it spawn so you’re gonna want to keep These 16 by 16 and then uh your why i think yeah um the y is actually how high up it spawns and this is how frequent it spawns so we’re going to make it spawn anywhere under 48. we’re going to save that and we’re going to run the game as soon as i Put the texture in well we can put it in while it’s loading up up so we go textures.blocks and we go here blocks and we’re going to do copy our ruby ore and paste it in there and we are going to actually have to restart our thing there we go Okay we’re loaded up and we’re gonna go to create new world and we’re going to creative world type default create new world all right so now we’re going to try and find ourselves a cave if we are lucky enough to find one or spawn by one as my game is lagging Terribly because of my frame limit on um oh here’s a little inlet on whatever it’s called and the first thing you should notice though is there should be a uh if i search it ruby oh i guess it’s not even in here yet so i guess i’m going to have to Fix or ruby blah blah blah oh because we didn’t do our game registries smart guy see this is why you never uh listen to me just kidding you should listen to me i’m pretty good at this stuff game registry dot register block uh or ruby and then uh or ruby okay cool cool Language registry dot add name and then or ruby and then ruby or and then minecraft forge dot set block harvest level and then block ruby and then pickaxe and then two once again and there we go what did i do wrong block ruby pickaxe right here needs another one of those okay cool Cool and save this oh whoops can’t use that there we go and save this and now it should be all in our game we’re gonna have to create a new world because our block was not actually registered so it could not have spawned so we’re going to just go ahead and delete that We’re going to go and create a new world make sure everything is on default all right and then now perfect we spawn right by a cave let’s get some potions of night vision going on here wherever they are there they are okay and we make sure our block has been registered There it is ruby or it’s going to look like this and hopefully this cave goes down further far enough for us to actually be able to find our ore okay here we go we’re below 48. so now anything is fair game okay so nothing down here Um is there gonna be any way of getting down any further hopefully there is so that way i can find it and if not i’m gonna go check my uh i’ll bring you guys with me i’ll check my uh statistics on uh my other one so i’m gonna just go ahead and Exit out of eclipse here and i’m going to pull it up once again and we’re gonna pull it up eclipse and we’re gonna go into more recipes plus and we’re gonna hit okay like so and then we’re going to go into our source files which are down here Restore got more recipes and we’re going to go to world generator ruby or and right here 56 i made it five um seven like i think that’s the uh number okay so we’re just going to copy all of this like so so we’re going to copy this And then we’re going to x out and we’re going to just copy the code over from my other mod now everything should be exactly the same but i’m just doing this for the numbers actually you know what i’m not going to do that because that’s not cool i’m just gonna Compare the two numbers here as we load up the clips again all right so we got our world generator so we have it under 56 so i’ll do 56 for our gems and then right here i think this is the rarity of it so we’re gonna put that at seven And we’re gonna change this to five because this is the um the max spawn rate size uh vane size that’s what i meant to say so we’re going to come into eclipse once again after comparing our numbers my voice is getting really dry i don’t know if you can tell But uh it’s pretty worn out i think this is gonna be the last episode that i record tonight plus it is one o’clock am and i should be getting some sleep right now so we’re gonna go to roadgenerator.tut we’re gonna change this to 56. come down here change this to Five and then come up here change this from 10 rarity to 7 we’re going to save it we are going to play and we’re going to create another world in which we can uh adventure on okay so we’re gonna come here delete this world create new world And go everything should be working all fine and dandy now i know it was working on my other oh god on my other mod so everything should be working a-okay besides the fact that we are in the middle of a jungle biome everything but that all right so we’re just gonna Climb over here find a village that’s in the middle of the water because thank you minecraft physics everybody builds their villages inside of waters if you don’t then you’re not part of the cool crowd so now we’re just going to look for a little cave inlet and here we go right here Looks like we have a nice little cave inlet make sure we still have our block at hand right there ruby ore good to go and we’re going to drop down and we should be able to find it anywhere above or below 56 so let’s go ahead and get some potions of night vision Drink those up and hopefully this goes down somewhere it’d be quite disappointing if it didn’t all right here we go it’s going down and down and down i’m gonna get some stone here block this up so we can see all of our ores if they decide to generate okay nothing generated Yet but that’s normal because the further down you get the more it’s going to generate that’s just how the world generator works if this doesn’t work we are actually going to copy over um a lot of our files or i mean all of our thing and i’ll actually put that In the description down below hopefully they’ll let me have that in the description i don’t know i might just have to like make a uh i’ll make it on the forum post or something i don’t know i don’t know but this should be generating with all of our other wars Oh this is actually a nice cavern there we go right here here is our wonderful generating ruby ore it is uh slightly rare uh it’s pretty much as rare as um not diamonds but just uh emeralds um it’s as rare as emeralds are inside of um inside of a Extreme hills biome but it spawns everywhere throughout the map so there’s some more some more so yeah there’s tons of it down here so that’s basically how you make your ore generate but not too like over not it’s not over generating so seven and then 56 and five are the magic numbers so Anyways guys that’s pretty much all i got for you today uh that’s how you make your own world generator and stuff and things and next uh time i record this series which is probably going to be tomorrow i will be showing you how to make your custom tool sets with uh Your rubies that you’ve now learned to spawn so sorry this episode was longer it was more of an it was more of a trial and error episode towards the end instead of coding but uh i’m sorry but that’s kind of how coding is it’s a lot of trial and error Until you get stuff right so anyways guys thanks for watching if you enjoyed the video make sure you like the video subscribe to crisis hub youtube channel and follow that link in the description over to my youtube channel as well as my twitter subscribe to my youtube follow my Twitter all my videos are tweeted out automatically when i publish them as well as i go on there occasionally to tweet so anyways guys thanks for watching and i’ll talk to you all later peace Video Information
This video, titled ‘How To Make A Minecraft 1.6.2 Mod Ep. 6 Ore Generation!! (Minecraft Forge Coding)’, was uploaded by CrysisHub on 2013-08-20 19:29:01. It has garnered 2659 views and 26 likes. The duration of the video is 00:27:59 or 1679 seconds.
Director’s Channel: http://youtube.com/RushedYouRG
Director’s Twitter: https://twitter.com/RushedYouRG
Just a quick note: Sorry that there is some trial and error in this video, that’s basically a main part in coding and I hope you understand! ——————————————————— Get your CompetitiveEdgee Controller: http://twitter.com/CompetitiveEdgee
Follow CrysisTV on Twitter: http://twitter.com/CrysisTV
Become a CrysisTV Director: http://crysis.tv/Directors
Become a CrysisTV Partner: http://crysis.tv/Partners
Get Awesome Gaming News Everyday!: http://crysis.tv