You are on page 1of 52

ESOFT METRO CAMPUS

CU6051ES - Artificial Intelligence


Coursework 2
Technical Documentation - Agent Behavior
BEng (Hons) in Software Engineering
Batch -17 (2022)

Members of Group
London Met ID Students Name

22015187 Suhaibul Akram Muhammed Azran

22015200 Mohommed Hanifa Rifnas

22015185 Risiidhan Punniyamoorthy

22015193 K. K. Sujith Prasanna Perera

M.H. RIFNAZ 1
Acknowledgement
The team would like to take this opportunity to thank Ms. Ashala Perera for delivering the
lectures on time for the students to understand and learn the underlying concepts of Artificial
Intelligence which supported the team to complete the given coursework in time according to
the deadline.
As well as the team would like to thank the ESOFT Metro Campus and the coordinator for
arranging the extra learning session for the students to achieve the learning objectives.

M.H. RIFNAZ 2
Contents
1 General information ............................................................................................................... 8
1.1 Purpose ............................................................................................................................ 8
1.2 Selected topic .................................................................................................................. 8
1.3 Goal ................................................................................................................................. 8
1.4 Objectives ........................................................................................................................ 9
2 System .................................................................................................................................... 9
2.1 System summary ............................................................................................................. 9
2.2 Functionality and features ............................................................................................... 9
3 Technology .......................................................................................................................... 11
3.1 Unity .............................................................................................................................. 11
3.2 Visual Studio ................................................................................................................. 11
3.3 Photoshop ...................................................................................................................... 11
4 System design ...................................................................................................................... 12
4.1 Sample diagram ............................................................................................................. 12
4.2 P.E.A. S ......................................................................................................................... 12
4.3 State diagram ................................................................................................................. 13
4.4 State table ...................................................................................................................... 14
4.5 Flow chart...................................................................................................................... 15
5 Game controls ...................................................................................................................... 16
5.1 Game objects ................................................................................................................. 16
5.2 Controls ......................................................................................................................... 24
6 Requirements ....................................................................................................................... 33
6.1 Minimum requirements ................................................................................................. 33
7 Important code snippets ....................................................................................................... 33
8 Testing.................................................................................................................................. 39
8.1 Test plan ........................................................................................................................ 39
8.2 Test cases....................................................................................................................... 40
9 References ............................................................................................................................ 50

M.H. RIFNAZ 3
Appendix A ............................................................................................................................. 51
Appendix B ............................................................................................................................. 52

M.H. RIFNAZ 4
Table of figures
Figure 1: sample diagram (author's design) ............................................................................ 12
Figure 2: state diagram (author's design) ................................................................................ 13
Figure 3: flow chart (author's design) ..................................................................................... 15
Figure 4: player agent (author's design) .................................................................................. 16
Figure 5: cloud- normal (author's design) ............................................................................... 16
Figure 6: cloud-dark (author's design) .................................................................................... 17
Figure 7: grass tile (author's design) ....................................................................................... 17
Figure 8: dirt tile (author's design) .......................................................................................... 17
Figure 9: rock tile (author's design) ........................................................................................ 18
Figure 10: water (author's design) .......................................................................................... 18
Figure 11: forest man (author's design) .................................................................................. 18
Figure 12: coin machine (author's design) .............................................................................. 19
Figure 13: lion (author's design) ............................................................................................. 19
Figure 14: trap (author's design) ............................................................................................. 20
Figure 15: lava (author's design) ............................................................................................. 20
Figure 16: helicopter (author's design) ................................................................................... 21
Figure 17: boat (author's design) ............................................................................................ 21
Figure 18: lava tile (author's design)....................................................................................... 23
Figure 19: medicine (author's design) ..................................................................................... 23
Figure 20: coin (author's design) ............................................................................................ 24
Figure 21: step 1 (author's design) .......................................................................................... 25
Figure 22: step 2.1 (author's design) ....................................................................................... 25
Figure 23: step 2.2 (author's design) ....................................................................................... 26
Figure 24: step 3 (author's design) .......................................................................................... 26
Figure 25: step 4.1 (author's design) ....................................................................................... 27
Figure 26: 4.2 (author's design) .............................................................................................. 27
Figure 27: 5.1 (author's design) .............................................................................................. 28
Figure 28: 5.1 (author's design) .............................................................................................. 28

M.H. RIFNAZ 5
Figure 29: step 6.1 (author's design) ....................................................................................... 29
Figure 30: step 6.2 (author's design) ....................................................................................... 29
Figure 31: alternative step 1 (author's design) ........................................................................ 30
Figure 32: alternative step 2.1 (author's design) ..................................................................... 30
Figure 33: alternative step 2.2 (author's design) ..................................................................... 31
Figure 34: alternative step 3 (author's design) ........................................................................ 31
Figure 35: alternative step 4.1 (author's design) ..................................................................... 32
Figure 36: alternative step 4.2 (author's design) ..................................................................... 32
Figure 37: player left, right (author's design) ......................................................................... 33
Figure 38: player jump (author's design) ................................................................................ 34
Figure 39: player trigger 1.1 (author's design) ........................................................................ 34
Figure 40: player trigger 1.2 (author's design) ........................................................................ 35
Figure 41: game pause when interaction (author's design) ..................................................... 35
Figure 42: game pause and resume (author's design) ............................................................. 36
Figure 43: cloud code (author's design) .................................................................................. 36
Figure 44: wild animal 1.1 (author's design) .......................................................................... 37
Figure 45: wild animal 1.2 (author's design) .......................................................................... 37
Figure 46: coin machine (author's design) .............................................................................. 38
Figure 47: boat (author's design) ............................................................................................ 38
Figure 48: Gantt chart (author's design) ................................................................................. 52

M.H. RIFNAZ 6
Table of tables
Table 1: state table (author's design)....................................................................................... 14
Table 2: requirement to run application (Unity documentation) ............................................ 33
Table 3: test case 1 (author's design) ...................................................................................... 40
Table 4: test case 2 (author's design) ...................................................................................... 41
Table 5: test case 3 (author's design) ...................................................................................... 43
Table 6: test case 4 (author's design) ...................................................................................... 45
Table 7: test case 5 (author's design) ...................................................................................... 46
Table 8: test case 6 (author's design) ...................................................................................... 48
Table 9: test case 7 (author's design) ...................................................................................... 49
Table 10: technical risks (author's design) .............................................................................. 51

M.H. RIFNAZ 7
1 General information
1.1 Purpose
Artificial Intelligence is an application developed to act like the process of human cognition to
bring solution to the real world with the support of the AI knowledge base. With the
technology, Artificial Intelligence has drastically improved and widespread across different
technological sectors, for instance; Natural Language Process, text processing and machine
learning etc. With the assistance of the recent findings of Artificial Intelligence, forecasting of
upcoming states of real-world events has affected the human activities to improve (Burns et
al., 2022).
The technology of Artificial Intelligence has impacted the video gaming platforms as well.
Instead of being a singular effect, Artificial Intelligence has been implemented to develop
video games to have different effect on its agents. According to Stuart (2021), Sony
Corporation has taken measure develop their games with Artificial Intelligence integrated to
provide the agent with different effects on the decision that has been made in the scenario.
With technology is being improved and solutions are brought, as beginners who are seeking
for knowledge and opportunities to make an impact on the current field, have invested the
gained skills into the sector of Artificial Intelligence to bring products and solutions to current
field.
1.2 Selected topic
For the given coursework, the team has selected the Agent behavior. The team decides to
develop simulated scenario where there are agents and objects that affects the current of the
scenario of the simulation.
1.3 Goal
The goal of the team is to understand the underlying concepts of Artificial Intelligence and
real-world solutions to develop an agent behavior application where there are agents and
objects in a simulated scenario that provides challenges and alternatives endings to follow
throughout the simulated platform to reach the end goal.

M.H. RIFNAZ 8
1.4 Objectives
To research on the Artificial Intelligence.
To understand the underlying concepts of Artificial Intelligence.
To Research on similar applications of agent-based application.
To identify technologies for the development of the application.
To collect documentation and technological resources for the development of the application.
To share the technological resources among the team members for development.
To have brain-storm sessions to discuss regarding the research and development.
To design multiple design concepts of the scenario for an integration of a final system.
To develop a sample prototype with agents and objects.
To enhance the prototype through iterations to meet the end goal.

2 System
2.1 System summary
Boy scout adventure
The simulated scenario is based on the concept of pathfinding to reach the end goal. The
application is known as ‘Boy scout adventure’ where the agent must find end goal of the
simulated platform for mission completion. While the pathfinding of the agent, the agent faces
different challenges that could prevent the agent from either the reaching goal or support the
agent. The agent must identify the objects that could be a threat and must apply proper
measures to pass them or ignore them. The agent is given the opportunity to complete scenario
on the decisions that is taken, hence the ending of the scenario depends on the actions taken
while reaching the end goal.
2.2 Functionality and features
Player
The agent of the scenario shall be an object that can perform real world physics, including
movement and jump mechanics. The agent shall move left and right, jump up to a certain height
as well shall drop to the platform considering gravity mechanics. The physics shall be based
by the controls of the user inputs.

M.H. RIFNAZ 9
Audio with distance
Game objects of the simulated scenario should have objects that have audio integrated. The
audio should be played considering the distance of the agent.
Visual object changes
Visual presentation of the object on simulated scenario shall change according to the time
being. The visual changes shall include weather change and object grabbing. The visual of
weather should after certain time, the objects should visually disappear as they are taken by
the agent.
Agent threats
Agent shall be given threats in simulated platform that should be overcome to reach the end
goal. The threats should only be against the agent, based on the user inputs, threats include
wild animal, animal trap. Agent interacting with the threats shall result restart of the simulated
platform.
Agent challenges
Agent shall be given challenges in simulated platform to reach the end goal of the scenario.
The challenges for the gent should depend on the actions taken by the agent, hence agent should
be able to ignore the challenges.
Visually appeal
The simulated scenario should have visual appealing environment. The agents of the platform
should have similar visual as the real-world objects, the objects include wild animal, rescue
helicopter, ground, and boat

M.H. RIFNAZ 10
3 Technology
3.1 Unity
Unity is, absolutely put, the world’s most famous game engine. It packs a ton of functions
collectively and is flexible enough to make nearly any game you could imagine. With
unmatched cross-platform functions, Unity is famous with each interest builders and AAA
studios. It’s been used to create video games like Pokemon Go, Cuphead, Heathstone,
Rimworld, and lots greater. While 3D is in the name, Unity 3-d additionally packs equipment
for 2D game improvement (Sinicki, 2020).
3.2 Visual Studio
Visual Studio is an Integrated Development Environment (IDE) advanced through Microsoft
to increase GUI (Graphical User Interface), console, Web applications, web apps, cellular apps,
cloud, and web services, etc. With the assist of this IDE, you could create controlled code in
addition to local code. It makes use of the diverse systems of Microsoft development software
like Windows store, Microsoft Silverlight, and Windows API, etc. It isn't a language-precise
IDE as you could use this to put in writing code in C#, C++, VB (Visual Basic), Python,
JavaScript, and plenty of greater languages. It gives help for 36 distinctive programming
languages. It is to be had for Windows as well as for macOS (Incredibuild, n.d.).
3.3 Photoshop
Photoshop is a graphic creation, photograph layout and image modifying software program
advanced through Adobe. The application gives many image modifying functions for pixel-
primarily based totally images, raster pics and vector graphics. Photoshop has been the industry
standard graphic manipulation application for so long that its name has become a verb. It is
common parlance to mention that an photo has been "photoshopped," or maybe just "shopped,"
that means that it is been edited or manipulated. It makes use of a layer-primarily based totally
modifying gadget that permits raster photo creation and changing with multiple overlays that
help transparency (Smith, 2018).

M.H. RIFNAZ 11
4 System design
4.1 Sample diagram

Figure 1: sample diagram (author's design)

4.2 P.E.A. S
Performance
Ability to jump when medicine pill is taken
Slow jump when on water
Die when hit on animal trap
Die when hit on lava
Die when hit by lion
Ability to activate the boat when coin is grabbed
Game end when reach the vehicle
Environment
Forest
Underground
Lava
Water
Weather

M.H. RIFNAZ 12
Actuator
Move left
Move right
Jump
Drive
Absorb
Grab
Sensor
Lion roars and moves when the agent is near to him
Forest man gives message when the player interacts with him for the first time
Boat activates when the coin is inserted to the machine
Helicopter flies when the player gets on
4.3 State diagram

Figure 2: state diagram (author's design)

M.H. RIFNAZ 13
4.4 State table
Current state Condition State transition

Injured player pointing to If ‘A’ is pressed Injured player pointing to left


right

Injured player pointing to If ‘D’ is pressed Injured player pointing to


left right

Injured player If medicine absorbed player (can jump)

Player If hit by animal trap Player dead

Player If on water Jump power reduced player

Player If hit by Lion Player dead

Player If hit by Lava Player dead

Player If grabbed coin Player with coin

Player with coin If coin inserted to machine Player can drive the boat

Player If gets on the helicopter Rescued player


Table 1: state table (author's design)

M.H. RIFNAZ 14
4.5 Flow chart

Figure 3: flow chart (author's design)

M.H. RIFNAZ 15
5 Game controls
5.1 Game objects
Player agent

Figure 4: player agent (author's design)


The player agent is integrated with real world physics involved including player movement.
The player agent object is moveable to left, right, however is not able to jump as the player
state is ‘injured’. The agent is integrated with gravity, hence that the agent is pulled to platform
when the agent is involved with the jump mechanics.
Cloud
Cloud - normal

Figure 5: cloud- normal (author's design)


Cloud is an agent object is part of the environment of the simulated platform. The cloud object
does not affect the gameplay of the simulation; however, it changes its state after certain time.

M.H. RIFNAZ 16
Cloud – dark

Figure 6: cloud-dark (author's design)


Cloud changes its state to ‘bad weather’, after certain. This affects the simulation by changing
visual of the cloud from normal color to a dark color state. As well as the cloud object is
integrated with 3D audio, hence the audio level changes as per the player location on platform.
Environment
Grass tile
Grass tile platform is where player agent is spawned.

Figure 7: grass tile (author's design)


Dirt tile
Dirt tile platform is designed for wild animal environment

Figure 8: dirt tile (author's design)

M.H. RIFNAZ 17
Rock tile
Rock tile platform is the underground area is the platform.

Figure 9: rock tile (author's design)


Water
The water object is integrated as a part of the simulated environment. The water is developed
with the 3D audio, hence the audio level changes, as per the player location on the platform.
Water reduces the jump mechanics of the player agent when the player agent interacts with
water.

Figure 10: water (author's design)

Forest man
Forest man is on the grass platform of simulated scenario. Forest man agent guides the player
on how to reach the end goal of the platform, when the simulated scenario begins for the first
time.

Figure 11: forest man (author's design)

M.H. RIFNAZ 18
Coin machine
Coin machine is part of the underground platform of the simulated scenario. The coin machine
agent object assists the player agent to reach the end goal, using an alternative ending method.
The machine takes the coin that is taken by the player agent and activates the boat.

Figure 12: coin machine (author's design)

Lion

A visual of lion is added as a threat for the player agent in the simulated scenario. The wild
animal is designed with 3D audio; hence the audio level is changed as per the player location.
The wild animal does not interact with the objects, unless it detects the player has entered to
its environment. The wild animal is designed with movement mechanics that it moves left and
right making the player agent difficult to surpass the threat. Lion interacting with the player
agents results for an application restart.

Figure 13: lion (author's design)

M.H. RIFNAZ 19
Trap

An animal trap is added as a threat for the player in the simulated scenario. The trap does not
involve in any physical mechanics. The player agent triggering with the animal trap results an
application restart of the platform.

Figure 14: trap (author's design)

Lava
Lava flames are added as a threat for the player in the simulated platform. The lava can only
be seen at the underground environment of the platform. Player agent interacting with the lava
object results a restart of the application.

Figure 15: lava (author's design)

M.H. RIFNAZ 20
Helicopter

The rescue helicopter is the main end goal of the player agent to complete the simulated
scenario. The helicopter is available at the end of the platform, on top of the mountain. The
helicopter integrated with 3D audio; hence the audio level changes as per the player location.
The helicopter is activated, as the player agent interacts with the agent object. When interacted,
the helicopter moves away from left to right, carrying the player agent.

Figure 16: helicopter (author's design)

Boat

The boat is added as an alternative option of reaching the end goal of the player agent to
complete the simulated scenario. The boat is not started, until the player agent has activated
the boat by using the coin machine. The boat moves while carrying the player agent when the
boat is activated.

Figure 17: boat (author's design)

M.H. RIFNAZ 21
M.H. RIFNAZ 22
Lava tile

The lava tile can be seen at the underground environment of the simulated platform. The Lava
tile is added for the player to safely travel from one end to the other, without interacting with
the lava flames.

Figure 18: lava tile (author's design)

Medicine

The player agent is at the ‘injured’ state, at the start of the scenario. The medicine object is
obtainable in the simulated scenario, which grants the player to be in ‘healthy’ state and
perform jump mechanics.

Figure 19: medicine (author's design)

M.H. RIFNAZ 23
Coin

Coin object is obtainable in the simulated scenario for the player agent. The coin objects
provide the player agent, the ability to activate and start the boat by interacting with the coin
machine.

Figure 20: coin (author's design)

5.2 Controls
Agent controls
Left: A
Right: D
Jump: Space bar
Skipping messages and interactions: Enter
Pause and resume game: P
Scenario
The scenario begins with the player agent spawning at the left start of the grass tile with the
‘injured state’. The player can move left and right, however cannot trigger jump mechanics
during the ‘injured’ state. The goal of the game is to reach the rescue team to survive the
simulated platform.

M.H. RIFNAZ 24
Step 1: Forest man message
The player agent should move towards the forest man who is available at the left corner of the
grass tile platform. The forest man provides a message on the threats, challenges, and the end
goal. The message only appears once when the player agent spawns. The message can be
ignored, and gameplay can be resume by pressing ‘enter’ keyword.

Figure 21: step 1 (author's design)

Step 2: obtaining medicine

The medicine must be obtained by the player agent to change the current state to reach the end
goal. The medicine can be found at the underground environment of the platform.

Figure 22: step 2.1 (author's design)

M.H. RIFNAZ 25
The medicine can be obtainable by moving near the object. Once interacted with the medicine,
a message is displayed stating that it will provide the player jumping ability.

Figure 23: step 2.2 (author's design)


Step 3: passing animal trap

The player agent is required to be on the grass tile to reach the end goal. The player agent must
move near the animal trap and press the ‘space bar’ to pass the anima trap.

Figure 24: step 3 (author's design)

M.H. RIFNAZ 26
Step 4: Going on water

The player is required to going on water to get to the other side of the platform. Jumping to the
water plays water jump audio.

Figure 25: step 4.1 (author's design)


The jump ability of the player agent is reduced when on water, hence the player is required to
move at the end of water level to perform the jump to get on the grass tile.

Figure 26: 4.2 (author's design)

M.H. RIFNAZ 27
Step 5: passing wild animal

The player agent is challenged to face the wild animal threat. The wild animal roars, however,
does not perform any physical movement, until it detects the player has entered to the pit.

Figure 27: 5.1 (author's design)


The wild animal performs movement mechanics and moves left to right attempting to attack
the player as soon as the player agent drops into the pit. The player agent should perform the
jump mechanic to pass the wild animal threat to safely survive.

Figure 28: 5.1 (author's design)

M.H. RIFNAZ 28
Step 6: Rescue helicopter

The rescue helicopter can be seen at the end of the platform. The player agent is required to
get on the helicopter platform for the helicopter to start.

Figure 29: step 6.1 (author's design)

The rescue helicopter flies away carrying player completing the end goal of the simulated
platform.

Figure 30: step 6.2 (author's design)

M.H. RIFNAZ 29
Alternative method of reaching the goal
The player agent is given the opportunity to select either upper ground way or underground
way to reach the end goal. The underground method requires the medicine pill to be obtained
first, then reach the boat to survive the platform.
Step 1: passing lava by lava tile
The player should perform jump mechanics to get on the lava tile to reach the other side of the
underground platform. Once, the player agent gets on tile it brings the player to the safe area.

Figure 31: alternative step 1 (author's design)

Step 2: Obtain coin


The coin must be obtained the by the player agent which is at the other side of the underground
platform.

Figure 32: alternative step 2.1 (author's design)

M.H. RIFNAZ 30
The coin can be obtained by moving near the object, when interacted with it, message appears
stating that coin is taken, and it can be used start the boat.

Figure 33: alternative step 2.2 (author's design)


Step 3: coin machine
The coin machine should be used to activate boat. The player agent is required to move near
the coin machine and press ‘enter’ key to insert the coin to the machine. Once it is entered,
audio of coin machine will be played.

Figure 34: alternative step 3 (author's design)

M.H. RIFNAZ 31
Step 4: Boat
Once the coin is entered to the coin machine, boat is activated. The boat starts when the player
gets on the boat.

Figure 35: alternative step 4.1 (author's design)

Player is required to perform jump mechanic to get on the boat. Once, the player agent is on
the boat, boat is started, and moves away carrying player safely completing the end goal.

Figure 36: alternative step 4.2 (author's design)

M.H. RIFNAZ 32
6 Requirements
6.1 Minimum requirements
Operating System Windows 7 SP1+
MacOS 10.12+
Ubuntu 16.04+

CPU SSE2 instruction set support.

GPU Graphics card with DirectX 10


Table 2: requirement to run application (Unity documentation)

7 Important code snippets


Player left and right movement

Figure 37: player left, right (author's design)

M.H. RIFNAZ 33
For player jump

Figure 38: player jump (author's design)


Player trigger events

Figure 39: player trigger 1.1 (author's design)

M.H. RIFNAZ 34
Figure 40: player trigger 1.2 (author's design)
Game pause when agent interaction

Figure 41: game pause when interaction (author's design)

M.H. RIFNAZ 35
Game pause and resume

Figure 42: game pause and resume (author's design)


Cloud

Figure 43: cloud code (author's design)

M.H. RIFNAZ 36
Wild animal

Figure 44: wild animal 1.1 (author's design)

Figure 45: wild animal 1.2 (author's design)

M.H. RIFNAZ 37
Coin machine

Figure 46: coin machine (author's design)


Boat

Figure 47: boat (author's design)

M.H. RIFNAZ 38
8 Testing
8.1 Test plan
Application name: Boy Scout adventure
Date 29th of April 2022
Test name: Moderated usability test

Goal of the test:


Goal of the test is to test each functional and non-functional component of the application to
ensure that the simulated platform is playable up to the expected degree completing the given
criteria.

Specific area to be tested:


Player movement
Weather
Animal
Coin machine
Game pause
Forest man

Test participants:
Suhaibul Akram Muhammed Azran
Mohommed Hanifa Rifnas
Risiidhan Punniyamoorthy
Kotuwilla Kankanamalage Sujith Prasanna Perera

M.H. RIFNAZ 39
8.2 Test cases
Test case Id: 01 Test designed date: 1st of May
2022.
Module name: Player death

Pre-condition: Player alive


Post-condition: Player death when hit on trap

Test procedure Test title Test data Expected Actual result Pass/fail
result

1. Jump player Unit test to Jump Display Pass.


using space bar test player movement ‘you died’
death
2. Land on the
trap

Table 3: test case 1 (author's design)

M.H. RIFNAZ 40
Test case Id: 02 Test designed date: 1st of May 2022.
Module name: Message by forest man

Pre-condition: no message by forest man


Post-condition: message by forest man

Test Test Test data Expected Actual result Pass/fail


procedure title result

1. Move Unit test Player The Pass.


near forest to test interaction message
man message by forest
by man
2. Receive
forest
message by
man
forest man

Table 4: test case 2 (author's design)

M.H. RIFNAZ 41
Test case Id: 03 Test designed date: 3rd of May
2022.
Module name: Game resume

Pre-condition: game pause with audio


Post-condition: game resume with audio

Test procedure Test title Test data Expected Actual result Pass/fail
result

1. Pause game Unit test to The The game to Weather change audio plays when the game is paused Fail.
using ‘P’ key test game keyword resumed
resume ‘P’ from paused
2. Resume game
state
using ‘P’ key

M.H. RIFNAZ 42
1. Remove Regression - - -
cloud.Play() test to test
game
2. Add
resume
cloud.UnPause()

1. Pause game Unit test to The The Pass


using ‘P’ key test game keyword game to
resume ‘P’ resumed
2. Resume game
from
using ‘P’ key
paused
state

Table 5: test case 3 (author's design)

M.H. RIFNAZ 43
Test case Id: 04 Test designed date: 6th of May
2022.
Module name: Game pause

Pre-condition: game resume


Post-condition: game pause

Test procedure Test title Test data Expected Actual result Pass/fail
result

1. Start the game


Unit test to The The game to Game is not paused Fail.
test game keyword pause
2. Pause game
pause ‘P’
using ‘P’ key

M.H. RIFNAZ 44
1. Define Regression resume - -
variable resume test to test
(bool) game pause
2. Check true
and false

1. Start the game Unit test to The The game Pass


test game keyword to pause
2. Pause game
pause ‘P’
using ‘P’ key

Table 6: test case 4 (author's design)

M.H. RIFNAZ 45
Test case Id: 05 Test designed date: 8th of May 2022.
Module name: Water jump

Pre-condition: jump high


Post-condition: low jump on water

Test Test Test data Expected Actual result Pass/fail


procedure title result

1. Jump into Unit Player Low Pass.


water test interaction jump on
to water
2. Press
test
space bar
water
jump

Table 7: test case 5 (author's design)

M.H. RIFNAZ 46
Test case Id: 06 Test designed date: 12th of May 2022.
Module name: Coin machine

Pre-condition: boat not activated


Post-condition: boat activated

Test Test Test data Expected Actual result Pass/fail


procedure title result

1. Go to Unit test Player Coin to Fail.


the to coin interaction be
machine machine inserted
when
2. Insert
near
coin by
machine
pressing
‘enter’

M.H. RIFNAZ 47
1. Add on Regression - - -
trigger test to test
stay coin
machine
2. Add on
trigger
exit

1. Go to Unit test to Player Coin to Pass


the test coin interaction be
machine machine inserted
when
2. Insert
near
coin by
machine
pressing
‘enter’
Table 8: test case 6 (author's design)

M.H. RIFNAZ 48
Test case Id: 07 Test designed date: 14th of May 2022.
Module name: Boat deactivation

Pre-condition: boat not activated before taking coin


Post-condition: boat not activated after taking coin

Test Test title Test data Expected Actual result Pass/fail


procedure result

1. Take coin Unit test Coin Boat not Pass.


to boat taking, to be
2. Jump on
activation player start
boat
interaction

Table 9: test case 7 (author's design)

M.H. RIFNAZ 49
9 References
1. Burns, E., Laskowski, N. and Tucci, L. (2022). What is Artificial Intelligence (AI).
Techtarget.com [online]. Available at:
https://www.techtarget.com/searchenterpriseai/definition/AI-Artificial-Intelligence
[Accessed 2 May 2022].

2. Docs.unity.com. (n.d.). Unity Documentation. [online] Available at:


https://docs.unity.com/ [Accessed 25 April 2022].

3. Incredibuild. (n.d.). What is Visual Studio? [online] Available at:


https://www.incredibuild.com/integrations/visual-studio [Accessed 3 May 2022].

4. Sinicki, A. (2020). What is Unity? Everything you need to know. [online] Android
Authority. Available at: https://www.androidauthority.com/what-is-unity-1131558/
[Accessed 3 May 2022].

5. Smith, J. (2018). What is Photoshop. [online] Agitraining.com. Available at:


https://www.agitraining.com/adobe/photoshop/classes/what-is-photoshop [Accessed 3
May 2022].

6. Stuart, K. (2021). Think, fight, feel: how video game artificial intelligence is evolving.
The Guardian [online]. Available at:
https://www.theguardian.com/games/2021/jul/19/video-gaming-artificial-intelligence-
ai-is-evolving [Accessed 2 May 2022].

M.H. RIFNAZ 50
Appendix A
Risk management (what are the risks faces and how they are solved)

Technical risks Mitigation Contingency

Power interruption To plan the task accordingly to To use remaining battery


avoid interruption use

Poor internet connection To use hard drivers to share Download application at


setups and files the best time

Poor device performance Avoid multi-tasking Have restart of the device,


share task among the team
members

Application and device crash Reduce multi-tasking, avoid Restart the device
poor implementation

Data deletion Save data on a cloud platform Download the save data
from the cloud
Table 10: technical risks (author's design)

M.H. RIFNAZ 51
Appendix B
Gantt chart

Figure 48: Gantt chart (author's design)

M.H. RIFNAZ 52

You might also like