1. Trang chủ
  2. » Công Nghệ Thông Tin

AI for games developer

895 328 0
Tài liệu đã được kiểm tra trùng lặp

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 895
Dung lượng 5,26 MB

Nội dung

Sách tham khảo trí tuệ nhân tạo

Ian Millington crosses the boundary between academic and professional game AI with his book Artificial Intelligence for Games. Most books either lack academic rigor or are rigorous with algorithms that won’t work under the CPU constraints imposed by modern games. This book walks a line between the two and does it well. It explains algorithms rigorously while also discussing appropriate implementation details such as scheduling AI over time and using the right data structures. I will be using this book for my Game AI course. —Jessica D. Bayliss, Ph.D. Rochester Institute of Technology This is the first serious attempt to create a comprehensive reference for all game AI prac- tices,terminology,andknow-how.Workslikethisarebadlyneededbythematuring video games industry. Systematic yet accessible, it is a must-have for any student or pro- fessional. —Marcin Chady, Ph.D. Radical Entertainment This book promises to be the closest I’ve seen to what is needed in the field. I would highly recommend it for people in the industry. —John Laird University of Michigan Ian Millington’s book is a comprehensive reference to the most widely used techniques in game AI today. Any game developer working on AI will learn something from this book, and game producers should make sure their AI programmers have a copy. —Dr. Ian Lane Davis Mad Doc Software The Morgan Kaufmann Series in Interactive 3D Technology Series Editor: David H. Eberly, Geometric Tools, Inc. The game industry is a powerful and driving force in the evolution of computer tech- nology. As the capabilities of personal computers, peripheral hardware, and game consoles have grown, so has the demand for quality information about the algo- rithms, tools, and descriptions needed to take advantage of this new technology. To satisfy this demand and establish a new level of professional reference for the game de- veloper, we created the Morgan Kaufmann Series in Interactive 3D Technology.Books in the series are written for developers by leading industry professionals and academic researchers, and cover the state of the art in real-time 3D. The series emphasizes prac- tical, working solutions and solid software-engineering principles. The goal is for the developer to be able to implement real systems from the fundamental ideas, whether it be for games or for other applications. Artificial Intelligence for Games Ian Millington Better Game Characters by Design: A Psychological Approach Katherine Isbister Visualizing Quaternions Andrew J. Hanson 3D Game Engine Architecture: Engineering Real-Time Applications with Wild Magic David H. Eberly Real-Time Collision Detection Christer Ericson Physically Based Rendering: From Theory to Implementation Matt Pharr and Greg Humphreys Essential Mathematics for Games and Interactive Applications: A Programmer’s Guide James M. Van Verth and Lars M. Bishop Game Physics David H. Eberly Collision Detection in Interactive 3D Environments Gino van den Bergen Forthcoming X3D: Extensible 3D Graphics for Web Authors Leonard Daly and Don Brutzman Game Physics Engine Development Ian Millington 3D Game Engine Design: A Practical Approach to Real-Time Computer Graphics, 2 nd Edition David H. Eberly Real-Time Cameras Mark Haigh-Hutchinson ARTIFICIAL INTELLIGENCE FOR GAMES IAN MILLINGTON AMSTERDAM • BOSTON • HEIDELBERG LONDON • NEW YORK • OXFORD PARIS • SAN DIEGO • SAN FRANCISCO SINGAPORE • SYDNEY • TOKYO Morgan Kaufmann is an imprint of Elsevier Senior Editor Tim Cox Assistant Editor Rick Camp Editorial Assistant Jessie Evans Publishing Services Manager George Morrison Senior Production Editor Paul Gottehrer Cover Design Chen Design Associates Composition VTEX Typesetting Services Technical Illustration Dartmouth Publishing, Inc. Copyeditor Andrea Raia Proofreader Phyllis Coyne Proofreading Indexer Distributech Interior printer Maple-Vail Book Manufacturing Group Cover printer Phoenix Color Corp. Morgan Kaufmann Publishers is an imprint of Elsevier. 500 Sansome Street, Suite 400, San Francisco, CA 94111 This book is printed on acid-free paper. © 2006 by Elsevier Inc. All rights reserved. Designations used by companies to distinguish their products are often claimed as trademarks or registered trademarks. In all instances in which Morgan Kaufmann Publishers is aware of a claim, the product names appear in initial capital or all capital letters. Readers, however, should contact the appropriate companies for more complete information regarding trademarks and registration. No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form or by any means—electronic, mechanical, photocopying, scanning, or otherwise—without prior written permission of the publisher. Permissions may be sought directly from Elsevier’s Science & Technology Rights Department in Oxford, UK: phone: (+44) 1865 843830, fax: (+44) 1865 853333, E-mail: permissions@elsevier.com. You may also complete your request on-line via the Elsevier homepage (http://elsevier.com), by selecting “Support & Contact” then “Copyright and Permission” and then “Obtaining Permissions.” Library of Congress Cataloging-in-Publication Data Application submitted ISBN 13: 978-0-12-497782-2 ISBN 10: 0-12-497782-0 ISBN 13: 978-0-12-373661-1 (CD-ROM) ISBN 10: 0-12-373661-7 (CD-ROM) For information on all Morgan Kaufmann publications, visit our Web site at www.mkp.com or www.books.elsevier.com Printed in the United States of America 06070809 54321 To Co no r A BOUT THE A UTHOR Ian Millington is a partner of Icosagon Ltd. (www.icosagon.com), a consulting com- pany developing next-generation AI technologies for entertainment, modeling, and simulation. Previously he founded Mindlathe Ltd, the largest specialist AI middle- ware company in computer games, working with on a huge range of game genres and technologies. He has a long background in AI, including PhD research in complexity theory and natural computing. He has published academic and professional papers and articles on topics ranging from paleontology to hypertext. vi C ONTENTS A BOUT THE A UTHOR vi L IST OF F IGURES xxi A CKNOWLEDGMENTS xxix P REFACE xxxi A BOUT THE CD-ROM xxxiii P ART I AI AND G AMES 1 C HAPTER 1 I NTRODUCTION 3 1.1 W HAT I S AI? 4 1.1.1 Academic AI 5 1.1.2 Game AI 7 1.2 M Y M ODEL OF G AME AI 9 1.2.1 Movement 10 1.2.2 Decision Making 10 1.2.3 Strategy 11 1.2.4 Infrastructure 11 1.2.5 Agent-Based AI 12 1.2.6 In the Book 12 1.3 A LGORITHMS ,D ATA S TRUCTURES , AND R EPRESENTATIONS 13 1.3.1 Algorithms 13 1.3.2 Representations 16 vii viii Contents 1.4 O NTHE CD 17 1.4.1 Programs 17 1.4.2 Libraries 18 1.5 L AYOUT OF THE B OOK 19 C HAPTER 2 G AME AI 21 2.1 T HE C OMPLEXITY F ALLACY 21 2.1.1 When Simple Things Look Good 21 2.1.2 When Complex Things Look Bad 22 2.1.3 The Perception Window 23 2.1.4 Changes of Behavior 23 2.2 T HE K IND OF AI IN G AMES 24 2.2.1 Hacks 24 2.2.2 Heuristics 25 2.2.3 Algorithms 27 2.3 S PEED AND M EMORY 27 2.3.1 Processor Issues 28 2.3.2 Memory Concerns 31 2.3.3 PC Constraints 32 2.3.4 Console Constraints 32 2.4 T HE AI E NGINE 35 2.4.1 Structure of an AI Engine 35 2.4.2 Toolchain Concerns 37 2.4.3 Putting It All Together 38 P ART II T ECHNIQUES 39 C HAPTER 3 M OVEMENT 41 3.1 T HE B ASICS OF M OVEMENT A LGORITHMS 42 3.1.1 Two-Dimensional Movement 43 3.1.2 Statics 44 3.1.3 Kinematics 47 3.2 K INEMATIC M OVEMENT A LGORITHMS 51 3.2.1 Seek 52 3.2.2 Wandering 55 ix 3.2.3 On the CD 57 3.3 S TEERING B EHAVIORS 57 3.3.1 Steering Basics 58 3.3.2 Variable Matching 58 3.3.3 Seek and Flee 59 3.3.4 Arrive 62 3.3.5 Align 66 3.3.6 Velocity Matching 69 3.3.7 Delegated Behaviors 70 3.3.8 Pursue and Evade 71 3.3.9 Face 74 3.3.10 Looking Where You’re Going 75 3.3.11 Wander 76 3.3.12 Path Following 79 3.3.13 Separation 85 3.3.14 Collision Avoidance 88 3.3.15 Obstacle and Wall Avoidance 94 3.3.16 Summary 99 3.4 C OMBINING S TEERING B EHAVIORS 100 3.4.1 Blending and Arbitration 100 3.4.2 Weighted Blending 101 3.4.3 Priorities 107 3.4.4 Cooperative Arbitration 111 3.4.5 Steering Pipeline 113 3.5 P REDICTING P HYSICS 126 3.5.1 Aiming and Shooting 126 3.5.2 Projectile Trajectory 127 3.5.3 The Firing Solution 129 3.5.4 Projectiles with Drag 132 3.5.5 Iterative Targeting 134 3.6 J UMPING 140 3.6.1 Jump Points 141 3.6.2 Landing Pads 145 3.6.3 Hole Fillers 149 3.7 C OORDINATED M OVEMENT 151 3.7.1 Fixed Formations 151 3.7.2 Scalable Formations 153 3.7.3 Emergent Formations 153 3.7.4 Two-Level Formation Steering 155 3.7.5 Implementation 158 3.7.6 Extending to More than Two Levels 165 3.7.7 Slot Roles and Better Assignment 167 . principles. The goal is for the developer to be able to implement real systems from the fundamental ideas, whether it be for games or for other applications.. xxxiii P ART I AI AND G AMES 1 C HAPTER 1 I NTRODUCTION 3 1.1 W HAT I S AI? 4 1.1.1 Academic AI 5 1.1.2 Game AI 7 1.2 M Y M ODEL OF G AME AI 9 1.2.1 Movement

Ngày đăng: 21/11/2013, 15:55

TỪ KHÓA LIÊN QUAN