ByteSkript.jar
into an empty folder.java -jar path/to/ByteSkript.jar
.
Windows users can do this through command prompt or by creating a clickable bat file.
Mackintosh/Linux users can do this through terminal or by creating a clickable shell file.skript/
folder is the most important.skript
.bsk
file in this directory will be run.libraries
resources
compiled
bsk
command..bsk
in the skript/
folder will be seen and loaded by ByteSkript.myscript.bsk
in the skript/
folder. You can open this file in your editor app.on load
event will be run when your script is loaded, but never again.trigger:
section needs to be indented inside the on load:
event. This is to tell ByteSkript that the trigger belongs to this event.print "hello"
effect will print a line to the system output (command-line.) You can read more about this and other effects in the documentation.CTRL + C
will end the program.hello
to the console.{var_name}
pattern. The name can contain alphaneumeric characters and _
but must start with an a-z
letter character."hello"
we can try introducing a variable.trigger
, we can organise it by breaking it up into separate functions.myscript.bsk
file.function ...
declaration goes on the root level of the file and is not indented.{name}
and {number}
inside this function.+
operator can be used to join text together."hello " + "there"
will join these to make "hello there"
.name
and number
arguments when it's run. We can put these inside the ()
brackets in the run effect.java -jar path/to/ByteSkript.jar run
or by clicking your shell/bat file, if you created one..bsk
extension inside the skript/
folder.on load
event will be triggered for each one.compiled/
folder. It will be called CompiledScripts.jar
by default, but you can change the name.java -jar path/to/CompiledScripts.jar
.