Fixing the asteroid generation in my space mining game

Sdílet
Vložit
  • čas přidán 11. 07. 2024
  • WISHLIST Star Mining Co. on STEAM:
    store.steampowered.com/app/25...
    Minecraft terrain generation video: • Reinventing Minecraft ...
    In this video I go over the techniques I've used to generate the asteroids in my space mining game. I use Voronoi cells to create clumps of basic materials, and then use remapped perlin noise to carve tunnels into the asteroids.
    Originally I used random walkers to add ores and precious materials but these looked pretty bad to me, so I swapped over to creating little clusters of circles which I think looks a lot better.
    Let me know what you think!
    If you want to see the origins of this game, check out the original (cringey) devlog here: • Using shaders for terr...
    Follow me:
    Twitter: / barneycodes
    Reddit: / barneycodes
    Support the channel: www.youtube.com/@BarneyCodes/...
    Chapters:
    0:00 Why original asteroids are bad
    0:58 Voronoi cells
    1:29 Ridged perlin noise tunnels
    2:07 Ore clusters
    #proceduralgeneration #devlog

Komentáře • 62

  • @BarneyCodes
    @BarneyCodes  Před 10 měsíci +6

    WISHLIST Star Mining Co. on STEAM:
    store.steampowered.com/app/2584800/Star_Mining_Co/
    Is there anything more you'd add to the asteroid generation?
    Would you like me to go into more depth on any of the techniques I used in this video?

    • @ketos8315
      @ketos8315 Před 10 měsíci +1

      Damn, you surely never heard of To The Core.
      You could have at least mentioned that youu got inspired from To The Core, you even copied the artstyle

    • @WeAreMachineMedia
      @WeAreMachineMedia Před 10 měsíci +1

      It would be interesting to hear about how the destructable physics and collisions work!

    • @ZOCCOK
      @ZOCCOK Před 10 měsíci +1

      @@ketos8315 sometimes people have ideas that have already been implemented.
      One can assume that he had a idea, but it was already implemented or
      He was inspired by that game but forgot to credit, or didn't think it necessary enough for a 3 minute video about making asteroids exciting.
      Or he had malicious intent to not inform about To The Core, like your comment implies.
      I like to think that he just had a idea that was already implemented or that he forget/ didn't think necessary enough

    • @nolol9907
      @nolol9907 Před 10 měsíci +1

      Perhaps you could do layers of different materials, along with the cells, kind of like how the minecraft terrain does it's biomes with humidity and temperature

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      @ketos8315 I've honestly never heard of it until now, it does look similar, but I think my game will end up being very different. I'm making it as a roguelike deckbuilder. I first made a video my game a year ago if you want to check it out (it's unlisted because it ranks pretty high on the cringe-o-metre): czcams.com/video/hYlWGMbqFLs/video.html

  • @JeremySeitz
    @JeremySeitz Před 10 měsíci +26

    Love this concept! some ideas: you could make it so the internals of the asteroid are not visible at first, you have to scan the ground and dig, and scanning costs some credits. Would also be fun to place explosive charges that you need to get away when they explode. Or perhaps some minerals are reactive and will detonate when you mine them.

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +9

      Thanks, some great ideas there! Nothing is set in stone yet so I'll definitely play around with these and see how they go!

  • @lilz3bra
    @lilz3bra Před 10 měsíci +2

    if you add weights to each material, and use that as the probability of that material spawning, combined with voronoi cells, you will get a much more "realistic" ore distribution, where denser materials are typically found deeper, with some outliers here and there. but good job mate, keep it up 💪🏻

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +4

      Really good idea, I've already got the materials sorted based on durability from when I was doing the layers, so that shouldn't be too difficult to implement! Thanks for the comment!

  • @troutsashimi
    @troutsashimi Před 10 měsíci +3

    i think it would be fun to also change the generation a bit based on depth so that the digging tactic changes both based on where you start digging and also based on how deep you've gotten into the asteroid

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      That's a great idea, thanks for your comment!

  • @Mysda_
    @Mysda_ Před 10 měsíci +1

    Really nice channel. Lot of procedural generation, and even concepts that are super close to what I've done before, loves it!

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +2

      Thanks so much, glad you enjoyed it!

  • @sinom
    @sinom Před 9 měsíci +1

    potential improvement would be to weight the probability of harder materials each cell gets to make it proportional to how close to the centre you are. That would end up with some kind of compromise between this and the original version.
    Additionally some fog of war type mechanic would probably be nice where you can't immediately see the whole asteroid but this very much depends on how you want the game to play.

    • @BarneyCodes
      @BarneyCodes  Před 9 měsíci +1

      Thanks for the suggestions! A few other people mentioned biasing the materials too and I think it's a great idea. I've actually already implemented it, just working on a few more features before I do another update video!
      I might have to play around with the fog of war and see how it feels 👍
      Thanks again for the comment!

  • @ChrisCiber
    @ChrisCiber Před 9 měsíci +1

    Asteroids don't have to be boring and round. They can be potato shaped where two different asteroids kind of merged together. Could have multiple cores. Could have barbells. Could have some asteroids that are spinning rapidly which makes them harder to approach from some angles. Could have "veins" of more valuable material to follow.

    • @BarneyCodes
      @BarneyCodes  Před 9 měsíci +1

      Great suggestions, thank you! Having more shape variations sounds like a good idea

  • @studentjahodak
    @studentjahodak Před 10 měsíci +6

    This really seems like carbon copy of To the core.

    • @firedestroyer53
      @firedestroyer53 Před 10 měsíci +1

      yeah that's what I thought too.

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +4

      I'd honestly not heard of To The Core until it was mentioned in a few other comments. I think it'll end up being pretty different since my game is a roguelike deckbuilding game. I made a video about this about a year ago if you want to learn more about it: czcams.com/video/hYlWGMbqFLs/video.html

  • @timmethyh
    @timmethyh Před 10 měsíci +1

    it's maybe out of scope or I could imagine really difficult to implement, but add physics for sand for example? and maybe (local) water?

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      I've been wondering about that and think it would be really cool, but I think that's probably a whole new project! Maybe for the sequel? ;)

  • @proxmbeats
    @proxmbeats Před 5 měsíci +1

    What if you add a decently thick top layer of the light gray, then have the random materials under that?

    • @BarneyCodes
      @BarneyCodes  Před 5 měsíci +1

      I've updated the generation a bit since this video (I think I show how I changed it in the next devlog?), what I do now is weight the randomness so materials are more likely to show up in bands, but they still have some randomness. I think the overall effect is quite similar to what you're suggesting!
      Thanks for the comment!

  • @Console.Log01
    @Console.Log01 Před 10 měsíci +1

    voronoi generation is also exactly how I generate the worlds in my terraria clone. Interesting!
    I'm gonna have to check out that perlin noise trick for caves in my game, atm they're very boring and sort of buggy.

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      Definitely check out the video I linked in the description of the minecraft dev giving a talk, there's a lot of really great info in there!

  • @carlsoll
    @carlsoll Před 10 měsíci +1

    Yoo this pretty neat 😏👉 Best of Luck! *Edit* Looks like they could be Twice the size 🤔 Seems like after a couple cards you’ve made it 🤙

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      Thanks! Will definitely make them bigger in the future! There's also a lot of tweaking and balancing to do for the cards!

  • @marlysalt
    @marlysalt Před 10 měsíci +1

    The first 'style' of asteroid looks manmade. Maybe those cores are technology upgrades or robots to pick up.

    • @BarneyCodes
      @BarneyCodes  Před 9 měsíci +1

      I still need to give some thought to how the cores will work, thanks for your comment!

  • @MeatBeatingFreak
    @MeatBeatingFreak Před 10 měsíci +1

    Im mostly just excited to play this game tbh, do u plan on releasing it? if so, where? Will it be free?

    • @anolive7535
      @anolive7535 Před 10 měsíci +1

      same here!

    • @ketos8315
      @ketos8315 Před 10 měsíci +2

      you can play To The Core right now on steam, its very similar

    • @alexandermeyer317
      @alexandermeyer317 Před 10 měsíci

      @@ketos8315 To the core is great!

    • @MeatBeatingFreak
      @MeatBeatingFreak Před 10 měsíci +2

      @@ketos8315 ive already played it and completed the entire game, got all upgrades and all ^^, thanks anyway tho

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      I'm hoping to get organised and put out some test builds/demos in the not too distant future. Eventually I plan on releasing it on Steam, not sure about the price point at this stage sorry!

  • @needabettername1559
    @needabettername1559 Před 10 měsíci +1

    Different materials and texture strength, like as you go in it gets harder to break the material

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      I think I'll end up biasing the generation so the stronger materials are more likely to be at the centre, but not guaranteed. Thanks for the comment!

  • @zrcx00
    @zrcx00 Před 10 měsíci +1

    i kinda think the asteroids should be a good portion bigger so youre not so easily at the core

    • @MeatBeatingFreak
      @MeatBeatingFreak Před 10 měsíci +3

      i think there'll be different difficulties on the asteroids, so some will be larger and some would be smaller. i wouldnt worry about it

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      @amogus3795 I'll definitely make them bigger in the future! There's also a lot of tweaking to do for the strength of the bombs which should make it more challenging.

  • @Enteropy23
    @Enteropy23 Před 10 měsíci +1

    i think i seen game like this before

    • @studentjahodak
      @studentjahodak Před 10 měsíci

      To the core released just moth ago

    • @Enteropy23
      @Enteropy23 Před 10 měsíci

      @@studentjahodak whats to the core

    • @Enteropy23
      @Enteropy23 Před 10 měsíci

      @@studentjahodak i use bing

    • @PiggyKillerQ
      @PiggyKillerQ Před 10 měsíci +1

      @@studentjahodak This also seems really similar to a Cool Math Game Diggy

    • @BarneyCodes
      @BarneyCodes  Před 10 měsíci +3

      I did make a video on it about a year ago: czcams.com/video/hYlWGMbqFLs/video.html
      But as a few comments have mentioned, there is another game called "To The Core" that I was unaware about that seems similar.