I just got ORK and do not understand how to run a script.
Start() and Update() methods are causing errors. Am I correct in assuming you cannot use those?
How would I run the following test script?
using UnityEngine;
using System.Collections;
public class TestScript : MonoBehaviour
{
public void testMethod ()
{
Debug.Log("test");
}
}
You have to include the ORK namespace up at the top of your script for starters.
using ORKFramework;
You can call a function in a script in an ORK event. I think the process there is to put the script on an empty game object in your scene and then fill in the event that calls a function.
It turns out that using ORKFramework isn't required just to call a function, but almost certainly is to interact with the framework.
I've put my script on an empty object in my scene but I can't get to make it run...
The name of the function you want to call goes into the Function Name field. The function must be public, and you need to add the parameters (Add Parameter button) your function requires. Please note that not all parameter types are supported, only some basic stuff.
To get the correct game object you want this to call on, add it as an actor in the event's settings - either use the Find Object functionality, or select the object in the inspector of your event interaction.
If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
══ (\../) ══
═ ( ◕.◕) ═══ Thank you!
══ (,)(,) ═══