Namespace example // Replace with your project name. You are now ready to use Raylib with Beef! I wrote a sample program that draws the raylib-beef logo to the window.Ĭopy and paste this into " Program.bf" under your main project and press "F5" to run. Right-click on your main project and select "Properties.".įrom there, select "Dependencies" from under the "General" dropdown and click the checkbox next to "raylib-beef". You should now see "raylib-beef" in your workspace panel. Go to the safe place where you stored the "raylib-beef" folder, and inside of it, and double-click on the "BeefProj.toml" file. Right-click on "Workspace" (not the tab) and select "Add Existing Project". We only need the "raylib-beef" folder for all purposes covered in this tutorial, so don't worry about any of the other folders or files. Luckily, I already did that which you can clone from GitHub.Įxtract the code to a folder and keep it in a safe place. Raylib is written in C, so to use it we're going to have to write some bindings for it. Let's install Raylib so that we can use it with Beef. Congratulations, you have just created your first Beef program! If you press "F5" now, a console window will appear and quickly disappear. If you try to run your project by pressing "F5", the IDE will ask if you want to auto-generate startup code because there is none. Press "Ctrl+Shift+S" to save your solution and everything in it.Ĭurrently your project is empty. Note: The name of the folder is what the initial startup project will be called.Ī workspace in Beef is similar to a solution in C#, it contains all the projects inside your main project. (Recent Projects blocked out for secrecy.)Ĭlick the "Create Workspace" button, and select the folder you want to create your workspace in. Now that you have Beef installed, open the Beef IDE, and you should see something that looks like this: They may already include fixes for bugs you could encounter and the latest features. If you're reading before version 1.0, I would recommend using the Nightly Releases. You can also join the BeefLang Discord server and ask for help there.įirst, Download and install Beef. The Beef Documentation covers most questions you may have. I'm not going to go over the more advanced stuff. Hoping to increase awareness of the language, I created a very small and simple guide that demonstrates how to use one of my favorite game frameworks, Raylib, alongside one of my favorite languages. If you're already familiar with C# (as I was), you can start using Beef pretty much instantly. Honestly, Beef has been one of my most favorite languages to work with in the past few months, even more than C#!īeef is compiled with no GC, and while I could probably write a whole post on how much I loathe garbage collectors, just know it makes the language really fast. I said I would write another tutorial someday.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |