Graal3D Scripting Manual

From Graal Bible
Revision as of 07:02, 12 October 2021 by JimmyAkl (talk | contribs) (changing worlds client download link)

Intro

Graal kart start.jpg

Welcome to the Graal3D Scripting Manual!

This Manual comes in handy for beginners wanting to learn Graal3D Scripting, and advanced developers looking to expand their knowledge, as it contains documentation, examples, tutorials and much more...

What we will focus on in this Manual is programming our gameplay (scripting the behavior of our GameObjects, their interactions, the components attached to them...)

How things work in Unity:

Unity is the leading platform for building 2D, 3D, VR and augmented reality games. It offers a scripting API in C#, allowing us to interact with the unity editor and the games we want to build.

In the Unity editor, we create and add GameObjects to our scene, we then attach C# scripts to each that will all run upon starting the scene. Unity sort of runs everything for you, it reads through all the lights, cameras, meshes, behaviors… and processes it for you.

How things work in Graal3D:

Since we will be using the Graal Unity Binding, things will be a bit different.

The Graal Unity Binding is a binding between GraalScript and Unity, it is actually still in alpha, but most functionalities needed are present. The goal of this binding is to mimic the Unity C# scripting system (functions and classes). So if you are familiar with Unity and C#, everything should be easy. If not, then do not worry, I will go over everything step by step and include examples done in C# and compare them to GraalScript for each topic.

The Worlds Client (which you will have to download) will serve as the Unity editor, mentioned earlier, which contains the base scene where you instantiate your GameObjects and manipulate them with your GraalScripts.

Required Downloads

Unity 2020.2.2f1: https://unity3d.com/get-unity/download/archive

The Worlds Client: https://github.com/TOONSLAB/GRAALONLINE/releases

RC: http://fp4.ca/windows_rc3_beta.zip

Tools

In-game Unity Tools (mimic the Unity Editor) & Game Functionality Tools (warping, fixing graphics, starting minigames...): Tools

Documentation

Unity

AssetBundles

Examples and Tutorials

Classes, Functions and Variables