1234567891011121314151617181920212223242526272829303132 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- public class Cancel : MonoBehaviour
- {
- public GameObject lineParent;
- public GameObject imagepaint;
- public void ClickCancelBtn()
- {
- PaintLine.canUse = false;
- if (imagepaint.transform.childCount>0)
- {
- for (int i = 0; i < imagepaint.transform.childCount; i++)
- {
- Destroy(imagepaint.transform.GetChild(i).gameObject);
- }
- }
- if (lineParent.transform.childCount > 0)
- {
- for (int i = 0; i < lineParent.transform.childCount; i++)
- {
- Destroy(lineParent.transform.GetChild(i).gameObject);
- }
- }
- if (RoomMainForms.Instance)
- {
- RoomMainForms.Instance.JieTuWancheng();
- }
- }
- }
|