Flowchart Editor - IsaacMulcahy/RPG-AI-SYSTEM-WIKI GitHub Wiki

Diagram of Flowchart Editor (Red - Toolbar, Blue - Focus, Green - Link, Yellow - Requirement)

Change Mode

The flowchart is used for more than one kind of flowchart and can be changed by using the dropdown menu in the top right. This will clear your existing one.

Basic Movement & Input

The flowchart editor can be controlled by keyboard and mouse.

Name Mouse Positive Negative
Adding Node Right Click    
Panning Vertical Scroll Wheel Down Arrow Top Arrow
Panning Horizontal N/A Right Arrow Left Arrow
Zooming N/A ‘+’ ‘-’

Toolbar

The toolbar is the top section of the flowchart editor (shown in red) which is always present. Going from left to right down. The first section is where the camera is located on the canvas of the flowchart graph, the Slider handles the zoom level of the canvas with a reset to the left. Then there is export and import used for saving and loading. Clear is used to reset the Flowchart editor.

Node Creation

The flowchart editor uses the Job System. These nodes can be added into the flowchart editor by right clicking within the canvas. This creates a context menu which provides a list of the nodes presented in the table above.

Node Interaction

The nodes can be moved by clicking and holding the tab with the node type name above the interaction buttons.

  • Links are explained in more detail in Links and Ordering.
  • Focus is explained in Focus System.
  • Clear links can be used to remove all child connections to the node
  • Delete is used to delete the current node.

Links and Ordering

Links of nodes (shown in Green) can only be done from one level down from the selected node (E.g., Job can connect to Duty but not Task, Method can connect to Action but not Task). Links are connected by selecting the ‘link’ button on the node which you wish to connect (parent node) and clicking the ‘link’ button on the node which you wish to make a child of the parent node. The order of the child nodes has an impact on the order the children are executed in zero being first and one being next. Links can be deleted using the flowchart connection widget by selecting the row and then clicking the '-' icon (bottom section of node, does disappear when zoomed out). Order can also be rearranged drag and dropping.

Requirement System

To add a requirement (shown in yellow), you can click on the ‘circle’ on the connection line, if the circle is filled in then a requirement is in place, if the circle is not filled then there are no requirements. Deleting is done via the widget. The widget can be collapsed and folded out by clicking on the circle. The requirement system allows for criteria to be required before a node can be executed, the four top level nodes (Job – Method) all have the same requirements selection which can be found below.

Name Impact Default
Required time If enabled this node will only be started within this time slot Disabled – 0-2400 (full day)
Item What Item is required to perform the node NULL
Num of wrks doing Check how many workers are doing the node and if met Disabled – 0 > None (last box is the name of the nodes which are children to the parent node)

Actions requirements work slightly differently, these are more requirements by the system for the action, this being wait time and animation reference. Items needed and outputs are defined on the action node.

Below Requirement is not present as of V0.7.0

Name Impact
Wait Time How long they will stop at the end of the action or idle for (e.g. if finding something)
Animation Reference What animation to play and will loop

Focus System

The focus system (shown in blue) is used to allow the user to focus in on specific paths in the flowchart editor. This is accessed via the ‘focus’ button on the Node. When this is selected, all connected lower nodes are only shown. The focus groups are shown below the toolbar (shown in blue) and is referenced by the unique identifier of the top node. To show all nodes, select ‘Main’. Focus groups can be deleted by selecting the ‘x’ to the right of the group reference. If a new node is added then it will show within the focused group. If focus group is changed the new unconnected node will not be shown except in the ‘Main’ focus or if it gets connected to the parent node of the focus group or lower.