Azarian

Kids Shapes Learning Puzzle

by Azarian

Kids Shapes Learning Puzzle Unity

Screenshots

Kids Shapes Learning Puzzle Unity
Kids Shapes Learning Puzzle Unity
Kids Shapes Learning Puzzle Unity

Specification

How to Use

Sample Code

using UnityEngine; using System.Collections; public class Drag: MonoBehaviour { // 2D private Vector2 screenPoint; private Vector2 offset; private bool isRightPlace; public GameManager gm; void OnMouseDrag() { isRightPlace = false; Vector2 curScreenPoint = new Vector2(Input.mousePosition.x, Input.mousePosition.y); Vector2 curPositi transform.positi } void OnMouseUp() { isRightPlace = true; } void OnTriggerStay2D(Collider2D coll) { if (coll.gameObject.name == gameObject.name && isRightPlace) { GetComponent&lt;AudioSource&gt;().Play(); gameObject.transform.positi GetComponent<Collider2D>().enabled = false; gm.CurPuzzleCount++; } } }

Video

Comments (0)

  • {{com.username}}
    {{com.username}}
    Buyer
    Seller

    {{com.username}}

    {{com.ctime}}

    {{com.content}}

    • {{com2.username}}
      {{com2.username}}
      Buyer
      Seller

      {{com2.username}}

      {{com2.ctime}}

      {{com2.content}}