one month voxel game development

  Рет қаралды 50,903

Tantan

Tantan

Күн бұрын

Пікірлер: 160
@barj
@barj 2 жыл бұрын
With each upload: rust calls me.
@elonmax404
@elonmax404 2 жыл бұрын
Respond to it then
@dice6845
@dice6845 2 жыл бұрын
scratch is way better Imo
@Ray_uck
@Ray_uck 2 жыл бұрын
$1000 to whoever makes a better game in rust? (not a challenge, a video idea)
@lonelyfloat2582
@lonelyfloat2582 2 жыл бұрын
@@Ray_uck "I MADE MY DREAM RUST GAME"
@Gwilo
@Gwilo 2 жыл бұрын
maybe you might make original content finally
@AJ213Probably
@AJ213Probably 2 жыл бұрын
8:45 I really suggest going through "Minecraft terrain generation in a nutshell" by Henrik. It seems Minecraft uses 3 other values and spline points to solve the issue of biome transitions. It also has just in general a bunch of information on how to handle terrain generation in a way to make it look really good. It's what I plan on doing when I work on a voxel game again.
@Proprogrammer001
@Proprogrammer001 2 жыл бұрын
Was gonna comment the same! I remember thinking "It was such a huge problem for minecraft, how did he solve it so ezpz?" and then watched the rest of the video and saw him describe how it wasn't all ezpz xD
@kjpg7413
@kjpg7413 2 жыл бұрын
That video has a lot of great info, but it also goes best with some caveats: - It teaches a context-less "Perlin-first" mindset for noise, but Perlin has unnatural squareness issues and is just one of many noise algorithms to choose from. Better generally to use Simplex(-type) noise or employ reliable artifact mitigation measures with Perlin. See article titled "The Perlin Problem: Moving Past Square Noise". - It discusses smoothed white noise as being "gradient noise" which isn't entirely accurate. It would still be correct to count smoothness as a requirement for noise, though.
@nathanwfranke
@nathanwfranke 2 жыл бұрын
Is anyone designing or know an open-source modular voxel game/engine in Rust? (Bevy?)
@krystostheoverlord1261
@krystostheoverlord1261 2 жыл бұрын
I love your game development series in rust! you are such a fun character, and it is lovely being able to see a game developer that doesn't focus purely on gameplay or purely on code when it comes to their devlogs, and to go on and explain (some of) the mechanics of how it works! Love it!
@silviodigennaro9953
@silviodigennaro9953 2 жыл бұрын
nah: create an height map and place the biomes on top of it yes: make the terrain dependent by biome TanTan logic
@djbailey1982
@djbailey1982 2 жыл бұрын
Looks very cool so far! That frustration into grinding into eureka moment programming gives you is always so good.
@cartelautomotivo
@cartelautomotivo 2 жыл бұрын
Loving the dedication. And your enthusiasm for Rust got me into learning Rust.
@OffBrandChicken
@OffBrandChicken 2 жыл бұрын
Here's an idea. Instead of trying to interpolate between biomes, each biome (which has its own terrain generation) have biome humidity and temperature ranges that overlap. So when you get values that can be applied to both a desert and grass biome the grass and sand blend nicer, and you can also change the color of the sand/grass based on the humidity. (You essentially create border biomes). You could also start with a smoother height map at first and use elevation as a factor; as atmospheric pressure can also determine a climate. I feel like this would be the best approach but idk how fast it would perform, and how well it would look. But this would also sorta remove biomes as there also wouldnt be a clear cut off. But it would allow for smoother transitions
@DMWatchesYoutube
@DMWatchesYoutube 2 жыл бұрын
your name made me laugh because i was thinking, "Off brand pew-die-pie" when watching this video
@RobLang
@RobLang 2 жыл бұрын
Rust is awesome. I enjoyed your maths explanations, blending is hard - I would probably do a multi-pass method of generation or not include blending at all. Or use voronoi areas where the space between each voronoi is marked as a blend area. Not sure that's simpler than your solution. Keep it coming, sir!
@AntonioNoack
@AntonioNoack 2 жыл бұрын
@8:56 If performance wasn't important, I would have taken every percentage to a certain power. Also the percentage should be inversely proportional to the distance ofc, so use a negative power. This sharpens the transitions. If you have found a nice looking power, just implement it as a stack of multiplications, e.g. x^16 = x2=x*x;x4=x2*x2;x8=x4*x4;x16=x8*x8; Important note: normalize after taking the power! 😄
@Verrisin
@Verrisin 2 жыл бұрын
Any decent compiler will optimize the "power to a constant" - unrolling it manually will at best make the optimizer work harder to notice what you are doing, and reimplement it optimally for given arch. At worst, it will stay suboptimal and less readable. - It might be worth doing in a shader, but even there I doubt it. See num.pow(16) at godbolt with `-C opt-level=3`
@AntonioNoack
@AntonioNoack 2 жыл бұрын
@@Verrisin I tested it for OpenGL once for my RX580 and only the cases 2,3,4,8 were optimized. (cannot post a link here, as YT deletes it then; is my most upvoted answer on StackOverflow)
@Verrisin
@Verrisin 2 жыл бұрын
@@AntonioNoack Interesting. But, yeah, it makes sense the optimizer would be simpler to load shaders faster. (to be fair, I don't even know how to check what shaders get compiled to...)
@soulsmith4787
@soulsmith4787 2 жыл бұрын
Man am I glad I found this channel 3 days ago! This was definitely worth the wait!
@mikael808
@mikael808 2 жыл бұрын
Wow, really good progress! I loved your devlog! Your videos always put me on good mood, thank you so much for making them! Ser fram emot nästa devlog (men ta all den tid du behöver, förstås) :D
@Tantandev
@Tantandev 2 жыл бұрын
Absolutely absolutely!
@seepsoda
@seepsoda Жыл бұрын
this has really opened my eyes quite a bit when it comes to world gen, have always struggled with getting decent biome based world generation, great vid broskie
@AntonioNoack
@AntonioNoack 2 жыл бұрын
@4:42 it's awkward to use soo huge numbers... I prefer first shifting, then masking. E.g. (color & 65280) >> 8 becomes (color >> 8) & 255.
@Tantandev
@Tantandev 2 жыл бұрын
That's so much cleaner, thanks!
@antipainK
@antipainK 2 жыл бұрын
To get rid of hard "edges" while switching the depth maps - simply "add" those depth maps to one "global" depth map. This way it will all blend "fluid"-ly
@mr.capoone5008
@mr.capoone5008 2 жыл бұрын
Your best video in a while! Really enjoyed this one - this is the type of stuff that motivates me to keep working on my own game as a solo dev myself
@Cavouc
@Cavouc 2 жыл бұрын
When doing biome interpolation, i think simply a sigmoid function could do the trick
@kjpg7413
@kjpg7413 2 жыл бұрын
Or more performant: clamped S-curves, e.g. 3t²-2t³ where t is clamped to between 0 and 1. Pass all your weights in, offset and clamped as required, then re-normalize the result so all biomes' weights once again sum to 1.
@OKayD3N
@OKayD3N 2 жыл бұрын
@@kjpg7413 nerd
@AndrewGiacomoPinnical
@AndrewGiacomoPinnical 2 жыл бұрын
I am calling it now, TanTan will be the first Developer to properly publish a fully complete game through Bevy and Rust! I love the biomes logic with temperature and humidity. Id definitely like to see how the math works behind this biome interpolation rule Love your videos man :D
@jorgerauljimenez3307
@jorgerauljimenez3307 2 жыл бұрын
It amazes me the amount of work you put to make each video.
@collinvisser7108
@collinvisser7108 2 жыл бұрын
Maths is hard - awesome progress. Upload on your own pace. You are in control.
@nadpher
@nadpher 2 жыл бұрын
spiritual successor to cube world, nice
@SnackLive
@SnackLive 2 жыл бұрын
Check out Veloren
@arcaneminded
@arcaneminded 2 жыл бұрын
Are you aware that Veloren is written in rust and is also heavily inspired by cube world?
@Tantandev
@Tantandev 2 жыл бұрын
Yes absolutely! I've talked to some of the devs on Veloren, really nice people!
@gJonii
@gJonii 2 жыл бұрын
Why not do normal blending but square all probabilities(or some other exponent in the range of 1.1-10) and then normalize them? Blending would be more extreme, but around edges where multiple biomes apply, you still get roughly equal split, but one biome would start dominating faster after it goes above others. Higher the exponent, the more drastic the change. With say 70% desert, 30% snow, after squaring it's 0.49 desert, 0.9 snow, or 84% desert, 16% snow. By cubing, you'd get 93% desert, 7% snow. So any effect of snow would be dramatically decreasing as the exponent increases
@Dorbellprod
@Dorbellprod 2 жыл бұрын
Nice to see this project return after so long! Very interesting!
@Duranial
@Duranial 2 жыл бұрын
I always doubt what to read or where to start with things like this but i love the way you explain things
@andregusmao3196
@andregusmao3196 2 жыл бұрын
Looking forward for the optimization video and explanation about this different performance in the OS'
@CreativeSteve69
@CreativeSteve69 2 жыл бұрын
yay another devlog from Tantan. Game looks like it's coming along nicely. With each upload its tempting me to challenge myself to do the same thing. Crate a fun simple game with nothing but code but my version would be with python the language I'm learning.
@question_mark
@question_mark 2 жыл бұрын
have you heard of veloren ?
@mariushmedias
@mariushmedias 2 жыл бұрын
Defining terrain by temperature or height seems odd to me.. look at the grand canyon where you can have negative values... also snow can remain on peaks for long periods of time even after weather goes warm. I would have considered adding some parameters like heat/cold accumulated in the soil which would increase or decrease over time depending on temperature/sun/weather... ex rain falling would cool soil a bit, night would cool soil a bit ... during winter peaks with snow would cool significantly so even when temperature goes above 0 degrees the snow would not melt because the soil is cold and gradually warms up over time. I was also thinking small rivers in desert or small lakes in oasis in desert, the water evaporating from lake or river can make the river sides/around lake area cooler, with grass etc
@saloooki2
@saloooki2 2 жыл бұрын
Really cool video, hopefully I'll be able to make something fractionally as awesome one day. Always nice to see another Linux user in the game dev space though 👍
@requity224
@requity224 2 жыл бұрын
For the lag spikes when loading a new chunk; I would implement multi-threaded code. For one thread, you'd would contain normal game processes, and then on different thread, you would make that manage any new chunk loading. This way, your game doesn't suddenly drop in performance upon loading a new chunk.
@Superotation
@Superotation 2 жыл бұрын
Keep it up, love your rust/bevy videos!
@paddev5901
@paddev5901 2 жыл бұрын
Really nice progress so far. I really have to do something with voxels myself eventually :D
@pixel_eyezd3805
@pixel_eyezd3805 2 жыл бұрын
Based on the graph at 5:09, I would make low temp high humidity a mountain instead of two snows.
@Tantandev
@Tantandev 2 жыл бұрын
oh good idea!
@pixel_eyezd3805
@pixel_eyezd3805 2 жыл бұрын
@@Tantandev thx, I also thought that the more jungle (high temp+humidity) surrounds it the more likely that it's a volcano.
@tissuepaper9962
@tissuepaper9962 2 жыл бұрын
@@Tantandev yes, think something like the Gobi desert or the colder parts of the Atacama desert. Mountainous, cold, and dry, not much snow.
@zennyth1866
@zennyth1866 2 жыл бұрын
you should use a space hashmap with a simple voronoi algorithm to determine which biome the block at x, z is in.
@niracaldwell
@niracaldwell 2 жыл бұрын
rust is cool
@zolaire
@zolaire 2 жыл бұрын
Good work Tantan! I can't wait for your next update :D
@blackboxpup
@blackboxpup 2 жыл бұрын
maybe some sort of voronoi-like implementation could help streamline your biome blending process? if you're using 2d noise to instance your biomes, each voronoi cell represents the individual biome regions, and then you get clearly defined borders that you could apply some sort of special interpolation to... theoretically you'd end up with edges, could match on all possibly pairs of neighbors, and craft cases for each that optimize for both neighbors' features? no idea if this is helpful or even makes any sense lmao
@kjpg7413
@kjpg7413 2 жыл бұрын
I use a somewhat related process. I don't directly use Voronoi geometry, though, just the point distribution you might use with Voronoi. Scatter randomly placed points around the world such that they're never spread too far apart (e.g. a jittered grid -- like Voronoi noise usually uses). Sample the biome at each point (no blending yet). Then, for each block (or rather block column) in the world, loop over all sampling points within a certain radius of it. Use a smooth falloff curve e.g. max(0, R²-x²-y²)³ to contribute a weight to the biome it samples, then divide each biome's individual weight by the total weight so they all sum to 1. You can optimize this with various caching and range querying techniques (incl. querying all the points in range of the current chunk being generated).
@WyrdieBeardie
@WyrdieBeardie 2 жыл бұрын
Love vowels, learning Rust... Awesome... no... Perfect!
@nicknorton3055
@nicknorton3055 2 жыл бұрын
Instead of learning how to work with some plugin on a popular engine, you just created your own engine. True Chad
@polrogi
@polrogi 2 жыл бұрын
10:38 hey jdh
@DylanMatthewTurner
@DylanMatthewTurner 2 жыл бұрын
I freaking love Rust too, man
@Finish60
@Finish60 2 жыл бұрын
@10:01 Excuse me but 0.003 is not 3%, it's 0.3% !
@THEDuWolf
@THEDuWolf 2 жыл бұрын
Yes
@guest7329
@guest7329 2 жыл бұрын
hi. do you know about Veloren? it is basically all you wanted
@owowow7509
@owowow7509 2 жыл бұрын
I know one more trick. You can add some high-frequency noise to blend an it can make border nicer. Noise can be pre-baked.
@flaschenzuglp9994
@flaschenzuglp9994 2 жыл бұрын
New Tantan video jeah! 👍
@Mempler
@Mempler 2 жыл бұрын
jdh (eyes) ***makes a tetris os in rust***
@flyingsquirrel3271
@flyingsquirrel3271 2 жыл бұрын
Wow thats some impressve progress! I didn't look into the code but I wonder if you could pregenerate a lot of the calculations needed for biome blending etc. ahead of time so they don't affect FPS that much.
@brianlogan4740
@brianlogan4740 2 жыл бұрын
Man please keep uploading. Your struggle is greater than mine but I've been tearing my hair out doing Qongzi's Minesweeper tut. The repo is different from his tut and I don't want to just git clone it and voila it works. I'm trying to learn Rust. I can print out the values I insert into my mutable HashMap that I pass into the mutating function but after it returns? Hashmap is empty. I've been coming back to this code everyday trying to figure out WTH is going on and why a mutation is passing Rust's checks but it's coming out totally freaking empty. So to see hear about your struggles is super cool man and I appreciate it! Growing pains
@davidmessner110
@davidmessner110 2 жыл бұрын
You coud maby look at the open source game Veloren how they did their bioms.( its also a voxel game made in rust)
@tissuepaper9962
@tissuepaper9962 2 жыл бұрын
Low temp low humidity should be tundra. How can there be snow if the humidity is low? The water comes from someplace.
@oglothenerd
@oglothenerd Жыл бұрын
Bevy, Bevy, Bevy, Bevy!
@Schlecknits
@Schlecknits 2 жыл бұрын
Looks great! Have you seen the game Veloren? They also use a voxel engine in rust and it's open source.
@esben181
@esben181 2 жыл бұрын
Alright I'm gonna make Cube World too, though with more emphasis on food production than adventure
@vipierozan99
@vipierozan99 2 жыл бұрын
fn temperature(&self) -> f32 { -1.0 } He did it bois, he broke thermodynamics
@BlazertronGames
@BlazertronGames 2 жыл бұрын
What happened to the cool chunk loading animation? I thought that was very unique.
@kc3vv
@kc3vv 2 жыл бұрын
Your videos are always a treat!
@timeTegus
@timeTegus 2 жыл бұрын
I would use 3d noise for the booms than the blending would be automatic. With your integration every dessert looks the same and has the same hight.
@waltuh1000
@waltuh1000 2 жыл бұрын
Nice!
@Skeffles
@Skeffles 2 жыл бұрын
Brilliant to see you come back to voxels and working on this game! Hearing about the modularisation of the game was great. Did you actually add any unit tests?
@sharkpyro93
@sharkpyro93 2 жыл бұрын
what's the name of the code color theme that you're using in the video?
@otto_ueue
@otto_ueue 2 жыл бұрын
Your Pop!_OS desktop is kinda dope 😎😎
@Badgero12345
@Badgero12345 2 жыл бұрын
Hahaha it looks really cool...you make me a script guy want to do more in depth code haha. Kubernetes is my life hahaha.
@Alexey_Pe
@Alexey_Pe 2 жыл бұрын
Have you thought about trying Wave Function Collapse for generation? What do you think of it?
@atiedebee1020
@atiedebee1020 2 жыл бұрын
That would depend on what kind of terrain he'd want, because wfc looks very different
@kjpg7413
@kjpg7413 2 жыл бұрын
WFC is a very interesting tool. One of the biggest holdups I would have to applying it to more natural-curvature-based terrain would be its strong preference for grid directions (moreso even than certain noise generators which I covered in another comment). I think translating the idea to randomly scattered points (Poisson, or at least jittered grid with the neighbor relationships recomputed), though, would make for some quite useful and visually appealing results when combined with the right rulesets and pre/post-processing steps.
@scoringdigitsson.5194
@scoringdigitsson.5194 2 жыл бұрын
Stay awesome king!
@isabellolsson8919
@isabellolsson8919 2 жыл бұрын
3:29 Caa ont road
@JZSNooB
@JZSNooB 2 жыл бұрын
inspiring stuff as always
@MedicMainDave
@MedicMainDave 2 жыл бұрын
While you might want to make it look and feel like cube world, please don't be like cube world and actually finish the game, I'm really hyped for your work!
@godspell5316
@godspell5316 2 жыл бұрын
Are you using Bevy's rendering plugins, or is everything done manually by using wgpu and OpenGL?
@Tantandev
@Tantandev 2 жыл бұрын
I'm using bevy's rendering plugin, but I've made most of it from scratch with wgpu. If you want to do more custom rendering things in bevy, you need to write some wgpu code.
@godspell5316
@godspell5316 2 жыл бұрын
@@Tantandev Thanks for the reply!
@davedwad852
@davedwad852 2 жыл бұрын
😅🤔🧐 Crazy, funny, informative and well produced. Great stuff!
@clemdemort9613
@clemdemort9613 2 жыл бұрын
Looks good! Keep it up 👍
@hapashreguiem7460
@hapashreguiem7460 2 жыл бұрын
You can do chunks like minecraft i think it will easier interpolate beetwaen two chunks
@Iigua
@Iigua 2 жыл бұрын
Block Bench 😍
@JMichaelsky
@JMichaelsky 2 жыл бұрын
Good job!
@bencollins2521
@bencollins2521 2 жыл бұрын
Anyone else spot the jdh discord msg at 10:35!!! Two of my favourite creators rly want a Collab!!!!
@godofpro5767
@godofpro5767 2 жыл бұрын
Jdh was mysteriously in the video
@OxAA00
@OxAA00 2 жыл бұрын
Love your vids! I'm trying to build a 2D side scroller with ldtk and bevy currently. :)
@PhosphorusMoscu-code
@PhosphorusMoscu-code 2 жыл бұрын
Awesome video
@gabrielguitiánestrella
@gabrielguitiánestrella 2 жыл бұрын
amazing !!
@GonziHere
@GonziHere 2 жыл бұрын
So, you are refactoring so you won't have to refactor? :D
@wolfdesroyer8711
@wolfdesroyer8711 2 жыл бұрын
rust is more then a coding language, it’s a way of life
@eboatwright_
@eboatwright_ 2 жыл бұрын
Looks awesome! Rust = best programming language
@sudence
@sudence 2 жыл бұрын
this was so epic
@derpizzaboi
@derpizzaboi 2 жыл бұрын
I fucking love rust. Your videos are motivating me even more to use it, but i just don't have ideas to use it for :(
@provelda9447
@provelda9447 2 жыл бұрын
Paul Walker?
@djeanql
@djeanql 2 жыл бұрын
Awesome!
@itsME-dc4vm
@itsME-dc4vm 2 жыл бұрын
nice ;D
@TrixxTraxx
@TrixxTraxx 2 жыл бұрын
When I switched to pop os I saw a 2x increase in fps in Minecraft too 😂👍
@Tresla
@Tresla 2 жыл бұрын
Bicubic interpolation could work
@DaReff
@DaReff 2 жыл бұрын
Don't know nothin about Rust, but if ya ever wanna get into Roblox Lua, i gotchu
@triandot
@triandot 2 жыл бұрын
just an idea that compliments tons of dull work and content creation - try streaming :) you don't have to edit a whole week of footage, you just get angry at maths and it's good entertainment
@philtoa334
@philtoa334 2 жыл бұрын
Nice.
@FelixHdez
@FelixHdez 2 жыл бұрын
Do you read the comments ?
@luukvanoijen7082
@luukvanoijen7082 2 жыл бұрын
poggers ya feel me
@Cal97g
@Cal97g Жыл бұрын
Threads on windows are shitty and take like 10x longer to spin up on windows vs linux. You should create a pool of threads up front and assign work to these threads to handle rendering. I'd bet that's where your slowdown is on windows.
@Cal97g
@Cal97g Жыл бұрын
Oh also, windows sucks.
@monad_tcp
@monad_tcp 2 жыл бұрын
8:54 way easier, its just the second order derivative. through a laplacian and there you are. just kidding, that problem is not easy.
@eboatwright_
@eboatwright_ 2 жыл бұрын
monkee rust brain = make modular code 🐵👍
@nix3l_
@nix3l_ 2 жыл бұрын
when did johnny depp learn rust
@Tantandev
@Tantandev 2 жыл бұрын
My lawyer calls for heresy!
@ZooHair
@ZooHair 2 жыл бұрын
math hurts
@marksmod
@marksmod 2 жыл бұрын
rust is so badass. I... ARGHH!!!
@DrewryPope
@DrewryPope 2 жыл бұрын
buddy tantan, bevy very slow in build. try a release build and it go vroom
Voxel Game Development Is Hard
12:24
Tantan
Рет қаралды 95 М.
Going all in on my Rust Voxel Engine
15:13
Tantan
Рет қаралды 32 М.
Sigma Kid Mistake #funny #sigma
00:17
CRAZY GREAPA
Рет қаралды 30 МЛН
Гениальное изобретение из обычного стаканчика!
00:31
Лютая физика | Олимпиадная физика
Рет қаралды 4,8 МЛН
I remade my voxel game 3 times, this is why
12:11
Tantan
Рет қаралды 123 М.
How Two People Created Gaming’s Most Complex Simulation System
38:54
ThatGuyGlen
Рет қаралды 1,5 МЛН
Voxel Game development - Creatures and Spells
12:01
Tantan
Рет қаралды 37 М.
The Problem With Procedural Generation
17:57
Acerola
Рет қаралды 271 М.
“Mojang Sucks”
11:56
KindofBradAtThis
Рет қаралды 332 М.
Blazingly Fast Greedy Mesher - Voxel Engine Optimizations
23:35
4 Months of Game Programming With My Own Engine
21:30
jdh
Рет қаралды 500 М.
ChatGPT makes Voxel Engine with Rust
12:20
Tantan
Рет қаралды 100 М.
Making my Voxel Engine faster
16:38
Tantan
Рет қаралды 46 М.
Sigma Kid Mistake #funny #sigma
00:17
CRAZY GREAPA
Рет қаралды 30 МЛН