{"id":149,"date":"2020-12-26T21:36:03","date_gmt":"2020-12-27T02:36:03","guid":{"rendered":"https:\/\/cynthiamcmahon.ca\/blog\/?page_id=149"},"modified":"2025-03-05T07:37:12","modified_gmt":"2025-03-05T12:37:12","slug":"monogame-tutorials","status":"publish","type":"page","link":"https:\/\/cynthiamcmahon.ca\/blog\/monogame-tutorials\/","title":{"rendered":"MonoGame"},"content":{"rendered":"\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/mg-tutorials-1024x576.png\" alt=\"MonoGame Tutorials\" class=\"wp-image-262\" srcset=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/mg-tutorials-1024x576.png 1024w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/mg-tutorials-300x169.png 300w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/mg-tutorials-768x432.png 768w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/mg-tutorials.png 1280w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<h2 class=\"wp-block-heading post-entry\">MonoGame Tutorials!<\/h2>\n\n\n\n<p>These are my general MonoGame tutorials, not part of a larger project. If you are looking for my Shadow Monster tutorials they can be found on the <a href=\"https:\/\/cynthiamcmahon.ca\/blog\/shadow-monsters\/\">Shadow Monsters MonoGame Tutorials<\/a> page. My Eyes of the Dragon tutorials they can be found on the <a href=\"https:\/\/cynthiamcmahon.ca\/blog\/eyes-of-the-dragon\/\">Eyes of the Dragon MonoGame Tutorials<\/a> page. The Eyes of the Dragon 3.0 tutorials are on the Eyes of the Dragon 3.0 page. Finally, my Forest Rush tutorials they can be found on the <a href=\"https:\/\/cynthiamcmahon.ca\/blog\/forest-rush\/\">Forest Rush MonoGame Tutorials<\/a> page.<br><\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading tutorial-title\">MonoGame For The Absolute Beginner<\/h2>\n\n\n\n<p>These MonoGame tutorials are aimed at somebody with no prior, or very little, MonoGame experience. They assume a basic understanding of the C# programming language.<\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 00<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1llOR5eNY_pMRz6GM-vLLbZLuMdp_Mz4K\/view?usp=sharing\">Understanding MonoGame<\/a> &#8211; This tutorial covers the basics of MonoGame, describing the skeleton of a game and sharing some key insights.<\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 01<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1dypx0kFD_GgcydGW9KFm0qV62_4HJE2A\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Getting Started<\/a> &#8211; This tutorial covers the basic of loading an image, drawing it on the screen the moving it around the screen.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 02<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1Ztd6Tri3DukQlIur47r4frrGMOMq0vW0\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Keyboard Input<\/a> &#8211; This tutorial covers the basic of loading an image, drawing it on the screen the moving it using the keyboard. It also moves the sprite at a uniform speed and constant speed regardless of frame rate.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 03<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/15eN9zW5_qTbfz3xolIznCfIGYeUzJUB5\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Scaling and Rotating Sprites<\/a> &#8211; This tutorial covers the basic of loading an image, drawing it on the screen then moving it using the keyboard as well as scaling and rotating it.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 04<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/18Bg95TleSU_wqqidgHmLUICc8-aLq5g8\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Going 3D<\/a> &#8211; This tutorial is about how to draw a rectangle in 3D.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 05<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1qRW3zWOpdBZtm8apt1N2eUlOrHgrqrdi\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Going 3D, Texturing, Scaling and Rotating<\/a> &#8211; This tutorial is about how to draw a textured rectangle in 3D and how to scale and rotate it.<br><\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 06<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1QwrsQd0b8KC-Q6AY6vfElmribnFNJWUs\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Going 3D &#8211; Moving and Cube<\/a> &#8211; This tutorial is about how to move objects in 3D space. It also covers creating our first 3D object, a cube.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 07<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1-kRYl9ZWHSchBbsqeJ8Id34wYjft2hve\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Going 3D &#8211; Drawing a Model &#8211; This tutorial is about how to load and render a 3D model.<\/a><a href=\"https:\/\/drive.google.com\/file\/d\/1-kRYl9ZWHSchBbsqeJ8Id34wYjft2hve\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\"><br>\n<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\"><a href=\"https:\/\/drive.google.com\/file\/d\/1-kRYl9ZWHSchBbsqeJ8Id34wYjft2hve\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Tutorial 08<\/a><\/h4>\n\n\n\n<a href=\"https:\/\/drive.google.com\/file\/d\/1-kRYl9ZWHSchBbsqeJ8Id34wYjft2hve\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">\n<\/a>\n\n\n\n<p><\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1gxOHaxrEtd28od3fc3Co3L9zNXCYsth_\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Brick Breaker<\/a> &#8211; In this tutorial, we create our first actual game: a brick breaker.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 09<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1jbV8HlqYXspsgZC-Mg1TQxys0kWgfBmd\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\"><\/a><a href=\"https:\/\/drive.google.com\/file\/d\/1M-apIBn6U3FU1DvhAb7jm8gvezsbBput\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Asteroids Clone<\/a> &#8211; In this tutorial, we create our second game, an Asteroids clone.<br><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Tutorial 10<\/h4>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1djFok3oIb2RRjkLIXAM_sPMTWjzQcdA_\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Animated Sprites<\/a> &#8211; This tutorial covers creating animated sprites using frame animation.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading tutorial-title\">General MonoGame Tutorials<\/h2>\n\n\n\n<h2 class=\"wp-block-heading tutorial-title\">Collision Detection Tutorials<\/h2>\n\n\n\n<p>These MonoGame tutorials are on collision detection between game objects using various techniques. They are aimed and beginner to intermediate MonoGame programmers.<\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Collision Detection Part 01<\/h4>\n\n\n\n<div><p><a href=\"https:\/\/drive.google.com\/file\/d\/1eeHdcAkvDxB5s7P_GVflsRH7r8y_mbu0\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Basic Collision Detection<\/a> &#8211; This tutorial covers the three most common collision detection methods: bounding boxes, per pixel and per pixel on transformed objects. It is aimed at beginners.<\/p><\/div>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Collision Detection Part 02<\/h4>\n\n\n\n<div><p><a href=\"https:\/\/drive.google.com\/file\/d\/1d3ctt6pLoP7Vt3wHc67kISR1wwtGJEQK\/view?usp=sharing\" target=\"_blank\" rel=\"noopener\">Alternate Methods<\/a> &#8211; This tutorial covers two alternate methods of collision detection: multiple bounding boxes and bounding circles.<\/p><\/div>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\" style=\"font-size: 32px; text-align: center;\">MonoGame 3D Tile Engine Tutorials<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"604\" src=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine-1024x604.png\" alt=\"MonoGame 3D Tile Engine tutorial sample\" class=\"wp-image-430\" srcset=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine-1024x604.png 1024w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine-300x177.png 300w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine-768x453.png 768w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine-1536x905.png 1536w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2021\/01\/3D-Tile-Engine.png 1922w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\">Rendering 2 million quads<\/figcaption><\/figure>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 1 &#8211; 3D Rendering<\/h4>\n\n\n\n<p>This tutorial is about creating a tile engine using 3D instead of SpriteBatch. As a result, we will improve performance and gain access to advanced 3D capabilities. This tutorial covers rendering quads and manipulating them. That is, translating, rotating and scaling them.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1e5gobwgpohxRluucQsGP5Ns9TLC90PH7\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Part 1 &#8211; 3D Rendering<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 2 &#8211; Making it Reusable<\/h4>\n\n\n\n<p>This tutorial moves everything to a reusable library. Also, I add a custom shader rather than a basic effect.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1RgjYAUquM4ttg81rWQuC0-jpMzkE7J8G\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Part 2 &#8211; Making it Reusable<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 3 &#8211; Index and Vertex Buffers<\/h4>\n\n\n\n<p>Instead of drawing individual vertices this tutorial moves to drawing using vertex and index buffers. As a result, performance is greatly improved.  I was drawing millions of quads per frame.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1-ZgpOunnS7tyUKlCbMnXGJpJv8Vmvs3j\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Part 3 &#8211; Vertex Buffers<\/a><\/p>\n\n\n\n<p><\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<p><\/p>\n\n\n\n<h2 class=\"wp-block-heading\" style=\"font-size: 32px; text-align: center;\"><mark class=\"annotation-text annotation-text-yoast\" id=\"annotation-text-ac93d5c8-0ad7-486b-9a06-df3d1c70cdd7\"><\/mark>MonoGame Tutorials &#8211; Space Raptor<\/h2>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor-1024x576.png\" alt=\"Shadow Raptor MonoGame Tutorial\" class=\"wp-image-246\" srcset=\"https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor-1024x576.png 1024w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor-300x169.png 300w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor-768x432.png 768w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor-1536x864.png 1536w, https:\/\/cynthiamcmahon.ca\/blog\/wp-content\/uploads\/2020\/12\/Space-Raptor.png 1920w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>The Space Raptor game is a Shoot&#8217;em Up, or Shmup, that takes place in the cold unforgiving regions of space. The objective is to make it through wave after wave of enemies before moving on to the next level.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-css-opacity\"\/>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 1 &#8211; Getting Started<\/h4>\n\n\n\n<p>Here we lay the foundation that will be used throughout the game. It starts with some basic components then moves on to firing bullets, the heart of a shmup. Following that is collision detection between the game objects.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1cDzo-h-Ww48wxCmX1YpeM6idUpVyxN7U\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Part 1 &#8211; Getting Started<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 2 &#8211; More Basics<\/h4>\n\n\n\n<p>We pick up where we left off last and start work on our enemies firing at up. Because we are using scaled sprites I implement pix perfect collision detection. A shmup is no fun without explosions so I add those in as well. As a result, we have a fairly functional game.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/12dpW0nNB26W2-JiBEyv8dPGUEUSafVeB\/view?usp=sharing&quot; target=&quot;_blank\" target=\"_blank\" rel=\"noreferrer noopener\">Part 2 &#8211; More Basics<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading tutorial-title\">Part 3 &#8211; Shields and Power Ups<\/h4>\n\n\n\n<p>What we really need now are shields! Also, we need to make our space raptor stronger. So, adding power ups and shields is the focus of this tutorial.<\/p>\n\n\n\n<p><a href=\"https:\/\/drive.google.com\/file\/d\/1FCUSX8ID1M6yq_exMhWAAEj2cEkYqgBR\/view?usp=sharing\" target=\"_blank\" rel=\"noreferrer noopener\">Part 3 &#8211; Shields and Power Ups<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>MonoGame Tutorials! These are my general MonoGame tutorials, not part of a larger project. If you are looking for my Shadow Monster tutorials they can be found on the Shadow Monsters MonoGame Tutorials page. My Eyes of the Dragon tutorials they can be found on the Eyes of the Dragon MonoGame Tutorials page. The Eyes &hellip; <\/p>\n","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-149","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/pages\/149","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/comments?post=149"}],"version-history":[{"count":47,"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/pages\/149\/revisions"}],"predecessor-version":[{"id":1375,"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/pages\/149\/revisions\/1375"}],"wp:attachment":[{"href":"https:\/\/cynthiamcmahon.ca\/blog\/wp-json\/wp\/v2\/media?parent=149"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}