Mindustry V6 Logic Tutorial Guide - Learn To Problem Solve With Guidance From A Real Programmer
Вставка
- Опубліковано 16 вер 2024
- Today's video is intended to act as an introduction and comprehensive guide showcasing how Mindustry V6's new logic system works and giving several different working examples of how to harness this new utility in your own play sessions. This tutorial covers the main components introduced with the Mindustry 6.0 update and should get you up to speed in no time at all. If you have any questions or suggestions for future topics, please leave them in the comment section below. I'm always happy to interact with my viewers.
Block Overviews:
Message - 0:11
Switch - 0:16
Processor - 0:28
Memory - 1:49
Display - 3:05
Schematic Example Explanations:
Controlling a display with a switch: 4:07
Disabling blocks, controlling units and feeding towers with logic: 7:48
Automatic building repair with poly unit: 28:07
Become an Impossi-pal by supporting the channel on Patreon: / impossibum
Join The Official Channel Discord! / discord
If you're a fan of this or any of my videos, feel free to spread the word. Posting a link on social media/reddit/facebook helps the channel and is greatly appreciated.
Title: Mindustry
Mindustry 6.0 Let's Play Series: • Mindustry 6.0
Developer: anuke.itch.io/
Store Link: store.steampow...
Description: "Gameplay
Create elaborate supply chains of conveyor belts to feed ammo into your turrets and produce materials to use for building
Use production blocks to create a wide variety of advanced materials
Defend your structures from waves of enemies
Play with your friends in cross-platform multiplayer co-op games, or challenge them in team-based PvP matches
Distribute liquids and fight constant challenges, like outbreaks of fire or enemy flier raids
Get the most out of your production by supplying optional coolant and lubricant
Produce a wide variety of units for automatic management of your base or assault on enemy bases
Campaign
Conquer the planet Serpulo as you advance through 250+ procedurally generated sectors and 16 hand-made maps
Capture territory and set up factories to produce resources while you play other sectors
Defend your sectors from periodic invasions
Coordinate resource distribution between sectors via launch pads
Research new blocks to fuel progress
Invite your friends to complete missions together
120+ technology blocks to master
33 different types of drones, mechs and ships
50+ achievements to complete
Gamemodes
Survival: Build turrets to defend from enemies in tower-defense based gameplay. Survive as long as possible, optionally launching your core to use your collected resources for research. Prepare your base for intermittent attacks from airborne bosses.
Attack: Build factories for units to destroy the enemy cores, while simultaneously defending your base from waves of enemy units. Create a variety of different types of support and offensive unit to assist you in your goals. Optionally enable an AI that builds defensive structures to an extra challenge.
PvP: Compete with other players on up to 4 different teams to destroy each other's cores. Create units, or attack other bases directly with your mechs.
Sandbox: Play around with infinite resources and no enemy threat. Use sandbox-specific item and liquid source blocks to test out designs, and spawn in enemies on request.
Custom Games & Cross-Platform Multiplayer
16 built in maps for custom games, in addition to campaign
Play co-op, PvP or sandbox
Join a public dedicated server, or invite friends to your own private session
Customizable game rules: Change block costs, enemy stats, starting items, wave timing and more
Mix & match gamemodes: Combine PvP and PvE gamemodes together
Custom Map Editor
Paint terrain with an editor UI
Edit and preview structures in-game
Configurable tool modes: Change how each tool functions
Powerful map generation system, with many different types of filters for procedural manipulation of terrain
Apply noise, distortion, smoothing, erosion, symmetry, ore generation and random terrain to your maps
Randomize and configure ore generation, as well as placement of river and resource tiles
Configure enemy wave layouts
Share exported maps on the Steam Workshop
Customize base map rules
Use 80+ different environmental blocks" -store page
Follow me on Twitter: / impossibum
#Mindustry #TowerDefense
Thank you for watching! Please consider subscribing if you enjoyed the video, it's a FREE way to help the channel grow. If you'd like to lend even more support, there's now tons of cool things available on PATREON! www.patreon.com/impossibum
I was trying to control the conveyor but it didnt work
As a newbie iam blown
@@chillcapsaicin6109 it might help to check out my Mindustry schematics series. I do a lot of code-a-longs so you can get a feel for how to work your way through builds start to finish.
i guess Im kinda off topic but do anybody know a good website to stream new series online?
@Jase Jesse Flixportal =)
Listening to your logic tutorial live without cuts is like listening to your math teacher solving a math problem that even he find difficult to answer and actually solves it and makes it easier for you to understand it too. Thank you for the logic tutorial guide
OMG thank you, i was confused AF to those new blocks
I'm glad it helped :)
At the end of this it felt really complicated but when I actually played mindustry today I was able to easily code what I wanted. Thanks!!
When you realize you sat through an entire pure harder than math tutorial with a smile on your face
It is not.
I dunno, this is easier than math for me.
@@holl7wbro has spoken 🗣️🗣️🗣️
Containers can hold each item up to 300. (300 pyrite and 300 graphite, and 300 etc of whatever.) But that was a good example tutorial
What
@@jadhamadou9435 it's per item type
I really like the tutorial, you could do something to show the display how many raw materials are in the kernel
should probably start reading the descriptions of thing's, 100 hour's played, i thought the message block was a thing so you could communicate on multiplayer, i'm always like "why do i want to unlock that? i only play single player" roflmao.
Well it's a handy debugging/display tool now at least. Beforehand I never really used the message block either honestly.
what does it do??? enlighten my none-description reading ass😭
Yo learn to use apostrophes properly
A game that makes you learn coding neat
fun fact: there is a new 4th processor called the "world processor" (also a world cell, and a world message). You can get it by
1. Create a custom map in the editor
2. place a world cell by either:
2.1. placing it in the editor
2.2. place it in "edit in game" through the menu where you exit the editor
3. you can edit the world processor's instructions by either:
3.1. edit in game (the game is essentially "paused", so the processor wont work in there)
3.2. playtest
The world processor can do many things a normal processor can't (like placing a block, making an explosion, particles, etc), so it's probably worth checking out
When said the sentence that you can use units to give your turrets and generators item
I just couldn't belive my ears you changed the whole game for me
This is
*Extremely underrated*
You should have 100k subs by now
We will watch your career in great interest
I once used a logic script that would keep my thorium generators from exploding if they got too hot or ran out of coolant, well worth the effort, those things like to go boom.
I also used another to only power on my production plants after they had enough resources to actually do something (saving a lot of needless power drain when they were short some ingredient).
Wow this is a lot of useful information about logic in this video. Thank you!
Glad it was helpful! =D
I see what you did there
Containers hold 300 of *each* item; you can have 300 graphite *and* 300 pyratite in a container. So the second example isn’t necessary to prevent a container from filling up with one kind of item. But it could still be useful you have a scarce resource that you only need 50 of in a container, for example.
You are correct, so it's not a practical example of something people should do but it is one that's easy to understand hopefully at least.
Also, you can simplify the logic for turning conveyors on and off by using operations instead of jumps. For example, you can control graphite like so. 1) Sensor: graphite_count = @graphite in container1. 2) Operation: graphite_on = graphite_count
@@pnyx7930 nice
Finalmente um vídeo de mindustry legendado
Eu tbm estava procurando
I am proud to say that I'm the 869th like of this video, absolute unit of a man at teaching
13:22 something weird happened there with one "if always" but it's still working
Is it possible to make the flare group up into 2 groups, 1 group following 1 player and the other group following another player in co-op?
I'd love to see how to show the total power generated on logic display. I am not sure what to read from to get this value!
Damn, this guy is a good teacher
Finally someone I can understand if you know what Im saying lel
hey i tried to use daggers to transport goodies between buildings but they seem to walk in straight lines between the building. ending up against walls and buildings, where they will be stuck for the rest of the time is there any way yo make them a bit more intelligent, and to navigate trough these buildings?
besides "move" (which makes it move by a straight line), there is also pathfind (it does the same thing but *finds* the *path* it needs to make to get to point b)
yea it works! thanks a lot
What if you did a speedrun in mindustry only two people did it.(Happy New Year btw)
Love the video
can you show how to do percent on a container? I want my conveyors to stop feeding then my core full. That way materials can be fed into other productions and not burned. Also the reason conveyors stop at 51, is you have > and not = or >=.
Glad you liked the video! I put together this example for you, hopefully it helps :)
steamcommunity.com/sharedfiles/filedetails/?id=2345361025
Basically lesser or equal than and greater or equal than.
Thanks for the vid! If anyone reading this has perhaps already created code for automatically replacing all your old conveyor belts to something like Titanium belts, could you please share it?
thanks for the guide i may watch your other videos too
You're very welcome, I hope you find some others you like :)
Hey Thanks a Lot Impossibum Plays :) good informations.. ahhh I miss my Programmer days..... :) new stuff to test
I'm a programmer... And one that likes efficiency and looking at the programming system of this it's kinda horrible but then again this is mindustry
Won't complain, you did a pretty good job as compared to other Mindustry UA-camrs, but just a favor, can you make me understand what are the options like Unit Flush, Sensor etc...
Well, let's start with the flushes. Print flush for example simply takes whatever was put into the print command and pushes it to the message block. Draw flush is essentially the same thing but for draw commands and pushing those to a display. Sensor is a super useful tool. It allows you access to ALL sorts of information about an object you're referencing. Whether that referenced object be a unit or building, you can learn all sorts of things, Stuff like it's name, type, x position, y position, what it's carrying, current health, etc.
@@ImpossibumPlays Nice dude! Got it!
reminds me of assembly
yeah, a lot of games seem to employ assembly like instructions.
can you do defence system going up, like powering up and your units will act on a tactical attack based on the coding when a large ranged turret detected an enemy within it's radius
That's certainly possible but I think patrolling units like in this video ua-cam.com/video/eebiTlplFeE/v-deo.html would likely be a more efficient use of resources.
I would rather use @(preferred item) than @firstitem couse it crashes when drone has at start wrong item
you sound like that one guy from resident evil:code veronica but with a less rediculous accent and more braincells
also thank you for this fantastic tutorial you are my hero
Awesome tutorial, but it mesmerizes me that you got to CODE the whole behavior of your units, otherwise they're pretty much useless, unless you want them to go to the end of the map. This game was nice until I got to units......... 🤦🏻♂️
Thats why its called mindustry bro..
@@hello-qp1cl industry = code everything with the worst logic format possible? lol
@@igorsantos07 that is the mind part not the industry part😂
i thought min was from mine =
mining industry
there was a comand block for units back then you can toggle to "rally", "attack" and one other i forgot
fold and expand too
Thanks
Yo thanks
how to add a command for the poly part to repair only if no enemy wave is active? ive added a unit radar: target enemy any, order 0, sort distance, output result... now the dont do anything anytime at all
7:23 is it possible to change the color of the rectangle and the background?
Absolutely! The clear command at the top of the script sets the default background color in rgb values. You can see our's is set to black with values of 0 across the board. You can similarly change the color of drawn shapes by changing the chosen color before using the draw command.
I want this guy to be my teacher
you know a command to locate and rebuild blocks from past games to add to the processor?
How do you control doors to open when an ally unit gets nearby
I got you covered :)
ua-cam.com/video/X__YKYFFMx0/v-deo.html
If I’m not missing something I think there was no lag in the code at 14:29 and the reason you had 51 graphite is because the greater than if block and that the number that’s greater than 50 is 51
You sir are correct! I think I was using >= in my head. That's my story and I'm sticking to it! :)
I am on v7, release build 143 on mobile and cannot even get units to pick up pyratite or blast compound for suicide bombings. Please help?!
I wish the color was easier. Its hard to just find colors by just putting numbers on the respective color for the hue so they make another color, especially when you have red, green, and blue to work with.
You can use an rgb color finder
27:55 would it work without "if always"? I think it would, but I know what it does here
Thanks for all the feedback! :)
For some reason I can easily get the gist of coding in mindustry, yet my mind can't even remember basic mathemathics.
I have a like 16 by 16 canvas and a message block how do I get them
Im wondering where is the tutorial map and desert wastes
Tbh this is better than maths class lol
Can you do it again but mono mine ores then deliver then repeat if the factory(or other) is empty? Please XD
Display not refreshing if we turn off switch
Know a command to tell the unloader to take titan, coal and graphit periodical? Switch between this 3 only like 5 seconds each and repeat?
You can prob write like
-control
Config unloader1 to @titanium
-Wait
5second
-Control
Config unloader1 to @coal
-wait
5second
-control
Config unloader1 to @graphite
-wait
5second
@@DiscountMiku worked, 0.1 is enough for titanium roads ty
Whats the processor command to tell polys to repair if nothing has to be build?
The way he says mindustry
What command "if always" do?
necesito este video pero en español
Can u make switch down when reactor meltdown???
Hey! I am also a programmer! What is your favourite coding language? Mine is R and C++ and I love making websites with JS and HTML5!
Mine use to be Java
@@kasper7203 why not continue learning Java? I am not forcing you but, it's your choice :D
@@thekeyboardwarrior1018.. That's a good question.. Depression I guess
Mindustry logic processors is just as simple as Minecraft Redstone Contraptions I don't get both so, Imma here
Is their a way to detect destroyed or ghost buildings using logic?
Interesting stuff and thank you but so far I have found no need to use logic in Mindustry. By the time I try to set something up like this I have beaten the map and probably a 2nd map =p
That's why you use schematics. The poly auto repair service will work with just plopping down the schematic
@@zimzimph I believe you. I wouldnt use someone elses schematic so thats out. Id have to make up my own but cant be bothered. Not if I can keep beating maps without using the system in the 1st place.
What does if always do
How do you do your horizon assault team with only micro processors
As an IT (not programmer more like technical staff but I do code little bit and hearing code, program, debugging , logic ,processor, if not equal,null, etc wtf with game now I feel like coding something I played this game before but 5 years and is not that complicated unlike now
What I understood is that this coding bit is similar to one in scratch
13 minutes into the video and it already confused me
It can be really hard to grasp logic and coding when you're just starting out. Hopefully you'll keep trying :)
Yo nice vid. But I wanna know if it's possible to allow every turret in the vicinity of a processor to target where your aiming without the hassle of having to copy-paste each command for each individual turret.
yes, totally possible.
@@ImpossibumPlays can you like show me how you do it? Been trying but can't seem to find a way at all
Me who just wants to make the logic proccesor display a copper image: *crying*
I just want units to go towards the drop point so they can fight.
i think you didnt explain the If Always part, you spoke about speaking live and stuff and you forgot about telling us what If Always does and what is was linked to for what purpose, i had to discover it by myself
But what do I use the logic for, like when should I put it to use
Check out my Schematics playlist if you'd like to see some cool things you can do with logic: ua-cam.com/play/PLP3FDE6qUu0YFKcEM74WezBorq1uM7oMF.html
@@ImpossibumPlays thanks 😊
So jump is like an if else statement?
You can certainly think of it that way. If condition is true, jump to the line indicated, else continue to next line.
@@ImpossibumPlays i see it's just like programming but sometimes its kinda hard to see and confusing
How to find x and y value
x and y value of what?
As long as you have a reference to something, you can read the values as @x or @y
@@ImpossibumPlays I got it I play on mobile that's why
Jumps are so horrible to use if you're used to using loops...
Jumps are quite versatile, you just have to get used to using them to create the same control flow for your scripts.
Where is the doc for this language...
Closest thing I'm aware of is the rtfm mod: github.com/DeltaNedas/rtfm
As a begginer iam blown
Hey this is a Beautyfull showcase how to build some Structures, but this it's not a guide.
A guide would have included how to set parameters and what every parameter is going to do.
You are just Rushing some mashines... Hope you dont think i Mean or else. Im just trying to tell you what i am thinking about.
My processor wouldn't work at all...
I would learn coding if you cam implement it in mindustry
It's very difficult to understand.
10:55
Turn on captions
"go flavor mode with trident vibes"
Ahhh... Aaahhhhh.!. AaaAAAHHHHHH!!!!!
Pfvr poderia me ensinar a baixar no steam tenho muita dificuldade :(
Você está tentando instalar jogos do Steam em um dispositivo móvel? Nesse caso, isso não funciona. Você terá que usar o aplicativo Mindustry da playstore. Caso contrário, precisaria de mais informações para ter alguma esperança de ajudá-lo. Estou usando o google tradutor, então espero que esta mensagem seja compreensível.
Why is this logic harder than actual programming? ಠ_ಠ
The problem is that it's missing a lot of the helpful features that common languages tend to have. So you're given something like assembly to work with as opposed to something like python which many people are more comfortable with.
My God now im even more confused do u have a tutorial for dummies?
Check out the other videos in the logic guide playlist: ua-cam.com/play/PLP3FDE6qUu0YcuoOpPSVMuMdjdCmDX2bU.html
They're more simple and to the point.
HELPPPPPP PLZ ITS JUST DONT WORK ANY SHIT BE ME
too bad you can't group and indent the logic lines.
Nah you lost me after you introduced the names of the items XD
It's too complicated it's good to be complicated but not this complicated the names of the actions dont really make sense
I watched 2/3 of the video trying to copy what he was doing and I just gave up
my brain no comprende
y must gam mk me tink
Oof i always called it minedustry.
why this shit need to be so complicated?
so basically learning how to code but its a game. lmao
Coding is a great skill to have. If it's gamified to get people interested then that's OK with me :)
Great video but these new blocks are useless
How are they useless if u could do many things in a much easier and effective way🙂
Display doesn't work ;-;
What issues are you having with display?
@@ImpossibumPlays it does not turn on!
@@Foxy-eb9jf after using the draw command, you have to flush the draw queue to the screen. So every cycle should look like this: clear display (usually with black so all 0's for color), draw your lines as you wish with the draw command, and then finally flush those instructions to the display. Make sure the display is accessible by the processor and that you're sending it to the right one.
It's not pyrite it's pyrAtite
Also thanks for the vid!
Indeed it is! I still make that mistake during commentary sometimes but I'm working on it :)
You just do everything in one take huh?