So this last one uh what we’re creating with this is the particles uh the fire particles which we aren’t necessarily going to have on our furnace in the end but i’m going to show you how to do it just so you know how to do particles So this is a side only this is a client side thing we won’t that we have to do don’t have to do this on the server it’s just a rendering thing it’s going to go public public void random display tick okay and normal parameters world world int x into y into zed And random random all right so um so we’re gonna check if it’s burning so if is burning two so if is burning two is equal to true um then int i spelled that wrong too many r’s so we’re going to create int direction so we’re going to create a an integer name direction And it’s gonna be equal to world dot get block metadata x y and said cool cool now we’re going to create a float and this is going to be xx uh now this is a little bit of a long line um because we got okay so when you’re Creating variables and you have multiple variables uh we don’t need to go like in float xx and then go down the next line keep doing this and creating being creating new ones what you can do to kind of keep your code shorter you can go float xx yy zed xx2 z2 And then those are all created as separate variables you can do them separately but they’re all in there and they’re all created now we’re just going to uh tack on some stuff to these so uh xx is going to be equal to we’re going to cast it to a float Which is going to be x plus 0.5 f okay then y y is going to be a float we’re going to cast two float as well um we’re gonna go random dot next float next float uh times six point zero f divided by sixteen point zero f and then z zed Is going to be a float again again cast to a float zed plus 0.0 or 0.5 0.5 f uh now i’m just going to quickly going to explain um these actually keep i forgot do that on this one here too forgot the equal sign uh i’m gonna kind of explain these uh These casts here for a second just thought i should do this so when you’re casting something basically what you’re doing so um uh as far as numbers go you have you have ins doubles floats uh so an int is just a single number so one two three four five six seven eight Nine ten okay a double is like 1.25 what 3.72 5.49 and thing and stuff like that and then a float for example is uh 1.75327 or 3.735278 something like that just those are just random numbers uh so basically what what what you’re doing when you’re when you Cast to a float since since what the numbers that we’re dealing with here may not technically be floats when they’re done because they could come out to be like um you know uh the xx could come out to be two for example it’s just an array it’s i Don’t know if it’ll ever actually be two but it could be two which means it’s going to be an end to not a float so we if we cast to a float it’s always going to make sure that it is a float so it’s just a conditional thing okey-dokey So now we’re onto x2 xx2 which is equal to random dot next float uh and we’re going to times that by 0.0 or 0.3 f sorry and then we’re going to minus 0.2 f okey-dokey and then z 2 is going to be equal to 0.5 f we’re done with that okay So now we just got a a big if statement do here so if direction is equal to four then world dot spawn world dot spawn particle we need to give it a name or we need to give it the name of the park on this case we want smoke okay uh More doubling and stuff so it it it wants doubles not floats you can say well why the hell did we make them floats in the first place well just do it okay just do it so double uh we’re going to cast it to a double and we’re going to go x x Minus zz2 okay next parameter is going to be again cast it to a double since we’re dealing with floats here it’s just going to be yy and then the next one is going to be again cast to a double and then type zed plus so within another set of parentheses zz plus xx2 And then after that we have some more these are also doubles we’re going to go 0.0f 0.0 f 0.0 f double so yet we’re putting floats no no no no wait wait my explanations of of each one are wrong uh double is like 0.0 0.2 and then and then f is like 0.00 And anything more than that okay sorry about that minor confusion so now we can do two different kinds of particles we can do our smoke and then we can do our flame so you just copy this line and the only thing we have to change is flame So we’re going to copy both of these lines now smoke the smoke spawn smoke particles and spawn flame particles and we’re going to go here we’re going to go else if and we’re going to type in direction is equal to 5 uh so if the direction is equal to 5 Then we’re going to do it we’re just going to do the same thing now from here we’re going to grab that no it’s not what i want to do copy we’re going to grab the whole else statement from uh this ending parentheses right up to this before the the other parentheses I’m gonna paste that two more times and we’re gonna change the five from the third one to a three and then the last one’s going to be 2. so uh the direction is equal to is going to be 5 3 or it’s going to be 4 5 3 2 and i just felt direction wrong there’s an r in there that shouldn’t be there there we go and we’ve done that and holy smokes we’re finished we’re finished booyah so there you go there’s that’s part one of this tutorial we got this whole uh the whole class file for the furnace Finished next time we’re gonna be doing the tile entity which is even more code so we may even have to break that one up into two parts hey i may even break the break up this one into two parts who knows i may have done that already Anyway guys thanks for watching uh look forward to the next one coming in the next few days i hope next week at tops uh and we’re gonna get this furnace done we’re gonna get shocked shaq net shack powernet up and it’s all gonna be great thanks for watching everybody enjoy your week or Your weekend uh whenever you’re watching this and uh stay frosty my friends you Video Information
This video, titled ‘Minecraft Forge 1.7.2 – ShaqPower Furnace Part 4’, was uploaded by ShaqGames on 2014-07-10 17:00:03. It has garnered 722 views and 14 likes. The duration of the video is 00:09:58 or 598 seconds.
Visit My Website! http://shaqaruden.com
Join Me on Google+!!!!! https://plus.google.com/112682976447447748810
Join Me on Facebook! http://facebook.com/shaqaruden
Follow Me on Twitter! http://twitter.com/shaqaruden
Follow Me on Raptr! http://raptr.com/gamingfusion
Follow Me on Instagram! http://instagram.com/shaqaruden
Join Me on Steam! http://steamcommunity.com/id/shaqaruden
Subscribe to the channel http://www.youtube.com/shaqarudengames
COMPARE YOUR CODE http://shaqaruden.com/redstonetutorial
Thanks to Fuizle for the old intro/outro song cover! FInd the video here http://www.youtube.com/watch?v=O5Xu161EwHA
Thanks to Gyrowolf for the new Intro/Outro music. You can check him out on SoundCloud – https://soundcloud.com/gyrowolf
Please Like, Comment and Subscribe!