Quantcast
Channel: Questions in topic: "dllimport"
Viewing all articles
Browse latest Browse all 160

DLLImort using JS

$
0
0
Hey guys, So after a lomng while I've finally managed to include a CPP file in my Unity3D project. But as it seems, my boss wants a JS solution instead of a C# one. Could anoyone please help me translate the following C# script to its JS equelivent? public class CppReader : MonoBehaviour { public string number; [DllImport ("UnityDLL")] private static extern string GetOutput(); [DllImport ("UnityDLL")] private static extern string MakeComputerMove(bool isWhite, int difficulty, bool executeMove); [DllImport ("UnityDLL")] private static extern bool MakePlayerMove(bool isWhite, string moveString, bool executeMove); [DllImport ("UnityDLL")] private static extern string Initialize(); }

Viewing all articles
Browse latest Browse all 160

Trending Articles