示例#1
0
    void OnGUI()
    {
        if (Time.time % 2 < 1)
        {
            success = callBack.getResult();
        }
        // For Setting Up ResponseBox.
        GUI.TextArea(new Rect(10, 5, 1300, 175), success);

        //=========================================================================
        if (GUI.Button(new Rect(50, 200, 200, 30), "Run Java Code"))
        {
            App42Log.SetDebug(true);
            customCodeService = sp.BuildCustomCodeService();             // Initializing CustomCodeService.
            JSONClass jsonBody = new JSONClass();
            jsonBody.Add("name", "John");
            jsonBody.Add("age", 30);
            customCodeService.RunJavaCode(cons.customServiceName, jsonBody, new CustomCodeResponse());
        }
    }