コード例 #1
0
ファイル: FlippingTool.cs プロジェクト: gamkedo-la/geogami
    public void paintAllShapesToPaintSurfaceEditor()
    {
        // Retrieve all Shapes from Level
        GameObject[] allPlayerShapes = GameObject.FindGameObjectsWithTag("Player");

        Debug.Log("allPlayerShapes " + allPlayerShapes);
        Debug.Log("allPlayerShapes length " + allPlayerShapes.Length);

        foreach (GameObject child in allPlayerShapes)
        {
            Debug.Log("foreach");
            PaintTrail childPaintTrailScript = child.GetComponent <PaintTrail>();

            if (child.activeSelf && childPaintTrailScript)
            {
                Debug.Log("activeSelf");
                childPaintTrailScript.instantiatePaintSurfaceElement(paintSurfaceContainer);
            }
        }
    }
コード例 #2
0
 public void instantiatePaintSurface(GameObject container)
 {
     paintTrailScript.instantiatePaintSurfaceElement(container);
 }