No video

I Made a Factory Game in 20 HOURS!

  Рет қаралды 127,652

Code Monkey

Code Monkey

Күн бұрын

Пікірлер: 353
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
🌍 Get the Game Courses Bundle 3x1! game.courses/code-monkey-bundle/ (Includes Steam Keys for my games as a FREE bonus!) 💬 Factory Automation Game! I've been working on this for a month, did you join me on the Livestream? Make sure you don't miss whatever mini-game I work on next, hit the bell icon! 👍 You can play the game on the Steam App or Download the Project Files, hope you like it! 🌐 Have you found the videos Helpful and Valuable? ❤️ Get my Courses unitycodemonkey.com/courses or my Steam Games 🎮 unitycodemonkey.com/gamebundle
@syedsadiq8631
@syedsadiq8631 3 жыл бұрын
Make a another mini mobile ads game plz code monkey
@catafest-work
@catafest-work 2 жыл бұрын
This game reminds me of the old Dune game. it would have been interesting to add the hidden resources and use leaflets to find enemies to destroy them and you to defend them. My opinion is that you can use this idea to simulate a computer - it could be used in the learning process for schoolchildren and you could put it online. In the end, the work done and the number of hours depends a lot on what you have.
@gfujigo
@gfujigo 2 жыл бұрын
Do you have a tutorial of how to make this game from scratch? I would love to take it. Also, in the background you show a top down game on Steam that looks really good. It’s the game in the background at 0:37. Do you have a tutorial of how to make that from scratch? I would love to take both the factory tutorial and the tutorial of that game in Steam. Thanks!
@CodeMonkeyUnity
@CodeMonkeyUnity 2 жыл бұрын
@@gfujigo Most of the videos on the Grid system playlist are step by step tutorials which is what this game is based on kzfaq.info/sun/PLzDRvYVwl53uhO8yhqxcyjDImRjO9W722 That's the Wash your Hands game kzfaq.info/get/bejne/p5-gmJCorZ3Jimw.html
@MeariBamu
@MeariBamu Жыл бұрын
There's no game that i want to play, it basic on factoric but the game purpose isn't my thought because it not enough like a chip layout generation program, that can held out put lot of different size of retangle in to a one small square with high density, that can make a little change and regenrate, that to let player like the chip designer, more density and look awesome and give a written line to add some parts more without redo move parts all times hand by hand
@BrokenPuzzle03
@BrokenPuzzle03 3 жыл бұрын
The amount of tutorials you have should be kept in a backup website in case youtube ever goes down. Thank you for everything you have taught.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Thanks! I'm glad the videos are helpful!
@eclipset.9683
@eclipset.9683 2 жыл бұрын
True, super helpful stuff. I'm sure he's got them stored locally too, so it won't lost forever. (I made that mistake with some stuff published to a website, they had exclusive rights for publishing, so I didn't have it hosted on my own site, and it was only stored through their editor. RIP).
@NikoBellicXDS
@NikoBellicXDS 3 жыл бұрын
Next video: *"I Made a GTA VI clone in 1 WEEK!"* This channel always surprises me in a good way lol
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That would be quite the challenge!
@emoneydev8684
@emoneydev8684 3 жыл бұрын
hmmmmmm
@sparecreeper1580
@sparecreeper1580 3 жыл бұрын
That would be gta 6 I = 1 II = 2 III = 3 IV = 4 V = 5 VI = 6 VII = 7 VIII = 8 IX = 9 X =10
@starbruhz
@starbruhz 2 жыл бұрын
@@sparecreeper1580 yeah we know, thats the point
@sparecreeper1580
@sparecreeper1580 2 жыл бұрын
@@starbruhz the comment says gta 6 clone
@DuctTapeJake
@DuctTapeJake 3 жыл бұрын
Me: Struggling for hours to instantiate an object and populate one of it's variables Code Monkey: So I'll just make a 3D Factorio template in a couple of days...
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
It's the power of experience and writing clean code!
@DuctTapeJake
@DuctTapeJake 3 жыл бұрын
@@CodeMonkeyUnity and constant practise. I'm finding myself saying "I knew how to do this 4 years ago" pretty often after taking a bit of a break from gamedev. Luckily your videos are here to my rescue.
@AustiBomb33
@AustiBomb33 Жыл бұрын
Survivor Squad, Game Corp DX, Blueprint Tycoon, Ninja Tycoon, and Battle Royale Tycoon. I bought these 5 of your games before going to University for Computer Science. Now that I'm finishing my degree and making my foray into Game Development, you've been the most helpful person on the planet. Thank you, for your great games, and your incredible teaching!
@CodeMonkeyUnity
@CodeMonkeyUnity Жыл бұрын
Oh nice! I hope you enjoyed the games! Thanks!
@VelvaryGames
@VelvaryGames 3 жыл бұрын
This is way too impressive for those few hours of work. Just amazing. And I love the tilt shift effect. Makes the look really great.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
When in doubt, add depth of field! Always looks great!
@bomdiajj
@bomdiajj 3 жыл бұрын
me: nice, managed to make a prototype of the game I'm making in 1 week code monkey:
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Don't get discouraged, everyone walks their own path, just keep on being better than you were a month ago!
@valtrax5871
@valtrax5871 3 жыл бұрын
What a CHAD
@bomdiajj
@bomdiajj 3 жыл бұрын
@@CodeMonkeyUnity I absolutely won't!! Watching your videos pushes me forward and thanks to people like you, today I know a lot more than I did a month ago.
@noctisocculta4820
@noctisocculta4820 3 жыл бұрын
Cool dude, what kind of game did you make?
@FocusGTOfficial
@FocusGTOfficial 3 жыл бұрын
Next Video : "I Made a Car Simulator Mobile Game in 2 Days!" This channel always surprises me in a good way lol
@rrahll
@rrahll 3 жыл бұрын
16 hours? Genius! The game already looks interesting... Thanks dude! Really cool content!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
It's the power of experience + reusing code!
@GonziHere
@GonziHere 3 жыл бұрын
It's a great overview of how Factorio might be working, or maybe how to do something like that in a different genre (RPG game with some small homebase), but I still want to point out that the WHOLE selling point of Factorio is its scale.
@page0809
@page0809 3 жыл бұрын
Dude, this was super cool!! Well done man! And yeah, this background music is a nice change, sound very good! Keep it!!
@ceredev
@ceredev 3 жыл бұрын
Code monkey in 16 hours: I made a Factory Game Me in 4 hours: ah, that's how finally a cube moves
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Experience is a very powerful thing!
@helloq5051
@helloq5051 3 жыл бұрын
took me 3 months to get a cube moving. uwu
@SteveJstone
@SteveJstone 3 жыл бұрын
I've been making a factory game like this and making devlogs. I'm pretty sure I'm well over 20 hours by now... It's super inspiring watching you work though :)
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
It's looking great, I really like the visual style, best of luck on your journey!
@SteveJstone
@SteveJstone 3 жыл бұрын
@@CodeMonkeyUnity Thanks!
@BrokenPuzzle03
@BrokenPuzzle03 3 жыл бұрын
The way you explain how you made your game can basically amount for everything I've learned in unity for 2 years. Including stuff I haven't learned yet.
@BloodyMobile
@BloodyMobile 3 жыл бұрын
When I started watching this I already had the impression "this guy really knows what he's doing", then you mentioned "...in my game Blueprint Tycoon" and I went "ah, now I know why, he already made a well done game, no wonder then" xD
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Yup already got quite a bit of experience although this was my first Factory game, it came out great!
@blackspear7257
@blackspear7257 3 жыл бұрын
Looks great, Pleasing interface! Just watching the gameplay feels so good!🔥 Hope you expand this to a big game!
@Nickerek
@Nickerek 3 жыл бұрын
I think some people would like to watch full uncut (even if not commented) project creation, like this factory game project. At least I would be interested :D
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That would be interesting, perhaps when I make a second channel I'll experiment with videos like that.
@donkeymonkey4435
@donkeymonkey4435 3 жыл бұрын
Thanks man , for this Amazing video!! Keep Rocking
@r4z0rbl4de
@r4z0rbl4de 4 ай бұрын
Your videos are invaluable. I have learnt so much. I highly recommend your courses whenever someone asks me where to start
@CodeMonkeyUnity
@CodeMonkeyUnity 4 ай бұрын
I'm glad to hear that! Best of luck with your learning journey!
@branidev
@branidev 3 жыл бұрын
You are the most bad-ass Dev you always surprise us what you can do! Such a well done game + edited video ;)
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Thanks!
@MatrixQ
@MatrixQ 3 жыл бұрын
Wait, Blueprint Tycoon was one of yours? It's been a while since I've got and played it, long before I got to know your KZfaq channel, but I remember having a lot of fun playing it. Nice.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That's awesome to hear! Thanks!
@MarushiaDark316
@MarushiaDark316 3 жыл бұрын
DOTS project: fluid particles on conveyor belts. Otherwise known as plumbing simulator. :D
@ollllj
@ollllj 3 жыл бұрын
for proper FIFO-traffic-jams, you split belts into [lines] (strings of belts/inserters, without merging/splitting branches). your runtime code only deals in lines, lists of the same moving items, these are belts (exclusive-)OR inserters of the same speed. Only your editor deals in elements of lines, that ultimately end up editing lines. A line ends where multiple things output to the same spot. A line ends, where 2 inserters grab from the same spot, OR where 1 inserter grabs from a belt. A line ends, when its string of linked belts/inserters loops back to itself. above 2 conditions may change with every placed/removed item. you may want to also artificially split lines geographically by world-chunks , so that every chunk of game world knows what likes it contains, and 1 line is fully contained in a chunk. this lets us modify and LOD lines faster. adding a bellt (or many items) may split a line in 2 lines. removing a belt may split a line in 2 lines. removing a bellt (or many items) may merge 2 lines into 1 line. (1 location changes, to only have 1 inoput, identical to its output) same for changing the speed of an item. each line starting point queues/priorizes items from its inputs. each line is a FIFO queue, simple to code. its output may be "full", which may push the voids to the inout of its queue, where they then may get filled. a "line is full" flag may also speed up code as a bounding condition.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Yup if I were to expand upon this then that is definitely the approach to take, it would improve performance massively.
@VesuviasV
@VesuviasV 3 жыл бұрын
this is cool, thanks for the write up. I was pondering how DSP did some of their processing. Apparently they do most of this in a compute shader which allows them to process whole planets of factories in real time. That seems doable. I stumbled when I imagined how they might accomplish sushi belts (belts with a mixed set of items). I was hoping the whole thing was compressible (IE I could process 10 ticks without processing 1 tick at a time) but the sushi belts pretty much squashed that thinking, I really couldn't come up with a solution that did not require every tick processing. But again if you're doing in a compute shader you have tons of computational room to do a huge amount of factories. This topic is so fascinating. If anyone has any online white papers on the subject or more discussion how to do this well I would love to see it.
@roshanthapa1297
@roshanthapa1297 3 жыл бұрын
That's awesome 😍. I couldn't be around in game dev for a while but it's absolutely insane to be back 🔥
@sairabanokazmi1150
@sairabanokazmi1150 3 жыл бұрын
Compared to other gamedev KZfaq channels, you focus more on teaching the viewer rather than comedy, great job!
@adambamford5894
@adambamford5894 3 жыл бұрын
You explain everything you do amazingly! I’m trying to make a third person person pvp game in bolt and your Udemy course is an absolute godsend.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Thanks! Best of luck on your learning journey!
@kamillatocha
@kamillatocha 2 жыл бұрын
thank you for this video and project files will spend some time learning from that :)
@MrMattyMoses
@MrMattyMoses Жыл бұрын
12:50 🥺 You're breaking my heart 💔 I think this is an excellent series! It would be interesting to see "where are they now" for these games after your own videos.
@bencusb
@bencusb 3 жыл бұрын
Don't know if anyone asked this but wouldn't implementing a search tree system help with the belts?
@TinyDeskEngineer
@TinyDeskEngineer 2 жыл бұрын
I've been considering trying something like this for a while now with the main obstacle I've noticed being that I have no idea how to make conveyors.
@apollolux
@apollolux 3 жыл бұрын
OH! Somehow until now I've been completely oblivious to the fact that Blueprint Tycoon is by you and I kept wondering why I occasionally get your vids recommended.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
I hope you enjoyed it!
@Ferenc-Racz
@Ferenc-Racz 3 жыл бұрын
You are awsome! Thanx for sharing your experiences with us! :)
@leventebalog8696
@leventebalog8696 3 жыл бұрын
Always when you upload a new video like this when you make a game I always try to make it by myself before watching the video and then watch your video and compare them and I always find things what you did in a much optimized and simpler way than me and I learnt a lot of things from you like this. Thanks for the awesome videos, they are really helpful. Sorry for grammar mistakes I'm hungarian and I'm just learning english. And now if I'm think about it, this is a nice way to learn english too because you are speak english.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Your English is great! Yup watching videos and writing comments is an excellent way to learn, for me I learned English pretty much by watching Cartoon Network and writing code!
@leventebalog8696
@leventebalog8696 3 жыл бұрын
Wow really?
@leventebalog8696
@leventebalog8696 3 жыл бұрын
I learnt a lot when I learnt coding(this is like a year) because the whole website(w3schools.com) is engish
@souporwormgaming
@souporwormgaming 3 жыл бұрын
Cool video! I'm getting into unity and I think that making a game like this (at some point) seems like a fun challenge.
@cutedogo8647
@cutedogo8647 3 жыл бұрын
Wow this is fantastic! I have recently discovered ypur channel and i even have tried making my own game, but it is much harder than i have expected. I know C# quite well but even with that i feel lack in some areas. What are some good videos of yours to start understanding how to write code for unity and how to solve common problems? Thank you for your work, you are a true legend!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
For the absolute basics you can start here kzfaq.info/get/bejne/e5xxZ7qn2KrJfHk.html Then a refresher on C# basics here kzfaq.info/get/bejne/f6yRrLSa1K2bYXU.html After that just browse for a simple video that interests you and try to follow that, maybe the video on Flappy Bird which takes the game from start to finish. Best of luck!
@switbitz
@switbitz 3 жыл бұрын
this feels like playing a minecraft tech modpack
@personmuc943
@personmuc943 3 жыл бұрын
Great job man! 20 hours isn't enough for me to solve my pathfinding errors 😂
@Valast
@Valast Жыл бұрын
Yk what i imagine a good factory game to look like too? Having to do multiple jobs like maintenance, packaging and other stuff
@devbre
@devbre 2 жыл бұрын
This is a great video. I am playing a bit with the code and I can see that the safety break to 1000 iterations, limits the size of how big the belt system can get over time. I wonder if there is a better way to check for loops in the belts (which is not wrong in principle) without incurring in an actual infinite loop in the code. Do you have any suggestions on this matter?
@firebiscuitgaming7624
@firebiscuitgaming7624 3 жыл бұрын
Really inspiring video. I'm amazed at how fast you put this together!
@nekidev
@nekidev 3 жыл бұрын
I just cannot wait to play it. Seems really interesting as I like thise type of games
@algs5483
@algs5483 3 жыл бұрын
Awesome work, Hugo!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Thanks!
@Daddelpalm
@Daddelpalm 3 жыл бұрын
You are an absolute beast of a game developer Code Monkey, good job!
@ZiplawDev
@ZiplawDev 3 жыл бұрын
I remember running into a similar problem to yours while trying to recreate baba is you's block push system, and I did it in a different manner to you, but this seems pretty smart :) (btw, it'd be cool if you recreated those sorts of systems so that it's scalable and cool, maybe for a series or something)
@foamtoaster9742
@foamtoaster9742 3 жыл бұрын
how did you do it ?
@ZiplawDev
@ZiplawDev 3 жыл бұрын
@@foamtoaster9742 I used a recursive function that checked if the object next to itself had a Push script attached, then ran the function on that. It checked every object in the line and then executed if it found nothing. I think mine is better for that situation and his is better for this one tho :)
@kingbling7571
@kingbling7571 3 жыл бұрын
This is amazing like always. It bet it feels just good to be able to create something that you visualize with skills you inherited over the years aka programming/game designing in this case and this result :D I have one question btw, I can some depth of field and blurry corners, what settings did you tweak in post processing to achieve it and that level of Polish at the end?
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Yup being able to create any game genre I can think of is a very awesome thing! For the depth of field, it's just making it a small non-blurred section so it kind of gives it a tilt shift sort of look. You can download the project files to inspect the exact settings.
@maarten1012TTT
@maarten1012TTT 3 жыл бұрын
It would be very cool to expand this by making the belt system with DOTS!
@ignatiusreilly8280
@ignatiusreilly8280 3 жыл бұрын
Can't wait for a course on this, sped up x1000.
@Rushhourz0
@Rushhourz0 3 жыл бұрын
Holy shit. In this video you really sound like those vacuum salesmen, that come to your house. And he seems he wants to really sell you that extra insurance and that vacuum key accessory aswell.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
What?
@Rushhourz0
@Rushhourz0 3 жыл бұрын
@@CodeMonkeyUnity To elaborate: I've watched a lot of your videos, but in this one in particular you seem to mention the courses and all that stuff more frequently than usual. Not that i dislike the courses, especially since i also own a package with Jason in it and I can also really recommend him. I hope you are not taking it offensively, really like your videos and learned a lot of stuff from you aswell (Unity DOTS for example). Just wanted to mention it, and keep up the good work :D
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
@@Rushhourz0 Yeah no problem I'm not taking any offense, just confused. The video does feature a standard 60s sponsor spot, so the difference is that most of my videos don't have a sponsor spot and this one does.
@chrisxxx4714
@chrisxxx4714 3 жыл бұрын
i would like soo much to see a complete course, maybe on udemy, on a factory-like game like this, where to learn how to code complex conveyor belts systems!!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
I'd love to do it but courses take a ton of time so not sure when. In the mean time you can download the project files and inspect the source code to see how everything works
@SpaceDump
@SpaceDump 3 жыл бұрын
Sweet, I'm impressed. I would love to be able to do stuff like this, however lacking imagination is really crappy. :D
@nekidev
@nekidev 3 жыл бұрын
I am a really creative person but I cannot make a 3d cube by myself
@mementomori7160
@mementomori7160 2 жыл бұрын
I'm so glad you made this video, I'm not really playing these type of games, but one meme started going around in a certain community and I want to join and making a meme factory game will be perfect. Why factory game? Because the meme is one gif that's evolving all the time, and someone made it so you can spam it on discord and it looks like a vertical conveyor belt, is it a stupid idea? Yes, but I can try this genre at least
@OverAndOverAndOver
@OverAndOverAndOver 3 жыл бұрын
This is awesome! How would you be able to make buildings cost a specific amount on place? Like a conveyor belt costs 5 money, whereas an assembler will cost 10
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
It's pretty simple to add an extra field to the Scriptable Object and implement a basic ResourceManager script
@OverAndOverAndOver
@OverAndOverAndOver 3 жыл бұрын
@@CodeMonkeyUnity How would this happen? Like, how would I reference the cost in the Scriptable Object within the Resource Manager, and make it subtract the money before spawning?
@slygamer01
@slygamer01 3 жыл бұрын
Unity's DOTS is a solution looking for a problem, but this type of game is one of those few problems that DOTS would be useful for.
@craftercis
@craftercis 3 жыл бұрын
Every time I watch your video's I get so much motivation for my own projects!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That's great to hear! Keep at it!
@eltick7351
@eltick7351 3 жыл бұрын
4:12 sounds like Yoshi lmao xD
@farvardinmainyu1961
@farvardinmainyu1961 3 жыл бұрын
Great work ! Thank you Code Monkey !
@AJ213Probably
@AJ213Probably 3 жыл бұрын
You would think a game can't make a performant factory game in unity, but Dyson Sphere Program exists. Fortresscraft Evolved also exists, but that game isn't as performant late game. It could be though if it did some multithreading though
@ollllj
@ollllj 3 жыл бұрын
i was wondering when you post anything about this after your live stream of it.
@chrisjulch561
@chrisjulch561 3 жыл бұрын
Is the conveyor belt class derived from monobehaviour? and are they directly attached to the object in the scene? The problem I always have is, that each object has its own script that’s constantly being updated which causes massive performance problems after 60-80 belts in the scene each updating an items position. I know it’s probably better to only call an update on an event like if an item appears on the belt or is moved to the next but, the only way I know how to check for those events are with collider or bounds which again is performance heavy at least on my pc. I’ve tried implementing a system in ecs but god that was a headache. I watched your section on the belt system and it’s perfect for what I’m trying to do, I’m just curious if the conveyor class is pure data or a mono behavior. Any help or thoughts would be awesome. Thanks
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
The Belt itself doesn't have an Update logic. The moving logic is on the Belt System which tells the belts to move whatever is on them and the Belt System itself only runs on the Time Tick System. So the belt logic updates 5 times per second, not every frame. The Time Tick system is super useful and something I've used in most of my games, I covered it in a video quite a while ago kzfaq.info/get/bejne/hKymoMmgt9TFoo0.html
@chrisjulch561
@chrisjulch561 3 жыл бұрын
@@CodeMonkeyUnity Ah I get the drift now, thanks for that, completely changed my thought process on the system I have. I was researching other conveyor belt systems in other games and I read on the factorio forum that they use a chain system, like every belt is part of a chain that has a length. I've been trying to understand why they do that. I can see how having a chain with a series of positions makes it easier to determine the items path and directions on the belt but my question is does a chain really improve performance or not? I have been trying to keep things as simple as possible yet not to a point where I'm avoiding future problems. lol I know I ask allot of questions but I am trying to soak up as much knowledge about this subject as possible, especially from the person that who taught me how to code allot of things. Having another programmer to talk too helps me understand concepts and Theory's allot better.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
@@chrisjulch561 Yes having everything organized into chains/paths and only doing heavy logic on the front is the way to go, it greatly improves performance since you don't need to worry about 90% of belts, just move them automatically.
@robosergTV
@robosergTV 3 жыл бұрын
20 hours? You are a wizard, nice job.
@jacobbetancourt5602
@jacobbetancourt5602 3 жыл бұрын
while watching this video, i thought of a game idea like factorio in which there is infinite progression with procedurally generated ore types/names, and compact machines within compact machines. hopefully nobody beats me to making this game a reality.
@jonathanmoothart8038
@jonathanmoothart8038 3 жыл бұрын
dude this is nuts! It looks great!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Thanks!
@EdgedPixie
@EdgedPixie 3 жыл бұрын
Yoraiz0r. This man is casually supported by the lead sprite artist on Terraria. *What.*
@panemetcircenses1367
@panemetcircenses1367 3 жыл бұрын
Hey Code Monkey, I really appreciate your videos and currently even going through your udemy tutorials. At this point I have a question... For some environments a hex-based approach is slightly better, because of having the same distance from mid to mid of a hex in all six directions. Can you perhaps take a vid with creating a hex-based grid system?
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That is something I'd like to cover but don't know when, I'm pretty sure you can reuse the same underlying Grid System and just do some tricky math to find how a world position relates to a Hexagonal grid position.
@panemetcircenses1367
@panemetcircenses1367 3 жыл бұрын
@@CodeMonkeyUnity Allright, thanks. I will wrap my head around this. ;-)
@pacmanrocks94
@pacmanrocks94 2 жыл бұрын
would you consider selling a course specifically on this type of game? that would be awesome
@python.programmer5567
@python.programmer5567 3 жыл бұрын
I want to be a professional game programmer for a big game so these videos are a blessing.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Keep at it! It's all about experience!
@ShyftyBubba
@ShyftyBubba 2 жыл бұрын
Lol it’s crazy how many “bugs” happen when a game is so new
@Pookzob
@Pookzob 3 жыл бұрын
Not sure if it's asked but you skimmed over "drew some moving arrows for belts", how did you do that? It really looks like an arrow is spawned and travels along the belt. Well done!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
The texture is just a single arrow pointing right on a dark grey background with the texture set to repeat. The "animation" is handled in the shader, just connecting the Time node to the Tilling and Offset node. All the belts use the same texture and shader at the same speed so it all connects perfectly
@Pookzob
@Pookzob 3 жыл бұрын
@@CodeMonkeyUnity I was thinking it was something along that line. Very well executed! Also love how you show how all your experience adds up as this is very much the case in all programming (as long as you keep learning and challenging yourself). It's so direct with your small game modules which gets that point across very effectively and visually!
@deadly_artist
@deadly_artist 3 жыл бұрын
Couldn't you make a simple "bool stop = false" variable on every item on an item belt that switches to true whenever the item in front stops or there is no belt in front of it, instead of making that overly complicated path define, merge and split system? (Probably also more performant) Just a random thought. EDIT: After finishing the video, I think even better would be to not have the objects move at all by default. Instead, adjacent objects can request from another object to move to towards them. A belt would move the object behind it towards it with a priority of e.g. 1, while the assembler would move the item towards it with a priority of 10. That would remove the need for extractors/inserters. That would even allow extraction from building to storage, and every object could have its own speed. (This could also be combined with stop system from above).
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That still has the same problem which depends on the order of your testing. If you test the second item, it wont move because of the one in front has an item, the items would only move if there's a gap between them. Again having the belt request an item still leads to the same problem on the order that you test. No matter what you do you need to know the order of the paths so you can ensure you move the items front to back. The issue is always with the order that you test.
@deadly_artist
@deadly_artist 3 жыл бұрын
Code Monkey Nope. Difficult to explain but it works. Have IsStopped function run on an item. It does not matter with which item you start. The IsStopped function calls the IsStopped function of the next item, which calls the same function of the next until either the next item equals the first item or there is no next item or the next item’s stop bool has been set to a value this turn. Then you can set the stop bool for all checked items to the same value.
@deadly_artist
@deadly_artist 3 жыл бұрын
This requires resetting the stop bool to default after every frame, but in the past couple weeks I’ve been doing that more and more for variables modified by script.
@uhavemooface
@uhavemooface 2 жыл бұрын
New Subscriber here. I love the look of this game and I would love to be able to make a game like this but my brain doesn't work like that. Thanks for showing us this game.
@magostinhojr
@magostinhojr 3 жыл бұрын
Hey Code Monkey! How are you doing? Are you planning to create some content explaining how to implement the conveyour belt system used on this video?! Thank you!
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
Probably not unless I expand upon this when I get back into DOTS But you can download the project files and see all the source code
@magostinhojr
@magostinhojr 3 жыл бұрын
@@CodeMonkeyUnity
@devbre
@devbre Жыл бұрын
I was wondering how to achieve a smoother movement of the items on the belt. At the moment looks like they get pushed from one belt item to another instead. Any suggestion?
@oskarsajdak351
@oskarsajdak351 2 жыл бұрын
great video, i am starting to like this game
@destroyonload3444
@destroyonload3444 3 жыл бұрын
Ah I gotta dig up some old code I wrote that works well for the belts but used for something else entirely. I honestly forgot what the implementation was. Lol. Did you post up on GitHub?
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
There's a link in the description
@wojciechgrysko1575
@wojciechgrysko1575 Жыл бұрын
Hey, as always amazing work! Can you tell me how to place the gold nodes (resources) in editor? In my game i would like to have a hidden resources on grid wchich will be loaded into game. Thanks in advance.
@83MrLeo
@83MrLeo 3 жыл бұрын
hi, i love your job. I have a question: is it possible to adapt the grid system to a terrain with relief?
@jbeaudoin11
@jbeaudoin11 3 жыл бұрын
Saw your post that you were working on a factory game tutorial. I was waiting on a belt system with ecs or another solution of per node processing. Doesn't look like i'll find this here :/ If we look at Dyson Sphere program, the game's belt looks pretty optimized. I really wonder how they made it.
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
When I finally find the time to get back into DOTS I will definitely be experimenting with that, I will see how far DOTS can be pushed.
@baac9150
@baac9150 3 жыл бұрын
Thank you so much for this tutorial. Its pretty cool. One question tho, I downloaded the project and the utils from your website. But I cant seem to find a license file. Is there a license for them (the code specifically) ?
@baac9150
@baac9150 3 жыл бұрын
Just going to bump this here, I dont know if you saw this comment :P Sorry for bothering you Code Monkey, I just want to be sure how to credit you.
@tsalVlog
@tsalVlog 3 жыл бұрын
Any chance we could get a macOS build of the Code Monkey app? I do all of my development work (incl. Unity) on a Mac. If it's a matter of needing help to port things, I can potentially do that. :)
@craftlofer9974
@craftlofer9974 2 жыл бұрын
im trying to make a factory game too expect there is a player that you can control and you have to use the materials to build defenses to defend yourself from the enemies
@sephypantsu
@sephypantsu 2 жыл бұрын
Making a similar game right now and is wondering which is a more effective design. Putting belt logic on belt or belt logic on item? I'm hoping to be able to extend it with multiple item per belt & multiple belt speed later
@CodeMonkeyUnity
@CodeMonkeyUnity 2 жыл бұрын
Putting that logic on the belt is likely to be more performant, better to handle a few dozen belts than thousands of items
@guridoraccoon6375
@guridoraccoon6375 3 жыл бұрын
you keep me motivated to develop games 🔥
@Tom-jo3lb
@Tom-jo3lb 3 жыл бұрын
Respect!
@rathodpragnesh3738
@rathodpragnesh3738 3 жыл бұрын
Looks awesome
@zildeos9858
@zildeos9858 3 жыл бұрын
This is so inspiring guess im picking up one of my old projects
@medatho-beadc3745
@medatho-beadc3745 3 жыл бұрын
Thanks a ton! Any chance of a 2D version of the prototype? I found it very helpful having the 2D classes on the grid building system. Been working through trying to convert so I can keep plugging away at it if necessary. Just verifying I'm not wasting my time :)
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
You can definitely do that, I don't think any part of the logic even touches the meshes so just swapping the underlying grid should work with a few tweaks.
@HugoMesquitaO
@HugoMesquitaO 3 жыл бұрын
do you have a video explaining how to put this blue grid? is it a shader? a visual grid(using your generic grid)?
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
That's using the Tilemap made in this video kzfaq.info/get/bejne/napleLSq2Z26gJ8.html
@atso9453
@atso9453 3 жыл бұрын
13:35 How did you make that blue grid layer that appears when you are about to build something showing where you can build and where you cannot? Thank you
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
It's my grid based tilemap which I covered here kzfaq.info/get/bejne/napleLSq2Z26gJ8.html
@atso9453
@atso9453 3 жыл бұрын
@@CodeMonkeyUnity ouuu thank you :D
@thatisjake
@thatisjake 2 жыл бұрын
Couldnt you just do the belt system like this? test for item in belt ahead if no item, then move to that belt if there is item, check that belt to move
@KalponicGames
@KalponicGames 3 жыл бұрын
You are talented individual. I am really glad that I found your and your channel. How to meet you in person some day.
@mlucifer79
@mlucifer79 2 жыл бұрын
you always best , I have a question how can move an object to new position ? for example user want's to move smelter to new place or wants to change his map design
@CodeMonkeyUnity
@CodeMonkeyUnity 2 жыл бұрын
You would demolish from the current position and add it to the new position, just need to be careful with buildings that occupy multiple positions
@mlucifer79
@mlucifer79 2 жыл бұрын
@@CodeMonkeyUnity thanks
@gioigaming445
@gioigaming445 10 ай бұрын
I'm very interested in the belt system, I really haven't found a good belt system anywhere else, could you maybe give us a tutorial or the whole script? I'd really like to understand how it works
@CodeMonkeyUnity
@CodeMonkeyUnity 10 ай бұрын
You can download the project files linked in the description but this belt system is not performant at all, it's extremely basic, for something performant you need a ton of clever tweaks and possibly smart usage of the Job System
@Paum-RSR
@Paum-RSR 3 жыл бұрын
Mindustry 3D!!
@sharoncastillo2411
@sharoncastillo2411 3 жыл бұрын
Just add terrain, turrets and enemies
@IceMetalPunk
@IceMetalPunk 3 жыл бұрын
And once you have computers being made... you're done? I think the next update to this game should be some way to use the things you're creating towards some kind of progress :)
@lucasahumada6913
@lucasahumada6913 3 жыл бұрын
You could even say,it’s **satisfactory**
@CharlesSeat
@CharlesSeat 2 жыл бұрын
Hey Code Monkey, do you have a video I can look at the explains how the buttons work in this game? I see in the project files that they are all using the pfBuildingButton prefab and the Button_UI script. What I don't understand is how the script knows which resource to pick. For example, when I click the conveyor belt button how does the button_UI script know that I want to build a conveyor belt instead of a grabber?
@CodeMonkeyUnity
@CodeMonkeyUnity 2 жыл бұрын
It's been a very long time since I made this so I don't remember exactly but I probably did it like I always do, there's a UI script which cycles through all the object types and creates a button for each. So the buttons are created dynamically when the game starts, not in the editor.
@dripyman6146
@dripyman6146 3 жыл бұрын
Haha from the thumbnail it looked like you ment you made one single factory in 20 hours lol
@AMIR-oh1ht
@AMIR-oh1ht 3 жыл бұрын
Code monkey basically is a normal version of dani
@HexZwei
@HexZwei 3 жыл бұрын
Which of your tutorials do I have to start with in order to understand this whole Gridbase system from start?
@CodeMonkeyUnity
@CodeMonkeyUnity 3 жыл бұрын
They're all on this playlist kzfaq.info/sun/PLzDRvYVwl53uhO8yhqxcyjDImRjO9W722
@HexZwei
@HexZwei 3 жыл бұрын
@@CodeMonkeyUnity great.. thank you... :)
@cheesebuilding
@cheesebuilding Жыл бұрын
Make a course on this now! Thanks
@CodeMonkeyUnity
@CodeMonkeyUnity Жыл бұрын
I'd love to! Just need to find the time!
They turned MATH into a factory game...
21:34
Real Civil Engineer
Рет қаралды 1,3 МЛН
ОБЯЗАТЕЛЬНО СОВЕРШАЙТЕ ДОБРО!❤❤❤
00:45
а ты любишь париться?
00:41
KATYA KLON LIFE
Рет қаралды 3,1 МЛН
Smart Sigma Kid #funny #sigma #comedy
00:40
CRAZY GREAPA
Рет қаралды 39 МЛН
I Played Every Factory Game and You're Playing Them Wrong
9:46
TotalXclipse
Рет қаралды 115 М.
How I designed Fruit Ninja
22:58
Luke Muscat
Рет қаралды 6 МЛН
Steam EXPERT teaches you Game Marketing for SUCCESS!
52:22
Code Monkey
Рет қаралды 58 М.
How Two People Created Gaming’s Most Complex Simulation System
38:54
ThatGuyGlen
Рет қаралды 1,4 МЛН
Tierlisting the BEST (and worst) GAME ENGINES
33:51
BiteMe Games
Рет қаралды 217 М.
Engineering the PERFECT automated factory!
23:32
Real Civil Engineer
Рет қаралды 819 М.
This factory builder tower defense game is TOO ADDICTIVE...
22:25
Real Civil Engineer
Рет қаралды 610 М.
Using Video Games to Simulate Evolution
20:26
Curious Archive
Рет қаралды 2 МЛН
I Made A Difficult Game About Climbing
15:04
Pontypants
Рет қаралды 2,1 МЛН
Automation in Game Design
8:20
Artindi
Рет қаралды 12 М.
ОБЯЗАТЕЛЬНО СОВЕРШАЙТЕ ДОБРО!❤❤❤
00:45