SFML game development learn how to use SFML 2.0 to develop your own feature-packed game

SFML Game Development is a fast-paced, step-by-step guide, providing you with all the knowledge and tools you need to create your first game using SFML 2.0.SFML Game Development addresses ambitious C++ programmers who want to develop their own game. If you have plenty of ideas for an awesome and uni...

Descripción completa

Detalles Bibliográficos
Otros Autores: Haller, Jan. author (author), Hansson, Henrik Vogelius. author, Moreira, Artur. author
Formato: Libro electrónico
Idioma:Inglés
Publicado: Birmingham : Packt Publishing 2013
Edición:1st ed
Colección:Community experience distilled.
Materias:
Ver en Biblioteca Universitat Ramon Llull:https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009628708106719
Tabla de Contenidos:
  • Cover; Copyright; Credits; Foreword; About the Authors; About the Reviewers; www.PacktPub.com; Table of Contents; Preface; Chapter 1: Making a Game Tick; Introducing SFML; Downloading and installation; A minimal example; A few notes on C++; Developing the first game; The Game class; Game loops and frames; Input over several frames; Vector algebra; Frame-independent movement; Fixed time steps; Other techniques related to frame rates; Displaying sprites on the screen; File paths and working directories; Real-time rendering; Adapting the code; Summary
  • Chapter 2: Keeping Track of Your Textures - Resource ManagementDefining resources; Resources in SFML; Textures; Images; Fonts; Shaders; Sound buffers; Music; A typical use case; Graphics; Audio; Acquiring, releasing, and accessing resources; An automated approach; Finding an appropriate container; Loading from files; Accessing the textures; Error handling; Boolean return values; Throwing exceptions; Assertions; Generalizing the approach; Compatibility with sf::Music; A special case - sf::Shader; Summary; Chapter 3: Forge of the Gods - Shaping Our World; Entities; Aircraft
  • Alternative entity designsRendering the scene; Relative coordinates; SFML and transforms; Scene graphs; Scene nodes; Node insertion and removal; Making scene nodes drawable; Drawing entities; Connecting entities with resources; Aligning the origin; Scene layers; Updating the scene; One step back - absolute transforms; The view; Viewport; View optimizations; Resolution and aspect ratio; View scrolling; Zoom and rotation; Landscape rendering; SpriteNode; Landscape texture; Texture repeating; Composing our world; World initialization; Loading the textures; Building the scene; Update and draw
  • Integrating the Game classThe run method; Summary; Chapter 4: Command and Control - Input Handling; Polling events; Window events; Joystick events; Keyboard events; Mouse events; Getting the input state in real time; Events and real-time input - when to use which; Delta movement from the mouse; Playing nice with your application neighborhood; A command-based communication system; Introducing commands; Receiver categories; Command execution; Command queues; Handling player input; Commands in a nutshell; Implementing the game logic; A general-purpose communication mechanism
  • Customizing key bindingsWhy a player is not an entity; Summary; Chapter 5: Diverting the Game Flow - State Stack; Defining a state; The state stack; Adding states to StateStack; Handling updates, input, and drawing; Input; Update; Draw; Delayed pop/push operations; The state context; Integrating the stack in the Application class; Navigating between states; Creating the game state; The title screen; Main menu; Pausing the game; The loading screen - sample; Progress bar; ParallelTask; Thread; Concurrency; Task implementation; Summary; Chapter 6: Waiting and Maintenance Area - Menus
  • The GUI hierarchy, the Java way