Added walls to see how ants would react. Previous video: • C++ Ants Simulation 1,... Music freepd.com/music/Favorite.mp3
Пікірлер: 66
@ITomocska3 жыл бұрын
Absolutely beautiful, could watch it for hours
@PezzzasWork3 жыл бұрын
Thank you!
@aaaa13393 жыл бұрын
@@PezzzasWork 10 hour version :D
@forabbycookie6993 жыл бұрын
It's a pretty interesting simulation to look at, and i think it could be interesting to add a simulation like that in some sort of games to make mobs act more natutal
@IronDizaster3 жыл бұрын
Probably not the best idea, for a small detail most people would not notice it would most likely be pretty performance heavy
@forabbycookie6993 жыл бұрын
@@IronDizaster i am talking about a game based on that mechanic like some sort of colony management
@alfredfeldt56943 жыл бұрын
would there be a way for the ants to gradually improve the path, it feels like they find one way and then they keep going that way even if it's the wankiest and least efficient way possible
@MrPointness3 жыл бұрын
maybe if they had some secondary set of sensors that they could use it to sense the pheromone a lot further ahead than normal, they could cut corners and slowly turn it into a straighter line
@leolen80292 жыл бұрын
Just add a bit of random turning and its should improve bit by bit
@florencemukagoga8513 Жыл бұрын
@@leolen8029 eeeeeeeeeeeee
@ipotrick66863 жыл бұрын
love this. I just made my own version of this using a grid representing the pheromone instead of discrete points, was lots of fun!
@PezzzasWork3 жыл бұрын
Nice! I am working on a grid version as well in order to ease integration with OpenCL.
@EzraBradford3 жыл бұрын
Huh, I'm suddenly curious how ants do in the presence of a wind or other force moving their trails in particular directions.
@jameschin94283 жыл бұрын
Those ants count their steps
@dmitrym37573 жыл бұрын
Nice! I remember solving travelling salesman problem with ACO algorithm not so while ago, and I was completely excited about it. But my implementation was really poor regarding visual representation.
@PezzzasWork3 жыл бұрын
This kind of algorithm is very interesting. I love the fact that you code something and then you watch it find complex solutions by itself, like genetic algorithms.
@dogedoger26063 жыл бұрын
I'm here because of Sebastian Lague, amazing! Je suis ici grâce à Sebastian Lague, magnifique !
@PezzzasWork3 жыл бұрын
Merci !
@lennartgimm3 жыл бұрын
This looks awesome! One question regarding the pheromone trails: The blue "this way to home" trails are strongest near the homes. I thought one would implement these by each ant leavin the trail while wandering around and the trail gets weaker over time (so the trail is strongest right where the ant is and the longer the trail has been there the weaker it gets). This looks more like the ants have a set amount of pheromone the get from their home and once that's used up, they leave virtually no trail. Same goes for their green "food" trails. Couldn't this create problems for ants who find food let's say triple the distance from what your simulation had? There's a lot of space they'd have to traverse without any guiding trails being so far from home and the food source. Love these walls btw, great addition to the usual simulation :)
@ZeroPlayerGame3 жыл бұрын
I think it's just a lot of ants stinking up the same place and then diverging, thus lowering the spatial density of the pheromone.
@gta5onlineshorts3 жыл бұрын
so beautiful 🐜🐜🐜 simulation
@squirrel16203 жыл бұрын
These paths remind me of lightning. Is it possible to simulate longer paths or a medium with varying viscosity?
@calebcarpenter4213 жыл бұрын
This reminds me a lot of the way a bolt of lightning forms.
@muffels64103 жыл бұрын
You could use The walls as landmasses The food as ports and the ants as boats
@gabrielnoronha27593 жыл бұрын
I wonder how would it behave with multiple colonies and multiple food sources
@ThatBastardOverThere3 жыл бұрын
Really nice! It might be interesting to add 'deadly' areas, which kill any ants that touch them, and leave behind a 'death' pheromone, which ants attempt to avoid? If you made the deadly areas move or change (perhaps to indicate the environment changing through the seasons, or predators roaming around), it'd be interesting to see the paths adapt. Obviously, you'd probably need to make the central nest keep spawning ants when old ones die. The other idea that might be cool is the equivalent of 'rivers' which are deadly, but also when an ant dies on the river, its corpse can be walked on safely by other ants, to make it so that the ants could accidentally make bridges to get to otherwise inaccessible food.
@DogeisCut3 жыл бұрын
Ants are the bogo sort of pathfinding.
@eplexo Жыл бұрын
All these simulations seem to give a feeling of De ja vu from nature. Those ants sure do look like blood vessels.
@SMVK3 жыл бұрын
Visual shape looks like at neuron :’3
@tumble83233 жыл бұрын
for a second I thought this was the powder toy lol
@orderofchaos86803 жыл бұрын
very cool simulation. could you make a tutorial video ?
@dmitrym37573 жыл бұрын
What framework do you use for visualization? Or is it "bare" OpenGL?
@PezzzasWork3 жыл бұрын
I am using SFML (www.sfml-dev.org/) which is very nice lib wrapping OpenGL.
@WillplaysFort3 жыл бұрын
try some thing where they dig to get to the food and also add storage for the dirt they will dig and also make them die overtime and also add a queen and also make different types of food these are all ideas you could put in
@dadutchboy23 жыл бұрын
you sound like someone who just joined a roblox group
@hammielover2253 жыл бұрын
... what makes you think that is all so easy to integrate? Because two things, one: it adds complexity (a lot of it. dirt and digging adds a third dimension, idk why you want a queen because of *two* and different types of food means different types of markers mean they have to tune in the ants behavior more), and two: performance is a thing and data overflow is another. the thing they have is just: Home, food, ants, home markers, and food markers. And the actions can easily be explained with 5 while loops, one of them being true. Now imagine how much code you will add just with the multiple food. Imagine how large and laggy the computer will be with the ants dying and increasing. Please try to think of how hard it might be to do something rather than the award *All I will ever ask for is some interaction between two nests*
@pomponi03 жыл бұрын
I don't wish to discourage you but coding isn't as simple as saying "let's add this and that". First you have to wonder, "what benefit would the program get from implementing this?" Then "is it feasible to program it?", "How much would it impact the render time?". Like, I've done animations where I had to sleep the program for miliseconds because otherwise I wouldn't even see what happened, then I made some Phososhop-like filters (sobel operator, desaturate, posterize) where I could tell it took a big fraction of a second to process a regular sized image. Now, between .01 miliseconds and 100 miliseconds you'll hardly feel a difference even if the latter is 10,000 times slower, but if you start with a render time of 1 minute and multiply it by the same amount it'll end up taking a whole week
@hammielover2253 жыл бұрын
@@pomponi0 agreed
@furankusama3 жыл бұрын
Is this the new sorting algorithm trend?
@onebacon_3 жыл бұрын
Amazing stuff. The roads they take are random, is there any way you could promote a shorter path?
@PezzzasWork3 жыл бұрын
Thank you! I think that making the markers dissipate faster should help.
@onebacon_3 жыл бұрын
@@PezzzasWork i thought about it too, but I think when a road has enough ant on it the disapation speed shouldn't matter because the following ants renew the scent. Maybe the scent could be analog with a "time since seen food" value, longer walking times means a bigger value. If ant follows a trail and sees two markers in front it should be more likely it would choose the smaller value.
@jackeown3 жыл бұрын
What did you use for rendering the animation?
@luckyizzac3 жыл бұрын
....this is a c++ simulation... how the heck do you want to render this and why
@cupobug3 жыл бұрын
Apparently they use SFML
@jackeown3 жыл бұрын
@@luckyizzac I know this is a c++ simulation... By "render", I of course mean "visualize in pixels" and not "create in real life" or anything...SFML answers my question.
@HellsingKnight3 жыл бұрын
Reminds me of The Powder toy
@Northale3 жыл бұрын
How to I, make this simulation? Where do I get it I want to experiment myself
@12-3433 жыл бұрын
What's up with the pinkish patches in the empty areas?
@ronalddiaz9223 жыл бұрын
Donde puedo ver el repositorio?
@jonathankiendrebeogo65233 жыл бұрын
🤩🤩 🤩 🤩 🤩 🤩 Magnifique 😍 😍 😍 😍
@aya-hl5bk3 жыл бұрын
@Pezzza's Work pls add .exe or somthing
@thegreatestegg80453 жыл бұрын
Tutorial ?
@hellishboy60653 жыл бұрын
I GOT THE 1000th like!!!!!
@Somewhere503 жыл бұрын
What game is it?
@zerfdex3 жыл бұрын
with what gui you use?
@PezzzasWork3 жыл бұрын
I am using the SFML
@jasonrieder67643 жыл бұрын
Hi. So I'm actually trying to build my own ant colony stimulation. With my first prototype however I obviously ran into some speed issues. Do you mind telling me if this Vidio is a timelapse or wher you where able to achieve that speed real time. just for a comparison also to see just how far i can push the speed on my simulation. Thanks
@timeiskey13 жыл бұрын
post code
@__________________________45973 жыл бұрын
Pay For It
@SunnySzetoSz20003 жыл бұрын
they don't improve the path
@serbianspaceforce68733 жыл бұрын
real ants don't either
@Mistarbist19843 жыл бұрын
THIS VIDEO IS SPONSORED BY RAID SHADOW LEGENDS
@breeckthon51443 жыл бұрын
Hello is there a way to Download it and creating my own worlds. I Would even buy it
@PezzzasWork3 жыл бұрын
It's all free and you can download the new version in the pinned comment of this video kzbin.info/www/bejne/m561iXWoaq-ppbs :)
@breeckthon51443 жыл бұрын
@@PezzzasWork Thanks 😊 That Helps me a lot. are you planning to make a full game or Programm of it? Because it is a bit Complicated to get it Running :(