Execute Code Icon Execute Code

This action simply adds a code editor block into the GML Visual list where you can add any valid GML code that you require for the object. Note that all the code in the action will be run before the next action in the list is run. To make it easier to track what these actions do you can name them by using the JSDoc @description identifier, as shown in the image below:

Execute Code example of use

 

动作语法:

Execute Code Action

例子:

Execute Code ExampleThe above action block code creates a couple of global scope variables to create an MP grid and a path.