General information

Subject type: Mandatory

Coordinator: Juan José Pons López

Trimester: Second term

Credits: 4

Teaching staff: 

Enric Sesa Nogueras

Teaching languages

  • Catalan

Documentation mostly in English. Language used in class: Catalan. Exercises and tests in Catalan and / or English. 


Specific skills
  • E4. Design a game and its monetization, taking into account the different parameters and variables that govern the business model of the product.

  • E6. Develop video games in high-level programming languages ​​in graphics engines based on specifications.

Transversal competences
  • T1. Communicate in a third language, preferably English, with an appropriate level of oral and written communication and in accordance with the needs of graduates.

  • T2. Work as a member of an interdisciplinary team either as an additional member or performing management tasks in order to contribute to developing projects with pragmatism and a sense of responsibility, making commitments and taking into account available resources.


This subject aims to introduce degree students to the field of artificial intelligence, and specifically to computational behaviour, showing them the application of some of its techniques in the construction of video games. Issues such as movement-based behaviors, including wayfinding, and a small range of decision-making mechanisms of a reactive nature are seen. The theoretical aspects are worked on, in an expository way, and their subsequent practical application, aimed at the resolution, often guided, of small problems. The class sessions combine both aspects in order to achieve a good balance between them. The practices (compulsory) and exercises in class and at home make up the evaluation model of the subject. 

This subject should be taken once the entire first year and the "programming in interpreted languages" subject of the second year have been passed. It would also be advisable to have passed the subject "Development of 2D games".



Topic 1. Introduction. AI and AI for games. Computational behaviors

Topic 2. Motion control: "Steering behaviors"

2.1 Basic and derived behaviors: seek, arrive, wander, velocity matching,...

2.2 Combination of behaviors. Flocking

Topic 3. Pathfinding: "Pathfinding"

3.1 Representation of space: graphs

3.2 The A star algorithm

Item 4. Decision making

4.1 State machines

4.2 Behavioral trees



Evaluation system

The grade of each student will be calculated following the following percentages:

A (1,2,3). Laboratory practices / group work: 50% (1/3 50% each)

A4. Final Exam: 50%

Final Note = A (1,2,3) · 0.5 + A4 · 0.5



- A4> = 5 is required to pass the subject. If this grade does not reach 5 then she herself will be the final grade. 

- An activity not delivered or delivered late and without justification (court summons or medical matter) counts as a 0.

- It is the student's responsibility to avoid plagiarism in all its forms. In the case of detecting plagiarism, regardless of its scope, in any assessment activity (including practices), article 8 of the assessment regulations will apply, which entails the automatic suspension of the subject without the possibility of recovery. In addition, the teacher will communicate the situation to the Coordination of the Degree so that it can take applicable measures in terms of disciplinary regime. In the context of this subject, plagiarism also means using and/or adapting code that has not been developed entirely individually (or within the group in the case of group activities). Facilitating code that results in plagiarism is also a form of plagiarism and will be treated in the same way. In summary, we can say that assessment activities must be solved in a strictly non-collaborative way (in the case of group activities, collaboration cannot go beyond the group itself). 



- It is necessary to obtain a mark> = 5 in the final exam of recovery to pass the asignatura.

- The mark of the recovery exam will be applied to the A4 activity (and the formula Final Grade = A (1,2,3) · 0.5 + A4 · 0.5 will be applied again) 

- In case of passing the recovery (A (1,2,3) · 0.5 + A4 · 0.5> = 5) the maximum final mark of the subject will be 5 




Millington, Ian (2019). AI for games. Boca Raton, FL: CRC Press, Taylor & Francis Group.


Buckland, Matt (2009). Programming game AI by example. Plano, TX: Wordware Publ.