![]() This is also why you’ll see it doesn’t have any loops or conditional statements - though these might be added in the future if there’s a need for them. It’s important to note that since the focus of the language is fairly specific, it doesn’t have to be general-purpose. ![]() Since it’s meant for tool-assisted speedruns, timing is also very important. For the keyScripter its only goal is to send simulated inputs to the OS, so most of the functionality is designed around making that as straightforward as possible. While designing a language it’s important to think about what you want to achieve with it, and thus what it should (and shouldn’t) be able to do. If you want to dig deeper, be sure to check out the keyScripter repo on GitHub! Language Design I’ve tried to keep everything fairly high-level, so as not to make the post too long. In this post we’re going to go into the design of the keyScripter, and have a look at how the compiler works. ![]() Ideally I wanted to create a tool that would allow anyone with very little programming knowledge to script their own runs, and not just for Spelunky 2, but for any game! In order to achieve this, I had an idea: a custom scripting language. But my goal was bigger than just me being able to script a Spelunky 2 run. The fastest way to get to something workable would have been to create a library with a bunch of utility functions that I could call from a Go program. This post was originally published on techtroupe.io.
0 Comments
Leave a Reply. |