Exemple #1
0
    // Fired when the player presses a Meta button. The MetaButtonEventConnector class was slightly modified to fetch references to all IOnMetaButtonEvent interfaces across the scene, rather than those just under a specific GameObject.
    public void OnMetaButtonEvent(MetaButton button)
    {
        // If the camera button is short-pressed (and there is a metaReconstruction object)
        if (button.Type == ButtonType.ButtonCamera && button.State == ButtonState.ButtonShortPress)
        {
            if (metaReconstruction != null && metaReconstruction.ReconstructionRoot != null && metaReconstruction.ReconstructionRoot.transform.childCount > 0)
            {
                SetGizmoToCenterOfMesh(metaReconstruction.ReconstructionRoot.transform.GetChild(0));
            }

            Debug.LogWarning("ConnectFourBoardSetup : OnMetaButtonPressed - Camera button pressed, but there is no meshReconstruction object! Scan with Alt-I/Alt-S first!");
        }
    }
Exemple #2
0
 /// <summary>
 /// Process the Meta Button Event
 /// </summary>
 /// <param name="button">Button Message</param>
 public abstract void OnMetaButtonEvent(MetaButton button);