 Hello guys Crypto Grounds here welcome back to another idle game tutorial video this is episode 24 and today We're gonna be doing a planet slash world system So if you've played at vendor capitalists you've seen earth Mars in the moon. That's kind of like what we're doing except For our planets ours are gonna be different game modes anyways if you enjoyed this video don't forget to leave a like subscribe my channel and turn on notifications if you're new and Let's see. Let's come I'm gonna start doing this. I'm gonna come up with a question every day for a video So what should today's be? um What is your favorite mobile idle game comment that below and I'll be sure to respond to those Okay, let's get on with it. So I've already made my Yeah, we got more buttons going on, but I have my planets thing going on So maybe in another video I can do like redo the navigation thing because this is kind of messy, right? so Okay, so I've added my planets button and I made an empty planet screen Make sure it's stretched through the entire canvas like so And now I'm gonna do something like I did for the rebirth screen where it's on top of that or it's not on top But actually it'll probably be just like Settings maybe No, wait, why are the settings like this? Okay? Well, I guess I'll just shift these down real quick All right, so I'm gonna add an image to this planet screen Image and then in here I already have a pre I already have a space background So you can do whatever you want. I'd suggest you to make your own instead of using a One they can find on Google or find one. That's copyright free Okay So this is very ugly looking So I guess what we can do We slice it. Oh We can do to tiled. Let's do tiled this work Cool. Yeah, we'll do tiled and you can just zoom in to however you want. Now. This is not the best way I'd rather just have a picture pre ready for this, but I think this looks just fine. In fact, I'm actually gonna make it a little darker Okay We have our planet screen Wait for oh, we need a back button too So in a rebirth we have a back button, so we'll just copy that back Okay, and let's add a knit. Oh, it's a lot of nip. Yeah, I can't talk. That was so bad. Okay. Let's add a point Okay, so here we go. We have our planet right here now you can add a Mars or whatever you want and Just for the video. I can add a second one real quick All right, so let's rename this to earth copy and paste this and then we'll add our Mars There we go Ignore this. Yeah. Here's our Mars. I call and I think it looks pretty good in my opinion. I don't do Pixel art and I'm pretty satisfied with Mars. I think I like it a lot better than earth. I don't know. It just looks nicer Actually, it doesn't have a bright glow. So let's export this as a PNG to because what happens sometimes with Photoshop files is if you use them in unity for some reason the glow is just turn out white I'm or more white rather than the color they're supposed to I don't exactly know why that happens, but It's a little annoying. So if anything with glows, I'd suggest you just to export as a PNG That's kind of the downfall of psd files Wow, if you don't have it you can directly edit them in Photoshop and it'll automatically update unity so, all right Change the icons There you go. That's much better. So here is our Mars. This one would be a little smaller, right? And we can just put that like right here Do whatever you want you can add a line right here. Let's see. Do we have a do we have a square image? I doubt it, but let's check. Oh, we can just do this cool. We can have a little Skinny line connect them or something cool I don't know you can do whatever you want for that, but I'm just gonna connect them like so and Let's have some interface. So let's add a text inside No, not an image a text Okay So we'll just call this earth So let's say earth is actually our main location, right? So let's say that's earth has changed the text Why is that so small? And so you can actually read it. Let's add an outline No, why I didn't even search that There we go. Yeah earth. I'm gonna make it at a border of two And this will be the name of the planet and then in here we can have currency So how we have our Coins right here Now let's center these because I don't think we need anything else here if you want to provide more information that is completely up to you and So my goal here is to have Mars boost earth in a way, right? The coin that or the the coins per second. So let's have let's copy another one of these and put it right here E I'm gonna call this EM connect for earth to Mars Call it whatever you want. This will be the EM boost And basically I if I want to do this eventually if you guys want me to do more I can add another planet where it just does the same thing But another planet to Mars, which I could I would just do moon because that's like the only other pixel I have All right, so this will be zero X coins or Coins per second All right, that looks just fine to me and then in Mars. Let's just connect to the The text for that and this will be Mars Now let's come out for the coins. I'm gonna change to this to I don't know you can be unique But I'm gonna do I could do like Martian coins, but I don't really know any like interesting You can just do Mars tokens. I don't know yet. You you can be as creative as you like with this However, this is the best I can come up with right now There we go. We have our basic interface So earth will be a Mars, but you'll basically just go to my earth. So we have our main screen right here. Oh Okay, so You know what we're gonna have to do. So since this is earth We're gonna have to create another We're gonna have to create another canvas, so let's just copy main screen Turn that on and then delete everything inside it Stretch to full screen 0000 Put it up here and this will be earth because Mars is gonna be its own thing, right? It's own prestige So earth will consist of everything except planets Events screen we can add this could be a button That could be accessed outside So daily events could be right there too So we kind of got a plan ahead of this. So what buttons do we not want to include? So we want main achievement screen that could be like it like an earth thing Prestige rebirth autos. Okay, and now for buttons. We want everything except for events Okay, so if we want to go to Mars, we will just go to Mars Cool, so let's copy and paste this the entire earth Places Mars so now it will have the planets button as well, right and And The events button Right here. We can have we can have our own events buttons. We can readjust that. So just copy and paste events button and put it to Mars And I'm only I think I don't want to get too much into Adding another planet because I don't want this to be extremely long video But I could just do further videos where we do more things with this All right, so we want to keep everything except for event or We want to leave everything except for main events Planets and let's turn off earth We only need a Main screen, which is this Okay, now Mars. We're gonna add a background which I'm gonna go grab a right real quick Cool. So now let's put image and Mars BG So this is another crypto clicker's background that I already have already. So yeah, please design your own Uh, so we have main daily events Planets now this seems a little too bright Perfect. Wow. How did I get that so perfect? I already just guessed Okay Uh, okay, so we need another header, right? So this header will be the earth header So we're going to copy this header and throw it in Mars because we're going to have A completely different thing so you can have another add button here, but I'm just going to delete this Events token go can go here So planet screen will cover everything. So we need to fix this then so That should work what happens if we rescale it does it work? Oh, I uh it Doesn't this again, this is like mobile. So you you do your background. This is what mines go. I guess we'll do It doesn't work perfectly on vertical, but this looks fine for now Okay, so we don't need to be an offense or a planet screen So hopefully if you're if you're lost, this is what the hierarchy looks like right now. So make sure you're on track I'll keep that open Um, so header we don't need we don't have gems right now. So we can just hide those And tokens text we'll just keep those And I guess for coins we can just throw this right in the middle Cool. So this is mars coins, right? So just do mars coins. We can change the color Make it pretty and this will be our Mars coins or you can just do m coins per seconds. However, you'd like m coins per second Like that we're just gonna do mars coins per second. Okay Here we go. We have our main setup going on right here Um, so in the main screen we you're not going to do prestige. So let's just ditch that The full reset is already binded with the full reset so we can keep that here or put it in the settings This honestly should be in the settings in the first place So let's add that button to the settings and delete it in the In the main screen from earth full reset. Just get rid of that So then when you go to settings, it's right there as it should be Okay, so we don't have anything here to do. So let's just make Let's make an invisible click. Can we do that? Let's do this. Let's make this entire mars Isn't this main screen? Okay, let's stretch this main screen while we're at it 00 00. Where is this prestige button now? Is it still there? No, it's right there. Okay, we'll just hide that Okay, click button. Let's make our mars our click button now. You don't have to do this But I'm just gonna do it because it looks cool So let's do Instead here we can multiply our coins so we can start with one so we can just do Like something like that I think that's interesting. We can yeah, let's change things up Okay, let's make this big I think this looks good so far. So now if we click this it shouldn't multiply your initial coins So let's hop right into the script. So here. Let's create an empty to divide the earth between Uh, the earth stuff so the methods where we can get the upgrade achievement automated rebirth prestige game This is the game is still going to be like the main one. So I guess we can just get these ones And let's create another empty called mars And we will create the script as this is what we should have done at the beginning This is why planning a game is very important. So you actually know how to How to like get your code structure correct the first try Because otherwise I would have done earth manager and mars manager, but we're going to do mars manager So everything in mars is going to be right off of the mars manager instead of the game manager. Okay So let you need to create the thing and then we will get started So we're going to use the same data the player datum class for our stuff But we will just separate it between the earth and the and the mars things. So yeah All right, so we are currently in our mars manager and we have to do our normal duties Which is import that using unity engine dots ui namespace Okay, and we got to get the break infinity And I bet we're going to be using static break infinity dot big devil For the math stuff Okay, so let's start with our save related things. So We have our regions divided here Let's see Events this can go to the bottom So let's I'm going to clean this up or click Okay, so I have added sections for pretty much everything and we can do it here, but I don't want to Exhaust you so I'll do that in like a cut so we can close everything here. So actually, you know what? Let's I'm gonna I'm gonna reformat this real quick too Okay, so we have everything split it up. So this will be much easier in the long run So make sure you do that because we can just close everything we don't need to access And that makes our script look much shorter when you're opening it up. So anyways, let's add another region Uh, it's called bitcoin So you do that by doing hashtag region and then the hashtag end region and you can close it just like that Very neat So in bitcoin all we really have is the The click value which is going to be one and it's going to be based on an equation here Okay, because we're going to do it the correct way, right? So there is no per seconds. So it's just multiplying. So we're going to have our public big double Because it's multiplying. So obviously it's going to get big And then here and what we can do eventually is some add some kind of like soft cap because if it's going to multiply It's going to go pretty fast, right? Or you can make it go really fast on purpose and it makes it really fun, right? That's why big double is helpful here We have to risk that Um, anyway, so this will be mars coins And this is the only save thing we're going to add here today Okay So hashtag region Mars Oh, I did it. Yeah, I named this bitcoin. I meant to put this mars. Sorry. I did this for my game. So I'm just like Now we're going to set coins to one because we're multiplying it or else if it's zero we can't multiply it ever Hashtag end region There you go So we can close this stuff too since we don't need to access it or change anything We could also obviously just close this but i'm just closing everything else just to make it easier when I come up And just want to change one thing at a time And we're done with these let me add a region for events See how much easier this is to read It's like so much easier Now we can go to our mars manager Let's add a text. We only need to access one text, which is mars coins text public void Um, we need to do navigation after this a public void update And we're gonna have a game object which will be controlled. I mean, we should have a nat Let's have a navigation manager. So we'll do that We'll add an if statements once we do that. So mars coins text dot text is equal to dollar sign So our thing is still being accessed in our in right here. So we're just gonna do public idle tutorial game Game and then we're gonna do var data equals Game dot data because we will be using this in the future and here all you gotta do is put data dot mars coins And let's do methods dot method dot wait, what is it? Oh, it's Methods dot notation method F2 And we should be good. Okay. So now we need to click We need to click so let's do public void Uh, click you name whatever you want We can just do click planet And basically this is just gonna multiply by and we're gonna change this later on just remember that so data Game dot data. Let's do var data var data equals game dot data Data dot mars coins is times equals 1.01. There we go Okay, so this should work, but we need to get the navigation down So in here, we need to add another tab a change tabs and we're gonna have to add this to the mars manager too So let's add a planet group And this will be called planets And let's copy and paste This first And then search Let's add that canvas planet group Okay Cool. So let's copy and paste this into here Obviously we can just reference it In our game, but we're just gonna Uh, no, we don't need this right now Okay, so we need a planet manager because we want to manage both of these at the same time Okay, so Let's see planet manager a planet button from both earth and mars are going to do the exact same thing So we're just going to change them to planets and that will both access The planet screen Our game manager we need to add the planet screen All right, so now we need to have Uh create empty planet manager planet manager now this will just be a short script to This will be like the central point between all the other ones And we'll use this in here Okay So just I ignore all that for now. But all we need is the Unity engine namespace and the unity engine dot ui namespace So let's add a public canvas earth and a public canvas Mars now that's the only thing we need And we what we can do here is do public idle tutorial game game And then we can just Uh, this is for on disable all we can just do game dot Main menu group Oh, no, it's planets group game dot playing uh planets group dot game object set equals false, which we already have right here And now we only have two so we can just get rid of the rest Which will be earth and mars I don't know what this is Okay, and this one will be labeled earth This one will be mars Cool, and that is it for navigation Pretty easy, right? If you just want to add more planets. You just got to make that list longer So yeah, mars Earth in our main game, and I believe that is it. So now what about mars? Oh shoot We need to make a new game object. That's empty. It's got nothing in it And then put mars manager in it just for organization Cool And we'll put Game in here and our mars coins text, which will be in the header But yeah after this we'll get the boosting things going on. So let's turn off mars And turn on earth so we can see if this works and turn on main screen I expect this to work. This was not that hard to make Okay, planets So now I can show you how to do scroll rec too because we don't we can't do that right now and we got to add the text here So mars coins, let's click on it. It doesn't do anything It's because we haven't actually done the planets yet But since we're in here We can test the planet screen real quick since these are buttons. Actually, no, let's do this off So we can only do this once Add a button Click on the plus drag planet manager to it and do Change tabs while earth will be earth And mars will be mars So let's add those texts. We're clicking our planet manager. So I guess that's two more things we need to do So we have our public text Uh earth coins text We have our mars coins We also have our em boost text, which is earth to mars Okay So we'll run this in its own update because it's not related to Earth or mars directly and again, that's just how i'm organizing it You can do it differently. You can do everything update or you can do everything in the main script Like uh everything calls like the run method if that makes sense So We need to add mars here Oh, actually, no, we don't need to because it's in our data, right? So our earth coins is going to be equal to Um, let's do var data equals game.data so we can simplify this so data dot Oh, right Gotta add the curly braces. So data dot coins And we can add game Game dot no that's methods Methods dot notation. I don't know what happened here, but it totally just screwed up Data dot coins. There we go. And then we'll just put the f2 And after that we will put coins There we go now for mars. It's the same thing except with mars coins mars coins And there we go. So now we haven't figured out the boosting it which we will do next So It should be good. Okay, so we have our tabs Good, we need to add our Text from the planet screen. So we have em connect. So we have earth We have the coins coins and our boost is right here, which currently doesn't do anything Cool This all should be a hit Successful game now. It's got more planets, which we all love. There we go. See pretty So now we can go to mars. You can go back Now back really just I think this just turns off the screen. What does the back button even do? Oh, it just goes to main. So let's just turn this off So you only need that, right? So I think we need to turn we need to make planets goes, uh We need to make it go to main so Because it turns everything off. So we'll just do main dot planet group No, it's game dot main group Eagles true All right While mars will do the exact same thing Okay, so let's go to mars Cool. So now this should multiply Doesn't seem like it is yet. I don't think I've applied the click yet Yep, I haven't oh wait, I have but it's the wrong click. Okay So let's let that apply our changes and it should work properly And then we're just gonna drag this mars manager And replace it with our own click which will be click planet and this should work Now the thing I need to do is add like another events token Button two hour mars. There you go. Now this should start multiplying So if we start clicking a lot if we get our auto clicker actually, yeah, let's get our auto clicker If we change this to one That's too fast. Oh, I know it's too slow Now this should start multiplying right So you can literally just keep this going and it will eventually get to Really high numbers because it's multiplying So that's kind of the issue. So maybe what we can do is add an equation For the multiplier where it kind of just slows it down. So you're not increasing it to build Tons of numbers see we're already at e3, right And it only took maybe a few hundred clicks to get there But you can see that kind that will grow, right? So we'll kind of have to limit that All right, so let's go to our planet screen. It should show. Yes, indeed it does So now we need to get the coins per second boost So here what we can do is add a big double public big double em boost And let's set this Uh, let's just be basic. Let's do log 10 Oh, right. We don't have break infinity yet No, this is planet manager Uh, we can do all the boost stuff here. Let's do that. So let's go out. Let's go here and just copy everything Just like that. So then we can just do log 10 and Uh I feel like log 10 is a lot. So let's just do log 20 and then we will do We're going to do squirt square root of Game.data plus one because if it's zero then we're just going to get bad evil numbers And this is it. This should be Mars coins Plus one and this will also be a plus one because it starts at zero log starts at zero Even though the plus one is in here, right? Let's just prevent it from going to from being anan At zero, okay Let's apply this to our text and this just basically emboost We're going to do methods dot notation method And then we're going to put our emboost F2 And then here we're going to do new line Coins per seconds, right? There we go. Let's uh, let's go to our main script right here Let's add our planet manager planet manager planets And we need to go to our coins per second. Where is that total coin coins per second We're just going to do temp times equal planets dot emboost Piece of cake, right? So now this should start to work And this should have saved it too I think that's all we need. I don't even oh, yeah, we need to apply planet manager Good thing. I didn't look good thing. I checked for that because I would have forgotten Okay So we are getting 12 per seconds. What about planets? So we're getting 2.4 times. So let's see 12 per second So let's just keep clicking away, right? Let's just have our auto clicker go. Oh, did I close it? Come on So you can just keep clicking away. So we 2.44 13. Yep. So it's going up. So that works So now what I'm going to do this will be like a kind of like a sub part of the series So we're all just do like like the next video if I wanted to do planet upgrades like from mars, I will do like planet slash upgrades or something like that or mars has upgrades. So whatever you think it's best just let me down below Um, anyways, I I think this is it for the video. I mean Oh scroll rekt. Let's do that real quick. So let's turn on our planet screen Now let's add a UI Scroll view So what we can do is get rid of these Scroll bars because I really don't like them and this will just be our scroll Or yeah, and this will just be our panel. I like to call panel and our content is just whatever is inside Right, so let's just make the scroll stretch the screen Zero zero zero zero zero we can get rid of this ugly ass background too And let's add a mask because we don't want anything outside showing even though that really doesn't matter And I forgot we need to leave this back button Okay, so now we have a panel So what's what is this planet screen? What is this image in the center? Is this the main canvas? Huh, I don't know what that is Okay, but anyways, we will put our Everything in here or connect the boost everything in the panel Uh, okay show mask graphic. Why is that not working? Oh, that's it's here. Why is that here? Okay, that was a weird. I always put my mask in here. So I guess that's not how that works Oh content. Oh wait, right We got to put our Rekt transform so our yeah, that's right here our content now our content is here and our viewport is Here so their setup is a bit wack. We're just gonna get rid of this So now if we move this panel around, uh, man, that doesn't work. Why doesn't it work? Okay, so I found the reason why the really the reason why is because this You can't have the alpha of the zero so you can just have it like the slightest amount of so you can just do 0.01 Even though you kind of see Actually, you don't What am I seeing? This back. Oh this background we can just put none So if we put zero, I'm trying to get find a way to get rid of this ugly ass gray Oh, is it because of this right here? Yeah, we don't need this image. There we go. So let's make the panel Um, be as big as we want so we can just have it like this Put it dead in the center like so and this should work. See if you the mask is applying like that cool So now if we save that this everything should work perfectly and also you should Make sure you keep this like that You can change your scroll sensitivity. Let's do 10 even though only scroll vertically But that's okay I'm assuming most of our stuff's gonna be up and down anyways So now We can So we can drag things around cool. So now let's say we don't want this Um To let's say let's see want it really slippery. We can just increase the deceleration rate Basically, it gets faster if you set it to a really high number. So how's it getting like faster? So if we keep moving it Let's see it eventually slows down But you can see how it kind of just goes really fast if you want no acceleration rate Oh shoot that broke it Where'd it go? Oh no It's gone Oh, it's n a n. Okay Shoot it's gone It's long gone Okay, so don't set your deceleration rate to negative. So it sets like 0.01 All right, so if we do that you can see how it slows down much faster If we do zero Oh See how it just like stops instantly. So that's what zero is except for the edge We can turn that we can do that. Is that inertia? No, that's not So let's say you don't want it to that you can just turn off inertia So here's our scroll our scroll is very weak You can just turn that to 100 and it looks pretty good, right? Um, so yeah, let's have inertia off. I think that looks just fine to be honest if you're dragging a map Yeah, that looks much better and elasticity. Let's set that to zero. So then it just doesn't do that Now if you want it to you can set it to like let's see what happens to have a really high number Should be like so it's not as sensitive See how it's very slow when it pulls back It's very slow. That's what elasticity is We could set it to 0.1. I think that's what we should have it at. Now what happens if we do 0.01? I bet that'll look kind of stupid. Yeah, that's the same thing as having it. Let's just have it at 0.2 I think just I like the smooth look of it But yeah, anyways, here is our scroll rekt and their plant system our planet system Cool. I think everything looks great. I think you guys are ready to get rolling with that Now I will do some videos on this subject such as another pressed each system Which we all love right anyways, I hope you enjoyed this video. Don't forget the question I asked earlier. What is your favorite mobile idle game if you enjoyed this video? Make sure you leave a like and turn on notifications if you and subscribe to my channel if you're new Anyways, have a good one. Peace