138x Filetype PDF File size 0.42 MB Source: www.cs.rug.nl
University of Derby, Department of Computing and Mathematics Mediterranean College of Thessaloniki Design Patterns For Implementing Game Mechanics Author: Supervisor: Xeni-Christina Kounoukla Dr. Apostolos Ampatzoglou Thessaloniki, May 2016 Abstract Typically, developing computer games is a very complicated task and as a result, many games suffer from poor design and weakened software quality attributes like maintainability. On the other hand, according to the software engineering literature, the application of GoF design patterns in game development is beneficial concerning certain design-time qualities. The aim of this study is to introduce basic instantiations of game mechanics through GoF patterns and evaluate the benefits of this mapping. Having specified implementations on how to instantiate a game design pattern is expected to increase their usability in practice. Nine mappings were identified and a case study on open source software Java games was performed in order to explore the applicability of the approach and evaluate the resulting benefits. Additionally, alternative, non-pattern employing implementations were developed, in order to be directly compared to the GoF pattern involving instances regarding software quality. The findings suggest that the application of GoF design patterns in the implementation of game mechanics improves certain aspects of software quality, while it might, one the other hand, weaken some other. Therefore, it is necessary for a designer to consider several factors, such as the most desired quality attributes and perform a multi-criteria decision analysis. The results provide pointers to interesting areas for future work, as well as advices on design-time decisions in game development. 2 Acknowledgements Firstly, I would like to express my sincere gratitude to my dissertation supervisor Dr. Apostolos Ampatzoglou, whose expertise, patience, continuous support, and generous guidance made it possible for me to conduct this project and related research. His immense knowledge and persistent help inspired and motivated me. He has supported my effort in uncountable ways. It was a great pleasure working with him. I am thoroughly grateful to Dr. Tasos Stylianou for his insightful comments, suggestions, and encouragement during the course of this project. Last but not least, I would also like to thank all my Professors who put their faith in me. Their knowledge and commitment to the highest standards were a constant source of inspiration. 3 Table of Contents Abstract .......................................................................................................................... 2 Acknowledgements ........................................................................................................ 3 List of Figures and Tables.............................................................................................. 6 1. Introduction ............................................................................................................... 7 1.1 Motivation ........................................................................................................... 8 1.2 Aim and Objectives ............................................................................................. 8 2. Literature Review.................................................................................................... 10 2.1 Background Concepts ....................................................................................... 10 2.1.1 What Is a Design Pattern? .......................................................................... 10 2.1.1 Game Design Patterns ................................................................................ 10 2.1.2 GoF Design Patterns ................................................................................... 11 2.1.3 Software Quality Attributes ......................................................................... 12 2.2 Related Work and Contribution ........................................................................ 14 3. Research Methodology ........................................................................................... 16 3.1 Research Questions ........................................................................................... 16 3.2 Cases and Units of Analysis (Sampling) ........................................................... 16 3.3 Data Collection ................................................................................................... 17 3.4 Data Analysis ..................................................................................................... 18 4. Findings and Results ............................................................................................... 19 4.1 Mappings Between Game and GoF Design Patterns ........................................ 19 4.1.1 Implementation of Turn-based Games with Template Method.................. 19 4.1.2 Implementation of Agents with Strategy .................................................... 20 4.1.3 Implementation of Power-Ups with Visitor ............................................... 21 4.1.4 Implementation of Game World with Composite ...................................... 22 4
no reviews yet
Please Login to review.