1. Using AI in Computer Games (AHH - Algorithms, Heuristics And Hacks)

NWC603COM – Using AI in Computer Games                                                        Rachel Osho                                                                                                                                              ID: 309740
Assignment 1 – Theory One


NWC603COM – Using AI in Computer Games                                                        Rachel Osho                                                                                                                                              ID: 309740
Assignment 1 – Theory One


Introduction

In this assignment I will be giving an evaluation of the core AI(Artificial Intelligence) elements and their suitability to different game contexts and then generate ideas and concepts to use AI elements in a computer game. I will also be analysing the strengths and weaknesses of the techniques and what type of games they will be included in.

What is Artificial intelligence and How is it used in gaming?

As the human brain is the most complex object in the world artificial intelligence has been created. Artificial intelligence is basically the creation of a machine with the ability to solve problems that are usually solved by us humans by the use our intelligence”. Artificial intelligence is literally everywhere within the world that you can think of, AI is in our homes, phones and cars and it even used within gaming.

Artificial intelligence is used in gaming in regards to NPC’s which are non-player characters. Artificial intelligence is used as a way of the NPC’s being able to interact with its environment

An example of where artificial intelligence is used in the game skyrim. Skyrim uses artificial intelligence so that the NPC's will be more independent and self-sufficient


AHH - Algorithms, Heuristics And Hacks

Algorithms

The definition of an algorithm is a basic set of rules, however some of them may be complex these algorithms help make up artificial intelligence. For example should a player in a game be 10 feet away, then the player is required to move towards them and if not then the player shouldn’t do anything. This is an example of how algorithms can be used within gaming. Initiially Pac-man the game is widely known as having AI in it as it was one of the very first games that had any for of character artificial intelligence. Pac-man uses algorithms that uses a simple set of rules/instructions


In this modern day and age, the games that are being created often use more complex algorithms in the sense that NPC’s or bots are able to react to sounds/line of sight etc. (ref powerpoint) This is more complex as the player can respond/react to the environment or additional stimuli as well as the NPC’s responding/reacting to players. Algorithms are essentially organized via a complex step by step set of rules that can either resolve a problem or complete a task. It can often be said that on their own it can be said that they are not artificial intelligence.

There are many advantages/strengths of using the technique algorithms. The first advantage being it is a clear step by step set of rules that are often a solution given to solve a problem, making it easy to be able to understand. Another advantage to the technique is that as it’s a set of rules, each individual step will have its own logical sequence meaning that it’ll be rational and making it easier to be debugged if needed to be. Following on another advantage is algorithms tend to not be dependent on a language that is used for programming. Therefore this makes it simple for anyone and literally everyone to understand, should that individual not have any programming knowledge. As well as the advantages there are also disadvantages of using algorithms. Firstly due to the fact that an algorithm isn’t a computer, instead it is the concept of how a program is supposed to be. Another weakness of algorithm is that writing algorithms can be time consuming as it can take a quite a bit of time to write. In regards to algorithm I can say that there are more strengths in comparison to the weaknesses.



Heuristics

Heuristics can be applied to AI in gaming as it is the concept of learning from trial and error, in other words learning from any previous mistakes that occurred. In regards to NPC’s (non player character’s), heuristics can be applied throughout AI in gaming. For example when playing a game the NPC could potentially get stuck as it gets trapped attempting to walk towards a particular direction e.g. walking into a lake. As the NPC potentially tries to carry out this action multiple times, this will then result in the NPC discovering that, that move can not be carried out. Heuristics and algorithms go hand in hand, even though heuristics breaks the simple set of rules and doesn’t continue to repeatedly carry out the action e.g. walking into a lake. Instead it will break the algorithm and learn from prior mistakes and then eventually the NPC will come up with a solution through trial and error and by walking around the lake as opposed to continuing to walk into the lake.

Even though I have previously stated that algorithms on their own are not artificial intelligence. However when you combine the two, algorithms and heuristics become artificial intelligence as the heuristic are basically a method for the algorithms. Warcraft is an example of a game the uses heuristics within the game.


Related imageRelated imageThe purpose of a heuristic in gaming is to create a new solution based on trial and error which is done within good timing, in order to be able to solve the issue that arises. A good and reasonable timing in regards to heuristics within gaming is a key factor, for example should the NPC begin to get chased by a zombie throughout the game, the NPC will need to be able to derive at a solution quite quickly on how to escape and think fast on its feet e.g. turn left in order to get away from the zombie in good timing so that the NPC does not get killed, so good timing is very important. (Gallear, 2017)

These are the four steps of hueristics (A break down of the trial and error):

1.  Optimality
2. Completeness
3. Accuracy
4. Execution

Furthermore there are several benefits of hueristics, firstly lets say a gamer is playing a game and that individual is trying to find the best solution to a task within a level through trial and error and they have to go through many tries to complete the task. This can be seen as a good thing as player can then go and supply the developer with some feedback that is very worthy of knowing so that the designer of the game can potentially go back and improve the game. Heuristics also allow you to attain any useful feedback much earlier and help you tackle any issues/concerns in the design procedure. Another advantage of hueristics is that it is a method that allows you to discover and explore other potential concerns. In contrast to the benefits of hueristics, it can also be a hindrance as it has some weaknesses. One of the weaknesses of hueristics is that in order to use hueristics to your advantage then essentially you are required to have the experience and insight in order to be able to implement the hueristics more adequately. As a result of not having the insight or either the experience then you will not be able implement the hueristics as you do not have the knowledge and this is a major weakness. Another weakness that lies with hueristics is that whilst assessing the dynamics of the hueristics, this can lead to the identification of insignificant issues and less bigger issues.

Hacks

A hack is when an artificial intelligence entity that uses data that they are not supposed to be made accessible as this information should be prohibited. Essentially hack is a kind of artificial intelligence used in games (Gallear, 2017) There are multiple games for example where the AI player would respond to things that they should not be able to have access to. So whilst playing a game, should the AI player open a door that’s not supposed to be opened and a bunch of bats fly out and the AI player gets scared, this would also be known as a hack as the AI player will react in a way that’s not expected and is responding to the trigger that it sets off. There are quite a few games that includes hacks, one of them being puzzle quest.

In regards to artificial intelligence in games there are a lot of hacks within a game this which is more or less a disadvantage because having hacks within a game, is that this can often lead the game to be impractical and unrealistic for the player as a result of there not being hacks in real life, so it can be seen as somewhat unreal. Due to this the player can potentially see the game as very idealistic leading to their gamer experience being ruined. However on the other hand it can be argued that a hack within a game can be an advantage to the player. This is due to the AI player already having the knowledge of what is going to come next, or take place should the character set off any specific triggers.

Comments

Popular posts from this blog

4. Using AI in Computer Games (Pathfinding Concepts)

NWC603COM ASSIGNMENT TWO - AI and Games

5. Using AI in Computer Games (Decision making concepts)