It depends how complex the task is. Since I make many Multiplayer features it quickly becomes impossible to keep an overview in the head. Using trial and error is also not an option as it takes too long to code that way.
The graph thing you talk about is probably UML (Unified Modeling Language) which I use to visualize complex mechanics before even starting with C++ or Blueprint. Many (or most) skip this part of the planning maybe because they feel it is a waste of time. Systems quickly get complicated though and having a UML diagram to fall back on can save you a lot of debugging. While creating the UML diagram I discover many flaws that can quickly be solved since I haven’t begun coding anything yet.
The disadvantage of UML diagrams is that it is purely pseudo-code so while you are making it you won’t get any feedback if what you are doing is even possible so it might not be well suited for beginners.