Beginning C++ Game Programming
eBook - ePub

Beginning C++ Game Programming

Learn C++ from scratch by building fun games

  1. 648 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Beginning C++ Game Programming

Learn C++ from scratch by building fun games

About this book

Get to grips with programming and game development techniques using C++ libraries and Visual Studio 2022 with this updated edition of the bestselling series.

Key Features

  • Create fun games in C++, with this up-to-date guide covering the latest features of C++20 and VS2022
  • Build clones of popular games such as a Timberman clone, a Pong game, a Zombie Survival Shooter, and a platform endless runner game
  • Discover tips to expand your finished games by thinking critically, technically, and creatively

Book Description

Always dreamed of creating your own games? With the third edition of Beginning C++ Game Programming, you can turn that dream into reality! This beginner-friendly guide is updated and improved to include the latest features of VS 2022, SFML, and modern C++20 programming techniques. You'll get a fun introduction to game programming by building four fully playable games of increasing complexity. You'll build clones of popular games such as Timberman, Pong, a Zombie survival shooter, and an endless runner.The book starts by covering the basics of programming. You'll study key C++ topics, such as object-oriented programming (OOP) and C++ pointers and get acquainted with the Standard Template Library (STL). The book helps you learn about collision detection techniques and game physics by building a Pong game. As you build games, you'll also learn exciting game programming concepts such as vertex arrays, directional sound (spatialization), OpenGL programmable shaders, spawning objects, and much more. You'll dive deep into game mechanics and implement input handling, levelling up a character, and simple enemy AI. Finally, you'll explore game design patterns to enhance your C++ game programming skills.By the end of the book, you'll have gained the knowledge you need to build your own games with exciting features from scratch.

What you will learn

  • Set up your game project in VS 2022 and explore C++ libraries such as SFML
  • Build games in C++ from the ground up, including graphics, physics, and input handling
  • Implement core game concepts such as game animation, game physics, collision detection, scorekeeping, and game sound
  • Implement automatically spawning objects and AI to create rich and engaging experiences
  • Learn advanced game development concepts, such as OpenGL shaders, texture atlases, and parallax backgrounds
  • Scale and reuse your game code with modern game programming design patterns

Who this book is for

This book is perfect for you if you have no C++ programming knowledge, you need a beginner-level refresher course, or you want to learn how to build games or just use games as an engaging way to learn C++. Whether you aspire to publish a game (perhaps on Steam) or just want to impress friends with your creations, you'll find this book useful

]]>

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription.
At the moment all of our mobile-responsive ePub books are available to download via the app. Most of our PDFs are also available to download and we're working on making the final remaining ones downloadable now. Learn more here.
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, weโ€™ve got you covered! Learn more here.
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Yes! You can use the Perlego app on both iOS or Android devices to read anytime, anywhere โ€” even offline. Perfect for commutes or when youโ€™re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app.
Yes, you can access Beginning C++ Game Programming by John Horton in PDF and/or ePUB format, as well as other popular books in Computer Science & Programming Games. We have over one million books available in our catalogue for you to explore.

Table of contents

  1. Preface
  2. Welcome to Beginning C++ Game Programming Third Edition!
  3. Variables, Operators, and Decisions: Animating Sprites
  4. C++ Strings, SFML Time: Player Input and HUD
  5. Loops, Arrays, Switch, Enumerations, and Functions: Implementing Game Mechanics
  6. Collisions, Sound, and End Conditions: Making the Game Playable
  7. Object-Oriented Programming โ€“ Starting the Pong Game
  8. AABB Collision Detection and Physics โ€“ Finishing the Pong Game
  9. SFML Views โ€“ Starting the Zombie Shooter Game
  10. C++ References, Sprite Sheets, and Vertex Arrays
  11. Pointers, the Standard Template Library, and Texture Management
  12. Coding the TextureHolder Class and Building a Horde of Zombies
  13. Collision Detection, Pickups, and Bullets
  14. Layering Views and Implementing the HUD
  15. Sound Effects, File I/O, and Finishing the Game
  16. Run!
  17. Sound, Game Logic, Inter-Object Communication, and the Player
  18. Graphics, Cameras, Action
  19. Coding the Platforms, Player Animations, and Controls
  20. Building the Menu and Making It Rain
  21. Fireballs and Spatialization
  22. Parallax Backgrounds and Shaders
  23. Index