if you understand 'outlines', like for using for writing a school essay or whatever, you understand the basics of scripting order~sequence!
============================
in simpliest form (this was the very first programming languages, like basic), scripting order~sequence, goes from top to bottom:
line 1: script 1
------V
line 2: script 2
------V
line 3: script 3
------V
line 4: script 4
==========================
but it gets more complicated, with nesting:
line 1: script 1
line 2: -> script 2
line 3: -> script 3
line 4: script 4
script 1 ~ line 1
|.......\
|.......script 2 ~ line 2
|.........\
|..........script 3 ~ line 3
|
script 4 ~ line 4
this isn't too bad though:
path: script 1 -> script 2 -> script 3 -> script 4
however, you can run into some exception-problems with scripts that wait for a user input or popup a menu window, as script 4 can activate before everything is finished up within script 2 and script 3.
================================
the simpliest (most error-free) nesting is obviously, a straight diagonal from the upper-left to the lower right:
script 1
.......\
.......script 2
...........\
...........script 3
..............\
..............script 4
path: script 1 -> script 2 -> script 3 -> script 4
================================================
so, what does you 'if~else' (using for this example) script would look like?, see below:
................................script 1
............................../..........\
...........script 2: if (true)............else
............ { script 3A }..............{ script 3B}
...........................\............/
..............................script 4
so the paths are:
script 1 -> script 2 -> script 3A -> script 4
script 1 -> script 2 -> script 3B -> script 4
========================================================
so, what does you 'if~else if~else' (using for this example) script would look like?, see below:
............................................script 1............
.........................../..................|..................\
...........script 2: if (A).............if else (B).............else
............ { script 3A }.............{ script 3B }...........{ script 3C }
...........................\..................|................/
..........................................script 4............
so the paths are:
script 1 -> script 2 (if A) -> script 3A -> script 4
script 1 -> script 2 (else if B) -> script 3B -> script 4
script 1 -> script 2 (else) -> script 3C -> script 4
===========================================
I hope you now see~understand what happens as we add more or less 'else ifs'... as trying to draw this stuff is a pain, lol.
I also hope you can understand all the other infinite path patterns~structures that can be done... lol
for an example, we can path~branch as deep as we want (think of an upside down tree):
............../\
............./\/\
............/\/\/\
.........../\/\/\/\
............../\
............./\/\
............/\/\/\
.........../\/\/\/\
..........|..|..|..|..|
or
............../\
............./\/\
............/\/\/\
.........../\/\/\/\
...........\/\/\/\/
............\/\/\/
.............\/\/
..............\/
or
............../\
............./\/\
............/\/\/\
.........../\/\/\/\
...........\/\/\/|.|
............\/\/..|.|
.............\/....|.|
and etc...
============================================
however, besides nesting scripts, you've got various loops (for, foreach, while, do-while, etc), functions (calling upon functions), functions calling on other functions, functions calling on themselves (loops the function: recursion), 'if' scripts~structures, and etc...
============================================
also, you might want to google various code flow charts, for some examples:
(this helps you train your brain in programming~code 'if' path-decision logic thought-processing~mentality, which is needed for game making regardless of whether you use code or the GUI~Editor)
https://en.wikipedia.org/wiki/Flowcharthttp://www4.ncsu.edu/~spbalik/java/IfElseExample.htmlhttps://chortle.ccsu.edu/QBasic/chapter18/bc18_3.htmlhttps://facweb.northseattle.edu/msteffa ... apter3.htmhttp://programmers.stackexchange.com/qu ... ps-processhttps://blog.udemy.com/flowchart-examples/