240-492 Games Programming with Java ::: AI ::: 1 240-492 Games Programming with Java Montri Karnjanadecha Andrew Davison.

Slides:



Advertisements
Similar presentations
Chapter 09 AI techniques in different game genres (Puzzle/Card/Shooting)
Advertisements

Application of Artificial intelligence to Chess Playing Capstone Design Project 2004 Jason Cook Bitboards  Bitboards are 64 bit unsigned integers, with.
CPSC 322 Introduction to Artificial Intelligence October 6, 2004.
ICS 101 Fall 2011 Introduction to Artificial Intelligence Asst. Prof. Lipyeow Lim Information & Computer Science Department University of Hawaii at Manoa.
Introduction to Artificial Intelligence Ruth Bergman Fall 2004.
Introduction to Artificial Intelligence CSE 473 Winter 1999.
PSU CS 370 – Artificial Intelligence Dr. Mohamed Tounsi Artificial Intelligence 1. Introduction Dr. M. Tounsi.
COMP 4640 Intelligent & Interactive Systems Cheryl Seals, Ph.D. Computer Science & Software Engineering Auburn University.
Introduction to Artificial Intelligence Prof. Kathleen McKeown 722 CEPSR, TAs: Kapil Thadani 724 CEPSR, Phong Pham TA Room.
Random Administrivia In CMC 306 on Monday for LISP lab.
PSYCHOLOGY Introduction to Psychology By Dr. Abdullah AL-ZAhrani.
Introduction to Artificial Intelligence ITK 340, Spring 2010.
1 Artificial Intelligence An Introductory Course.
Computer Science 1000 AI – A Brief Overview. Artificial Intelligence definition: many! `` ``The exciting new effort to make computers think... machines.
Artificial Intelligence Dr. Paul Wagner Department of Computer Science University of Wisconsin – Eau Claire.
CSCI 4410 Introduction to Artificial Intelligence.
Artificial Intelligence Introduction (2). What is Artificial Intelligence ?  making computers that think?  the automation of activities we associate.
Introduction (Chapter 1) CPSC 386 Artificial Intelligence Ellen Walker Hiram College.
Artificial Intelligence Lecture No. 3
Introduction to Artificial Intelligence. Content Definition of AI Typical AI problems Practical impact of AI Approaches of AI Limits of AI Brief history.
Lecture 1 Note: Some slides and/or pictures are adapted from Lecture slides / Books of Dr Zafar Alvi. Text Book - Aritificial Intelligence Illuminated.
ICS 101 Fall 2011 Introduction to Artificial Intelligence Asst. Prof. Lipyeow Lim Information & Computer Science Department University of Hawaii at Manoa.
A RTIFICIAL I NTELLIGENCE Introduction 3 October
CSE4/563: Knowledge Representation Recitation September 13, 2010 “Intelligence is the art of good guesswork.” –H.B. Barlow.
If the human brain were so simple that we could understand it, we would be so simple that we couldn't. —Emerson M. Pugh.
Graph Coloring with Ants
WAES 3308 Numerical Methods for AI
Application of Artificial Intelligence to Chess Playing Jason Cook Capstone Project.
Tax Form Advisor Nebela Corina Burca Vlad. Artificial Intelligence What is A.I. ? A simple definition could be : The branch of computer science concerned.
Artificial Intelligence in Game Design Dynamic Path Planning Algorithms.
1 Introduction to Artificial Intelligence (Lecture 1)
Artificial Intelligence: Introduction Department of Computer Science & Engineering Indian Institute of Technology Kharagpur.
Artificial Intelligence
Computational theory techniques in interactive video games.
Artificial Intelligence IES 503 Asst. Prof. Dr. Senem Kumova Metin.
Definitions of AI There are as many definitions as there are practitioners. How would you define it? What is important for a system to be intelligent?
University of Kurdistan Artificial Intelligence Methods (AIM) Lecturer: Kaveh Mollazade, Ph.D. Department of Biosystems Engineering, Faculty of Agriculture,
Introduction to Artificial Intelligence CS 438 Spring 2008.
Chapter 1 Artificial Intelligence Overview Instructor: Haris Shahzad Artificial Intelligence CS-402.
A Brief History of AI Fall 2013 COMP3710 Artificial Intelligence Computing Science Thompson Rivers University.
Othello Artificial Intelligence With Machine Learning Computer Systems TJHSST Nick Sidawy.
Source: CSE 214 – Computer Science II Graphs.
CompSci Problem Solving: Sudoku  Rules of the Game Sudoku is played with a 9 by 9 "board" consisting of nine 3 by 3 sub-boards. The symbols 1 -
CS382 Introduction to Artificial Intelligence Lecture 1: The Foundations of AI and Intelligent Agents 24 January 2012 Instructor: Kostas Bekris Computer.
COMP 4640 Intelligent & Interactive Systems Cheryl Seals, Ph.D. Computer Science & Software Engineering Auburn University.
1 Chapter 7 Advanced Pathfinding Techniques improving performance & quality Reference: Game Development Essentials Game Artificial Intelligence.
1 Artificial Intelligence & Prolog Programming CSL 302.
Stacks Chapter 3 Objectives Upon completion you will be able to
By William Campbell MACHINE LEARNING. OVERVIEW What is machine learning? Human decision-making Learning algorithms Applications.
The Game Development Process: Artificial Intelligence.
Overview of Artificial Intelligence (1) Artificial intelligence (AI) Computers with the ability to mimic or duplicate the functions of the human brain.
Introduction to Artificial Intelligence Prof. Kathleen McKeown 722 CEPSR Tas: Andrew Rosenberg Speech Lab, 7 th Floor CEPSR Sowmya Vishwanath TA Room.
Artificial Intelligence and its Portrayal in Electronic Media
Artificial Intelligence
Othello Artificial Intelligence With Machine Learning
Introduction to Artificial Intelligence
Lecture #1 Introduction
Introduction to Artificial Intelligence
Othello Artificial Intelligence With Machine Learning
COMP 4640 Intelligent & Interactive Systems
CSCI 5582 Artificial Intelligence
Course Instructor: knza ch
Intelligence Are the things shown below, Intelligent?
Systems that THINK Like Humans
EA C461 – Artificial Intelligence Introduction
Games Programming with Java
COMP3710 Artificial Intelligence Thompson Rivers University
Introduction to Artificial Intelligence Instructor: Dr. Eduardo Urbina
Artificial Intelligence
Othello Artificial Intelligence With Machine Learning
Presentation transcript:

Games Programming with Java ::: AI ::: Games Programming with Java Montri Karnjanadecha Andrew Davison

Games Programming with Java ::: AI ::: 2 Chapter 2 Introduction to Artificial Intelligence

Games Programming with Java ::: AI ::: 3 Outline Definition of Artificial Intelligence Uninformed Search Methods Informed Search Methods Game AI

Games Programming with Java ::: AI ::: 4 What is AI? Systems that think like humans –“The exciting new effort to make computer think ….. machine with minds, in the full an literal sense” –“Activities that we associate with human thinking, activities such as decision-making, problem-solving, learning…” Systems that think rationally –“The study of mental faculties through the use of computational models” –“The study of the computations that make it possible to perceive, reason, and act”

Games Programming with Java ::: AI ::: 5 That is AI? (cont’d) Systems that act like humans –“The art of creating machines that perform functions that require intelligence when performed by people” –“The study of how to make computers do things at which, at the moment, people are better” Systems that act rationally –“A field of study that seeks to explain and emulate intelligent behavior in terms of computational processes” –“The branch of computer science that is concerned with the automation of intelligent behavior”

Games Programming with Java ::: AI ::: 6 What is AI? (cont’d) To make the computer think

Games Programming with Java ::: AI ::: 7 Simple AI Stuff A board with tokens

Games Programming with Java ::: AI ::: 8 Closing the gap A board with tokens

Games Programming with Java ::: AI ::: 9 Chase Algorithm if (lx!=dx) // check for non-matching x { if (lx>dx) { lx--; // higher x, so decrease it } else { lx++;// lower x, so increase it } if (ly!=dy) // check for non-matching y { if (ly>dy) { ly--; // higher y, so decrease it } else { ly++;// lower y, so increase it }

Games Programming with Java ::: AI ::: 10 Evade Algorithm if (lx!=dx) // check for non-matching x { if (lx>dx) { lx++; // higher x, so increase it } else { lx--;// lower x, so decrease it } if (ly!=dy) // check for non-matching y { if (ly>dy) { ly++; // higher y, so increase it } else { ly--;// lower y, so decrease it }

Games Programming with Java ::: AI ::: 11 Chasing Struck The simple chase algorithm fails when unmovable blocks are presented

Games Programming with Java ::: AI ::: 12 Evading the Obstacle

Games Programming with Java ::: AI ::: 13 More Advanced Pathfinding A* pathfinding algorithm 1. Create a 2-D integer array as large as the map size 2. Fill all cells with -1 (-1 means not tested yet) 3. For any “blocked” cell, put a large number (e.g. 255) 4. Place a 0 in the target cell

Games Programming with Java ::: AI ::: 14 A* pathfinding algorithm 5. Start at the target cell (the known distance cell) 6. Determine valid adjacent cells 7. Give the adjacent cells a known distance value 8. Repeat step 5 Stop Citeria 1. No adjacent cells 2. The cell of origin gets filled in Path finding

Games Programming with Java ::: AI ::: 15 When It’s All Done 5. Start at the target cell (the known distance cell) 6. Determine valid adjacent cells 7. Give the adjacent cells a known distance value 8. Repeat step 5 Stop Criteria 1. No adjacent cells 2. The cell of origin gets filled in Path finding

Games Programming with Java ::: AI ::: 16 Backtracking In order for the red piece to capture the green piece, the red piece must move to lower-values cells-- from 7->6, 6-> 5, 5->4, 4->3, 3->2, 2->1 and 1->0