xix

xviii

149 Figure 3.3.8 Once the execution line reaches a decision, a node is triggered to set the AgentState and then apply a timer to establish how long the agent might be in that state

Screen-captured by Author.

149 Figure 3.3.9 The execution line moves down and repeats all the checks for every entity type if it does not reach the end of the logic

Screen-captured by Author.

150 Figure 3.3.10 Functional Decision Logic during runtime

Simulated and screen-recorded by Author.

153 Figure 3.3.11 Navmesh at work

Simulated and screen-recorded by Author.

153 Figure 3.3.12 Flocking Behaviors recreated with Vector and World-Offset nodes within UE4

Screen-captured by Author.

155 Figure 3.3.13 The Behavior Tree allows a visual way to define AI tasks within UE4

From “Behavior Tree Overview,” Unreal Engine Documentation, accessed October 18, 2019, https://docs.unrealengine.com/en-US/Engine/ArtificialIntelligence/BehaviorTrees/BehaviorTreesOverview/index.html.

155 Figure 3.3.14 Behavior Tree Execution Order from top to down and left to right

From “Behavior Tree Overview,” Unreal Engine Documentation, accessed October 18, 2019, https://docs.unrealengine.com/en-US/Engine/ArtificialIntelligence/BehaviorTrees/BehaviorTreesOverview/index.html.

156 Figure 3.3.15 Explore Tasks defined within the Behaviour Tree

Screen-captured by Author.

157 Figure 3.3.16 EQS allows us to check the surrounding environment to calculate locations based on how far away they are from the agent

Screen-recorded by Author.

157 Figure 3.3.17 Agent Exploring the space by utilizing this data

Simulated and screen-recorded by Author.

159 Figure 3.3.18 Behavior Tree Object-Looking state tasks

Screen-captured by Author.

160 Figure 3.3.19 EQS also allows us to calculate a random location that is biased to how far away they are from an object

Screen-recorded by Author.

161 Figure 3.3.20 Agents ‘juggling’ the distances to the objects until they look right

Simulated and screen-recorded by Author.

165 Figure 3.3.21 Simplified steps for establishing object Interaction tasks

Illustrated by Author.

165 Figure 3.3.22 Object-Interact State tasks within behavior tree

Screen-captured by Author.

167 Figure 3.3.23 Agent interacting with an object

Simulated and Screen-recorded by Author.

167 Figure 3.3.24 Agents lining up before interacting with the object

Simulated and Screen-recorded by Author.

169 Figure 3.3.25 Agent Interact state tasks within Behavior Tree

Screen-captured by Author.

169 Figure 3.3.26 Agents interacting with each other

Simulated and Screen-recorded by Author.

171 Figure 3.3.27 Threshold State tasks within Behavior Tree

Screen-captured by Author.

171 Figure 3.3.28 Agent moving through threshold

Simulated and Screen-recorded by Author.

173 Figure 3.3.29 To spawn Agents, we must first make a list of all the Entrance Threshold objects at the start of the simulation

Screen-captured by Author.

173 Figure 3.3.30 Spawning Agents at Entrance Thresholds

Screen-captured by Author.

175 Figure 3.3.31 Enter State tasks within the Behavior Tree

Screen-captured by Author.

175 Figure 3.3.32 Agents entering and exiting the building

Simulated and Screen-recorded by Author.

177 Figure 3.3.33 Agents sometimes becomes stuck in the corner due to the EQS continuously perceiving the corner in front of the agent to be the furtherest point within the environment

Screen-captured by Author.

177 Figure 3.3.34 Unstuck State within Behavior Tree tells the agent to query a new location behind them if they don’t move for longer than a specified time interval

Screen-captured by Author.

178 Figure 3.3.35 Bug with obtaining a position vector for establishing agent global offset

Simulated and Screen-recorded by Author.

178 Figure 3.3.36 Bug with obtaining a position for the agents to form a line

Simulated and Screen-recorded by Author.

179 Figure 3.3.37 Bug with animation looping for the Agent Interact State

Simulated and Screen-recorded by Author.

179 Figure 3.3.38 Another global offset bug when establishing a position vector from the agent’s personal space

Simulated and Screen-recorded by Author.

180 Figure 3.3.39 Functional Behavior Tree during runtime

Simulated and Screen-recorded by Author.

183 Figure 3.3.40 UE4 animation system breakdown

From “Animation System Overview,” Unreal Engine Documentation, accessed December 28, 2019, https://docs.unrealengine.com/en-US/Engine/Animation/Overview/index.html.

183 Figure 3.3.41 Autodesk Character Generator

Screen-captured by Author, from “Autodesk Character Generator,” accessed December 28, 2019, https://charactergenerator.autodesk.com/.

185 Figure 3.3.42 Agents become lifeless floating objects without animation

Simulated and Screen-recorded by Author.

185 Figure 3.3.43 Animation Sequence within UE4 drives the skeletal mesh asset.

Screen-recorded by Author.

186 Figure 3.3.44 Blend Space

Screen-recorded by Author.

186 Figure 3.3.45 State Machine

Screen-captured by Author.

187 Figure 3.3.46 Adobe Maximo

Screen-recorded by Author, from “Mixamo,” Adobe, accessed December 28, 2019, https://www.mixamo.com/#/.

189 Figure 3.3.47 Animations controlled by the State Machine during runtime

Simulated and screen-recorded by Author.

190 Figure 3.3.48 Flowchart of updated Human Systems within UE4By Author.

Illustrated by Author

193 Figure 3.4.1 The Construction Script is visually very similar to the Blueprint

Screen-captured by Author.

193 Figure 3.4.2 The Construction Script allows us to sync model attributes within the game space with variables within the Blueprint

Screen-recorded by Author.

195 Figure 3.4.3 Command Center viewport and properties

Screen-captured by Author.

195 Figure 3.4.4 The Command Center asset contains the blueprint nodes (as defined in the Enter State on pg. 168) to spawn agents at thresholds every game tick during the simulation process

Screen-captured by Author.

197 Figure 3.4.5 Entrance/Exit viewport and properties

Screen-captured by Author.

197 Figure 3.4.6 Threshold viewport and properties

Screen-captured by Author.

199 Figure 3.4.7 Architectural Object viewport and properties

Screen-captured by Author.

199 Figure 3.4.8 The 3D mesh and materials of the object can be changed in the properties panel depending on the typology of the actual object

Screen-captured by Author.

200 Figure 3.4.9 Blueprint Interface node within the Interact node within the Object Interact State of the Behavior Tree.

Screen-captured and edited by Author.

201 Figure 3.4.10 The Interact Event within the object blueprint allows it to change the color of its texture whenever the Interact node within the behavior tree of the Agent is triggered

Screen-captured by Author.

203 Figure 3.5.1 3ds Max export window

Screen-captured and edited by Author.