protected virtual void SetDie() { //상태 isDead = true; //속도 if (rb != null) { rb.velocity = Vector3.zero; } //충돌체 ColliderOnOff(false); //애니메이션 if (animator != null) { animator.SetTrigger("DeadTrigger"); } //다시 풀로 돌아가기 Invoke("ObjectOff", 3f); //근접공격대상에서 벗어나게 RemoveInList(); //실행중인 모든 코루틴 종료 StopAllCoroutines(); //스코어 올려줌 GamePlayerManager.Instance.scoreCounter.KillMonster(); //무기꺼중 if (weaponPosit != null) { weaponPosit.gameObject.SetActive(false); } //이펙트 청소 foreach (KeyValuePair <CharacterCondition, CharacterStateEffect> effect in effectDic) { effectDic[effect.Key].EffectOff(); } effectDic.Clear(); //hud꺼줌 HudOnOff(false); //코인생성 DropGoods coin = ObjectManager.Instance.coinPool.GetItem(); coin.Initiatlize(this.transform.position, 10, GoodsType.Coin); //사운드 //SoundManager.Instance.PlaySoundEffect("monsterDown"); SoundManager.Instance.PlaySoundEffect("monsterHit"); isPushed = false; isStun = false; //소메치기패시브 if (NowSelectPassive.Instance.HasPassive(PassiveType.PickPocket) == true) { if (hasBullet == true) { //확률 if (MyUtils.GetPercentResult(5) == true) { GamePlayerManager.Instance.player.GetBulletItem(10); if (Language.Instance.NowLanguage == LanguageType.English) { MessageBar.Instance.ShowInfoBar("Get 10 Bullets", Color.white); } else { MessageBar.Instance.ShowInfoBar("총알 10개 훔침", Color.white); } } } } }