C# bindings for raylib, a simple and easy-to-use library to enjoy videogames programming
Branch: master
Clone or download
ChrisDill Initial example update
- Updating examples with new changes.
Latest commit b841a28 Feb 11, 2019


Raylib-cs Logo


C# bindings for raylib 2.0, a simple and easy-to-use library to learn videogames programming (www.raylib.com)


So far, I have only tested on Windows. Tips on making things work smoothly on all platforms is appreciated.

  1. Add the nuget package

  2. Start coding!

using Raylib;
using static Raylib.Raylib;

static class Program
	public static void Main() 
		InitWindow(640, 480, "Hello World");

		while (!WindowShouldClose())

			DrawText("Hello, world!", 12, 12, 20, Color.BLACK);



Tech notes

The bindings are close to the original with a few changes and extensions.

  • Enums are passed in as type instead of int to avoid explicit casting to a int every time.
  • Added constructors for some of the types.

Custom build

  1. Add raygui
  2. Add a file with the following
#include "raylib.h"
#include "easings.h"

#include "physac.h"

#include "raygui.h"


If you have any ideas, feel free to open an issue and tell me what you think. If you'd like to contribute, please fork the repository and make changes as you'd like. Pull requests are warmly welcome.

If you want to request features or report bugs related to the library (in contrast to this binding), please refer to the author's project repo.


raylib-cs (and raylib) is licensed under an unmodified zlib/libpng license, which is an OSI-certified, BSD-like license that allows static linking with closed source software. Check LICENSE for further details.