Here is a little fun project I did last month. This provides an alternative syntax for writing Halo scripting languages that is more similar to Lua than Lisp. Note that this doesn't add anything to the Halo scripting language, as I can't really make it do things you couldn't do before. I am planning on adding loops, though Halo's limited script stack size will mean you have to use these loops sparingly.
Here's an example Hello World script:
global string hello_world = "hello world"
startup start
developer_mode = 127
if (4 + 1) > 4
print(hello_world)
print("5 is greater than 4!")
elseif 5 / 0
print("wait, what?")
end
end
When parsed and converted into Halo script, it results in this script:
(global string hello_world "hello world")(script startup start (set developer_mode 127)(if (> (+ 4 1)4)(begin (print hello_world)(print "5 is greater than 4!"))(if (/ 5 0)(print "wait, what?"))))
The resulting script can then be compiled by Sapien into Halo Custom Edition. Unnecessary spaces and quotation marks are stripped and removed.
Again, this does not allow you to do anything you couldn't do in HSC before, but it may make scripting easier for people who are not used to Lisp. In the end, it's just a fun little project.
If you actually do want to use this, you will need Python. This might be a dealbreaker for some of you as Python can be really hard to install for some people, but if people are interested, I may make a more portable version later.
Source and further documentation:
https://github.com/Kavawuvi/serpentEdited by Kavawuvi on Mar 15, 2019 at 02:02 PM