Setup SDL2 with Visual Studio Code and mingw64 on Windows

Recently I changed my setup from macOS to Windows, and I’d like to do some experiments with GameDev in Windows. So one of the first things that I did was try to set up my dev environment and test some SDL2 code. This is a simple guide to how to setup SDL2 with Visual Studio Code and mingw64, for me worked and I hope that you can start with SDL2 in Windows. Installing the tools. The first thing that we need to install is Visual Studio Code editor. Download, install, and launch VS Code. You need to install the C/C++ …

Read moreSetup SDL2 with Visual Studio Code and mingw64 on Windows

SFML Template to start with your game

If you have setup SFML  with the tutorial that I wrote, the example is easy but is not very useful if you want to create more complex games. In this post, I going to show you how I create a simple Game class to have more control about the game loop, the user input and the frame rate. First, you need to create a Game.h and Game.cpp files. In your Game.h write this code #ifndef GAME_H #define GAME_H #include <SFML/Graphics.hpp> class Game { public: Game(); void Run(); private: void processEvents(); void update(sf::Time deltaTime); void render(); void handlePlayerInput(sf::Keyboard::Key key, bool isPressed); sf::RenderWindow mWindow; …

Read moreSFML Template to start with your game

GBA Development setup in macOS

To develop in GBA we need the tools to do it, and installing it in macOS is simple even if they take a few steps. Install pacman The first thing we must do is install pacmac, which will allow us to download the devkitpro for the GBA, to install it we must go to the following URL: https://github.com/devkitPro/pacman/releases/tag/v1.0.2 And we will download devkitpro-pacman-installer.pkg. Once it has been downloaded, we install the package. The following will appear:: So, we need to go to System Preferences -> Security & Privacy  and allow the permissions: Follow the steps to install the package. Once that …

Read moreGBA Development setup in macOS

OpenGL Setup in macOS

We have configured SFML in macOS, now we’re going to configure OpenGL with macOS and Xcode. First, you need to install GLFW brew install glfw Then, you need to download GLAD to get the OpenGL headers: Use gl version 4.1 if you want to be compatible with macOS and in Profile select Core. Click in Generate. Download the glad.zip and unzip in your Download folder. https://glad.dav1d.de Once you are downloaded and unzipped the folder, put the glad and KHR folders in the /usr/local/include directory of your mac. Creating the Xcode Project After installed GLFW and downloading the glad files, is …

Read moreOpenGL Setup in macOS

About my learning of GameDev

For a long time I wanted to create video games; In fact, it was thanks to RPG Maker that I start to learn programming and I liked it, and that’s why I became a software developer After a while I finally set out to really develop a game and release something, more than anything like a hobby, since I like everything that involves the game dev and also because it is very different from traditional programming. I have tried some engines and sometimes I don’t feel at all comfortable, since I want to learn how everything works from inside and …

Read moreAbout my learning of GameDev

SFML 2.5.1 setup on macOS with CLion

I know that the title is very specific but that is the platform that I am doing some experiments with SFML. So, if you want to create games with SFML and you have macOS and you want to use CLion as IDE just follow the next steps: Install SFML There are a lot ways to install SFML but the easiest is to install it with brew brew install sfml With this command, you’re going to install the version 2.5.1. Create the project with CLion Now is time to create a new project with CLion, put the name that you want …

Read moreSFML 2.5.1 setup on macOS with CLion

Why C# is (one of) my favorite language?

My first approach with C# was when I was studying my career; a guy from Microsoft came to my school to do a chat about C# technologies and one of them was Windows Phone. So I started to learn C# and create Windows Phone apps (I won a Nokia for that 🙂 ). After one year, I started to create C# videos on YouTube and was a popular channel in its time, now is abandoned, but I received very good comments about that course in YouTube, even of teachers that send their students to watch that videos. For some reasons, …

Read moreWhy C# is (one of) my favorite language?

Install Elixir in Debian/Ubuntu using precompiled packages

Today I had the necessity to update a production server using Debian to Elixir 1.9.2. The update from Elixir 1.6 to 1.9.2 was really easy but I will put my steps if anybody has the same requirement. We will need three packages installed in our server: wget unzip Erlang 20 or up Installing Elixir First, we need to go to our tmp folder to download the precompiled package, create a directory to unzip the package and then unzip it. cd /tmp wget https://github.com/elixir-lang/elixir/releases/download/v1.9.2/Precompiled.zip mkdir elixir_precompiled mv Precompiled.zip elixir_precompiled/ unzip Precompiled.zip Now we have all the necessary stuff to get starting …

Read moreInstall Elixir in Debian/Ubuntu using precompiled packages