void Awake() { cman = GameObject.FindGameObjectWithTag(Tags.mainCamera).GetComponent<CutSceneManager>(); bgm = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<BGMManager>(); sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); switches = GetComponentsInChildren<MechSwitch>(); blocks = GetComponentsInChildren<MechBlock>(); spawner = GetComponentInChildren<MonsterSpawning>(); unlocked = 0; puzzleActivated = false; blockPositions = new List<List<Vector2>> { new List<Vector2> { new Vector2(-3f, 17f), new Vector2(3f, 17f), new Vector2(3f, 11f) }, new List<Vector2> { new Vector2(4f, 39f), new Vector2(-4f, 39f), new Vector2(4f, 31f) }, new List<Vector2> { new Vector2(-4f, 53f), new Vector2(4f, 53f), new Vector2(4f, 63f) } }; }
void Awake() { sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); bgm = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<BGMManager>(); startTime = Time.time; j = 0; }
void Awake() { sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); startTime = Time.time; MaxHealthPoint = 2000.0f; HealthPoint = 2000.0f; }
void Awake() { sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); startTime = Time.time; lastTime = 0.0f; target = GameObject.FindWithTag("Player"); j = 0; }
void Awake() { obstaclePrefab = Resources.Load("comp_block"); sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); cman = GameObject.FindGameObjectWithTag(Tags.mainCamera).GetComponent<CutSceneManager>(); bgm = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<BGMManager>(); currentSetNumber = 0; sets = new List<List<Vector2>>(); List<Vector2> set1 = new List<Vector2>(); set1.Add(new Vector2(2, 0)); set1.Add(new Vector2(7, 0)); set1.Add(new Vector2(6, 1)); set1.Add(new Vector2(1, 3)); set1.Add(new Vector2(5, 3)); set1.Add(new Vector2(2, 5)); set1.Add(new Vector2(0, 6)); set1.Add(new Vector2(6, 6)); set1.Add(new Vector2(3, 7)); sets.Add(set1); List<Vector2> set2 = new List<Vector2>(); set2.Add(new Vector2(1, 0)); set2.Add(new Vector2(7, 1)); set2.Add(new Vector2(9, 2)); set2.Add(new Vector2(2, 3)); set2.Add(new Vector2(4, 4)); set2.Add(new Vector2(6, 4)); set2.Add(new Vector2(1, 5)); set2.Add(new Vector2(7, 6)); set2.Add(new Vector2(0, 7)); sets.Add(set2); List<Vector2> set3 = new List<Vector2>(); set3.Add(new Vector2(4, 0)); set3.Add(new Vector2(0, 1)); set3.Add(new Vector2(9, 4)); set3.Add(new Vector2(3, 5)); set3.Add(new Vector2(6, 6)); set3.Add(new Vector2(1, 7)); sets.Add(set3); List<Vector2> set4 = new List<Vector2>(); set4.Add(new Vector2(4, 0)); set4.Add(new Vector2(9, 0)); set4.Add(new Vector2(8, 2)); set4.Add(new Vector2(9, 3)); set4.Add(new Vector2(0, 4)); set4.Add(new Vector2(2, 5)); set4.Add(new Vector2(4, 6)); set4.Add(new Vector2(3, 7)); set4.Add(new Vector2(8, 7)); sets.Add(set4); StartCoroutine(InitializeObstacles()); }
private void OnTriggerEnter2D(Collider2D collision) { if (collision.tag == "Enemy") { SEManager.Play(SEManager.ClipName.Hit); Destroy(collision.gameObject); Destroy(gameObject); } }
private void Awake() { seManager = FindObjectOfType <SEManager>(); SetAlphaToOne(); CreateColors(); AddFullAlphaColor(); colorDisplay.SetActive(false); showColors.onClick.AddListener(() => colorDisplay.SetActive(!colorDisplay.activeSelf)); }
private void EndMonsterHouse() { for (int i = 0; i < WallList.Count; i++) { WallList[i].SetActive(false); } SEManager.SetSE(SE); gameObject.SetActive(false); }
void Start() { //SEのインスタンス生成 SEManagerPrefab = Instantiate(SEManagerPrefab) as SEManager; SEManagerPrefab.name = "SEs"; //初期化 Question.QuestionManager.Create(ref QuestionFuncs, SEManagerPrefab, QuestionText, AnswerPrefab, AnswerText, CorrectAnswerText, this, "Lesson" + CurrentlyUserInfo.selectedLevel.ToString()); status = Question.SolveStatus.Waiting; }
public void explosionX() { if (!isBomb) { SEManager.PlayBombSound(); explosion[0] = (GameObject)Instantiate(explosionPrefab, transform.position + new Vector3((distancePX - distanceNX) / 2, 0f, 0f), Quaternion.identity); explosion[0].transform.localScale = new Vector3(distancePX + distanceNX, 2f, 2f); } }
private void OnTriggerEnter2D(Collider2D collision) { if (collision.CompareTag("Player")) { SEManager.PlaySE(SEManager.getItem); TimeManager.Instance.AddTime(this.addTimeValue); this.contactPlayerEvent.Invoke(); Destroy(this.gameObject); } }
private void OnTriggerEnter2D(Collider2D collision) { if (collision.CompareTag("Player")) { SEManager.PlaySE(SEManager.stopMovement); Rigidbody2D p_rb = collision.transform.parent.GetComponent <Rigidbody2D>(); p_rb.velocity = Vector2.zero; p_rb.angularVelocity = 0f; } }
void Start() { //オブジェクトプール ObjectPoolManager.Instance.Create_New_Pool(kick_Crash_Block, block_Num); ObjectPoolManager.Instance.Create_New_Pool(shoot_Crash_Block, block_Num); ObjectPoolManager.Instance.Create_New_Pool(charge_Kick_Crash_Block, block_Num); //取得 _se = GetComponentInChildren <SEManager>(); camera_Shake = GameObject.FindWithTag("MainCamera").GetComponent <CameraShake>(); }
private void OnTriggerEnter2D(Collider2D collision) { if (StageManager.Instance.ClearFlagType == E_ClearFlagType.BreakTarget && collision.CompareTag("AttackToEnemy")) { SEManager.PlaySE(SEManager.getItem); this.breakTarget.Invoke(); ClearFlag_BreakTarget.Instance.BreakTarget(); Destroy(this.gameObject); } }
private void OnTriggerEnter2D(Collider2D collision) { if (StageManager.Instance.ClearFlagType == E_ClearFlagType.CollectItem && collision.CompareTag("Player")) { SEManager.PlaySE(SEManager.getItem); this.getMustCollectItem.Invoke(); ClearFlag_CollectItem.Instance.GetMustCollectItem(); Destroy(this.gameObject); } }
// Awake Start Update private void Awake() { this.scriptOptionDirector = this.objectOptionDirector.GetComponent <OptionDirector>(); this.objectBGMManager = GameObject.FindWithTag("BGMManager"); this.scriptBGMManager = this.objectBGMManager.GetComponent <BGMManager>(); this.objectSEManager = GameObject.FindWithTag("SEManager"); this.scriptSEManager = this.objectSEManager.GetComponent <SEManager>(); }
private void Awake() { if (Instance == null) { Instance = this; } else { Debug.LogError("More Than two instance"); } }
private void Update() { if (Input.GetKeyDown(KeyCode.Return)) { SEManager.PlaySE(SEManager.E_SE.Slash); } if (Input.GetKeyDown(KeyCode.W)) { SEManager.PlaySE(SEManager.E_SE.Jump); } }
// Use this for initialization void Start() { saveNextFallPos = nextFallPos; Canvas = GameObject.Find("Canvas"); GameObject manager = GameObject.FindWithTag("GameController"); p_seManager = GameObject.Find("SE").GetComponent <SEManager> (); gameManager = manager.GetComponent <GameManager> (); scoreManager = manager.GetComponent <ScoreManager> (); Initialize(); }
private void Awake() { if (Instance == null) { Instance = this; Instance = this; audioSource = GetComponent <AudioSource>(); } }
public void PressBackManual() { this.manual[this.currentIndex].SetActive(false); this.currentIndex--; if (this.currentIndex < 0) { this.currentIndex = this.manualLength - 1; } this.manual[this.currentIndex].SetActive(true); SEManager.PlaySE(SEManager.page); }
private void Awake() //스타트보다 먼저 실행되는 함수 { if (instance != null) { Destroy(this.gameObject); } else { DontDestroyOnLoad(this.gameObject); instance = this; } }
public bool PutBombermanPrefab() { if (putBomberManNum < putAbleBomberManNum) { SEManager.PlayPutBombSound(); GameObject bomberman = Instantiate(bombermanPrefab, transform.position, Quaternion.identity); bomberman.GetComponent <BomberMan>().SetPutter(this.GetComponent <PutObject>()); putBomberManNum++; return(true); } return(false); }
public bool PutLandMinePrefab() { if (putLandMineNum < putAbleLandMineNum) { SEManager.PlayPutBombSound(); GameObject landMine = (GameObject)Instantiate(landMinePrefab, transform.position, Quaternion.identity); landMine.GetComponent <LandMine>().SetPutter(this.GetComponent <PutObject>()); putLandMineNum++; return(true); } return(false); }
public bool PutProtectDomePrefab() { if (putProtectDomeNum < putAbleProtectDomeNum) { GameObject protectDome = Instantiate(protectDomePrefab, transform.position, Quaternion.identity); protectDome.GetComponent <DestroyTimeAgo>().SetPutter(this.GetComponent <PutObject>()); SEManager.PlayPutObjectSound1(); putProtectDomeNum++; return(true); } return(false); }
// Use this for initialization void Start() { audio = GetComponent <AudioSource>(); seManager = GetComponent <SEManager>(); changeScale = new ChangeScale(new Vector3(1, 1, 1), changeTime); //mirrorRect = new Rect(1, 1, 1, 1); normalScale = transform.localScale; scale = new Vector3(1, 1, 1);//transform.localScale; scaleStorage = scale; normalMass = GetComponent <Rigidbody>().mass; sizeStorage = SizeEnum.Normal; }
void Awake() { sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); bgm = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<BGMManager>(); startTime = Time.time; bossState = 0; status = transform.parent.gameObject.GetComponent<Boss>(); boss = transform.parent; StageRefPoint = GameObject.FindGameObjectWithTag("StageRefPoint").transform.position; status.isInvicible = true; }
public bool PutLaserPrefab() { if (putLaserNum < putAbleLaserNum) { SEManager.PlayPutObjectSound0(); GameObject laser = Instantiate(laserPrefab, shotBullet.transform.position, transform.rotation); laser.GetComponent <Laser>().SetPutter(this.GetComponent <PutObject>()); putLaserNum++; return(true); } return(false); }
private void Awake() { this.objectGameDirector = GameObject.FindWithTag("Director"); this.scriptOutputTips = this.objectGameDirector.GetComponent <OutputTips>(); this.objectSEManager = GameObject.FindWithTag("SEManager"); this.scriptSEManager = this.objectSEManager.GetComponent <SEManager>(); this.objectParentOfGroups = GameObject.FindWithTag("ParentOfGroups"); this.scriptBulletManager = this.GetComponent <BulletManager>(); }
public void PressBackMissionRankingButton() { SEManager.PlaySE(SEManager.select); this.scrollViews[this.showingMissionIndex].SetActive(false); this.showingMissionIndex--; if (this.showingMissionIndex < 0) { this.showingMissionIndex = this.missionCount - 1; } this.scrollViews[this.showingMissionIndex].SetActive(true); this.RankingTitleText.text = "ランキング(Mission" + (this.showingMissionIndex + 1).ToString() + ")"; }
public void OnSelect() { SEManager.PlaySelectButtonSound(); lifeNumText.text = lifeNum; moveSpeedText.text = moveSpeed; shotSpeedText.text = shotSpeed; bulletNumText.text = bulletNum; descriptionText.text = description; announceText.text = announce; releaseConditionText.text = releaseCondition; selectTankObject.SetActive(true); }
public bool PutBatteryPrefab() { if (putBatteryNum < putAbleBatteryNum) { GameObject battery = Instantiate(batteryPrefab, new Vector3(shotBullet.transform.position.x, 0f, shotBullet.transform.position.z), transform.rotation); battery.GetComponent <DestroyTimeAgo>().SetPutter(this.GetComponent <PutObject>()); battery.GetComponent <DestroyByAttack>().SetPutter(this.GetComponent <PutObject>()); SEManager.PlayPutObjectSound0(); putBatteryNum++; return(true); } return(false); }
private void Awake() { this.objectGameDirector = GameObject.FindWithTag("Director"); this.scriptDestroyAll = this.objectGameDirector.GetComponent <DestroyAll>(); this.scriptOutputTips = this.objectGameDirector.GetComponent <OutputTips>(); this.objectMainCamera = GameObject.FindWithTag("MainCamera"); this.objectSEManager = GameObject.FindWithTag("SEManager"); this.scriptSEManager = this.objectSEManager.GetComponent <SEManager>(); this.scriptTargetManager = this.GetComponent <TargetManager>(); }
private void Awake() { this.scriptGameDirector = this.GetComponent <GameDirector>(); this.scriptScore = this.GetComponent <Score>(); this.objectOptionManager = GameObject.FindWithTag("OptionManager"); this.scriptGameOption = this.objectOptionManager.GetComponent <GameOption>(); this.objectSEManager = GameObject.FindWithTag("SEManager"); this.scriptSEManager = this.objectSEManager.GetComponent <SEManager>(); this.scriptGameButton = this.objectCanvasButton.GetComponent <GameButton>(); }
private void Awake() { if (_instance != null) { Destroy(this.gameObject); } else if (_instance == null) { _instance = this; } DontDestroyOnLoad(this.gameObject); }
public void SetPlayerName() { if (this.inputField.text == "") { SEManager.PlaySE(SEManager.speedDown); } else { SEManager.PlaySE(SEManager.decision); StaticData.playerName = this.inputField.text; SceneManager.LoadScene("SelectMissionStage"); } }
void Awake() { if (instance == null) { instance = this; DontDestroyOnLoad(gameObject); } else { Destroy(gameObject); } gameover = GetComponent<GameOverMenu>(); fader = GetComponent<Fader>(); gman = GetComponent<GUIManager>(); pauseScreen = GetComponent<PauseScreen>(); bgmm = GetComponent<BGMManager>(); semm = GetComponent<SEManager>(); GameObject storyController = GameObject.FindGameObjectWithTag(Tags.storyController); if (storyController != null) { storysemm = storyController.GetComponent<SEManager>(); } paused = false; }
public Scenariodate(string text_date,float time ,Route next_route = Route.Main, CharacterAnimator.Animation jony_animation = CharacterAnimator.Animation.UpScaling, CharacterAnimator.Animation abery_animation = CharacterAnimator.Animation.UpScaling, CharacterAnimator.State jony_state = CharacterAnimator.State.Normal, CharacterAnimator.State abery_state = CharacterAnimator.State.Normal, int camera_number = -1, CameraAnimator.Animation camera_animation = CameraAnimator.Animation.Null, ExtraAnimator.Animation extra_animation = ExtraAnimator.Animation.NULL, SEManager.SE se_petern = SEManager.SE.NoSound) { this._text_date = text_date; this._next_route = next_route; this._time = time; this._jony_animation = jony_animation; this._jony_state = jony_state; this._abery_animation = abery_animation; this._abery_state = abery_state; this._camera_number = camera_number; this._camera_animation = camera_animation; this._extra_animation = extra_animation; this._se_pertern = se_petern; }
// Use this for initialization void Start () { Jony = (GameObject.FindGameObjectWithTag ("Jony")).GetComponent<CharacterAnimator>(); Abery = GameObject.FindGameObjectWithTag ("Abery").GetComponent<CharacterAnimator>(); _extra_animator = GameObject.FindObjectOfType<ExtraAnimator> (); _scenario_text = GameObject.FindObjectOfType<ScenarioText> (); _view_camera = GameObject.FindObjectOfType<ChangeCamera> (); _camera_animator = GameObject.FindObjectOfType<CameraAnimator> (); _cv_reference = GameObject.FindObjectOfType<CVManager> (); _se_reference= GameObject.FindObjectOfType<SEManager> (); _start_count = GameObject.FindObjectOfType<StartCount> (); Style = new GUIStyle(); State = new GUIStyleState(); //CSVデータから、ルートごとに分けてテキストデータ等を読み込む var MasterTable = new CSVMasterTable(); MasterTable.Load(); foreach (var Master in MasterTable.All) { //一度データを取り出す。 Scenariodate data = new Scenariodate ( Master.Scenario, Master.WatchTime, (Route)Master.NextRoute, Master.JonyAnimation, Master.AberyAnimation, Master.JonyState, Master.AberyState, Master.CameraNumber,Master.CameraAnimation, Master.ExtraAnimation,Master.SEPetern); //ルートにあわせて保存 switch ((Route)Master.CurrentRoute) { case Route.Main: _Main.Add (data); break; case Route.A: _A.Add(data); break; case Route.B: _B.Add(data); break; case Route.C: _C.Add(data); break; } } // _A.Add(new Scenariodate("ENDTEXT",0,Route.Main)); //_B.Add(new Scenariodate("ENDTEXT",0,Route.Main)); //_C.Add(new Scenariodate("ENDTEXT",0,Route.Main)); _cv_reference.Init(); _next_route = Route.NULL; _do_skip_text = false; //UpdateScenerio (Route.Main); }
protected virtual void Init() { unitMove = GetComponent<UnitMove>(); meshRenderer = gameObject.GetComponentInChildren<MeshRenderer>(); mat_ended = Resources.Load<Material>("Materials/Unit_Turn_Over"); stats = gameObject.GetComponent<UnitStats>(); m_statusEffects = gameObject.GetComponent<SEManager>(); LoadResources(); SetStats(); SetPowers(); }
void Awake() { sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); }
void Awake() { gman = GetComponent<GUIManager>(); sem = GetComponentInChildren<SEManager>(); screenHeight = GUIManager.height; screenWidth = GUIManager.width; waitInterval = 1.0f / characterPerSecond; }
protected override void Awake() { agent = GetComponent<NavMeshAgent>(); sem = GameObject.FindGameObjectWithTag(Tags.gameController).GetComponent<SEManager>(); }
void Awake() { hash = GameObject.FindGameObjectWithTag(Tags.storyController).GetComponent<HashIDs>(); sem = GameObject.FindGameObjectWithTag(Tags.storyController).GetComponentInChildren<SEManager>(); }
void Awake() { gman = GameObject.FindGameObjectWithTag(Tags.storyController).GetComponent<GUIManager>(); sem = GameObject.FindGameObjectWithTag(Tags.storyController).GetComponentInChildren<SEManager>(); fader = GetComponent<Fader>(); }