コード例 #1
0
 public void Start()
 {
     m_logic  = MinigameManager.GetActive <mg_IceFishing>().Logic;
     m_label  = GetComponentInChildren <Text>();
     m_sprite = GetComponentInChildren <Image>();
     SetActive(p_active: false);
 }
コード例 #2
0
 public void ShowGame()
 {
     Resources.LoadGameResources();
     PopAllScreens();
     UIManager.Instance.OpenScreen("mg_if_GameScreen", toShowDarkMask: false, null, null);
     Logic = base.transform.GetComponentInChildren <mg_if_GameLogic>();
 }
コード例 #3
0
        public void Awake()
        {
            m_gameObject = GetComponent <mg_if_GameObject>();
            m_logic      = MinigameManager.GetActive <mg_IceFishing>().Logic;
            Camera mainCamera = MinigameManager.GetActive().MainCamera;

            m_screenWidth = mainCamera.aspect * mainCamera.orthographicSize;
        }
コード例 #4
0
ファイル: mg_if_Crab.cs プロジェクト: smdx24/CPI-Source-Code
        public void Initialize(mg_if_EObjectsMovement p_movement)
        {
            m_movement = p_movement;
            mg_if_GameLogic logic  = MinigameManager.GetActive <mg_IceFishing>().Logic;
            Vector2         vector = base.transform.position;

            vector.y = logic.TopZone.position.y;
            base.transform.position = vector;
            GameObject gameObject = null;

            gameObject    = ((p_movement != mg_if_EObjectsMovement.MOVEMENT_LEFT) ? logic.CrabStopLeft : logic.CrabStopRight);
            m_checkPoint1 = gameObject.transform.Find("mg_if_stop_1");
            m_checkPoint2 = gameObject.transform.Find("mg_if_stop_2");
        }
コード例 #5
0
 public void Start()
 {
     m_logic         = MinigameManager.GetActive <mg_IceFishing>().Logic;
     m_hook          = GetComponentInChildren <mg_if_FishingHook>();
     m_line          = GetComponentInChildren <mg_if_FishingLine>();
     m_penguin       = GetComponentInChildren <mg_if_Penguin>();
     m_wormCan       = GetComponentInChildren <mg_if_WormCan>();
     m_mainCamera    = MinigameManager.GetActive <mg_IceFishing>().MainCamera;
     m_destination   = new Vector2(0f, -4f);
     m_touchDistance = m_hook.GetComponentInChildren <BoxCollider2D>().size.y * 1.5f;
     m_hook.Initialize(this, GetComponentInChildren <mg_if_WormDrop>());
     m_line.Initialize(this);
     m_penguin.Initialize(this);
     m_wormCan.UpdateWorms(m_logic.Lives);
 }
コード例 #6
0
 public mg_if_InputManager(Camera p_camera, mg_if_GameLogic p_logic, MouseInputObserver mouseInputObserver)
 {
     m_logic  = p_logic;
     m_camera = p_camera;
     InputManager.AddCamera(m_camera);
     m_fingerIndex            = -1;
     InputManager.LongTapTime = 0.05f;
     m_onTouchStart           = OnTouchStart;
     m_onTouchUp   = OnTouchUp;
     m_onTouchDown = OnTouchDown;
     InputManager.Subscribe(TouchEvent.ON_TOUCH_START, m_onTouchStart);
     InputManager.Subscribe(TouchEvent.ON_TOUCH_UP, m_onTouchUp);
     InputManager.Subscribe(TouchEvent.ON_TOUCH_DOWN, m_onTouchDown);
     this.mouseInputObserver             = mouseInputObserver;
     mouseInputObserver.MouseMovedEvent += OnMouseMoved;
 }
コード例 #7
0
        public void Awake()
        {
            mg_IceFishing active = MinigameManager.GetActive <mg_IceFishing>();

            m_gameLogic = active.GetComponentInChildren <mg_if_GameLogic>();
        }
コード例 #8
0
 public void Start()
 {
     m_label = GetComponent <Text>();
     m_logic = MinigameManager.GetActive <mg_IceFishing>().Logic;
 }
コード例 #9
0
 public void Start()
 {
     m_logic  = MinigameManager.GetActive <mg_IceFishing>().Logic;
     m_bottom = base.transform.parent.Find("mg_if_BottomCheck").localPosition;
 }
コード例 #10
0
 public void ShowTitle()
 {
     PopAllScreens();
     UIManager.Instance.OpenScreen("mg_if_TitleScreen", toShowDarkMask: false, null, null);
     Logic = null;
 }