!!try & catch method // Coroutine OnOff // Foreach & for
1. https://docs.microsoft.com/ko-kr/dotnet/csharp/language-reference/keywords/try-catch
try & catch method
try에서 검출 되지 않는 것을 catch에서 검출하는 것으로 오류의 부담이 있다.
2. Coroutine OnOff
private IEnumerator StartOnBoard()
{
while (true)
{
yield return new WaitForSeconds(0.1f);
if (_State == AttachedState.Attached)
{
Debug.Log("Coroutine_ShotAndOver");
yield break;
}
Debug.Log("CoroutineRunning");
}
}
3. Foreach 는 for에 비해서 가독성이 좋고 편리해서 이용 . array로 구성해 주나 어떤 array인지는 모름 Unity에서의 foreach는 가비지가 발생할 수 있음으로 사용 자제하는 것이 좋음
http://wnsgp.tistory.com/60
try & catch method
try에서 검출 되지 않는 것을 catch에서 검출하는 것으로 오류의 부담이 있다.
2. Coroutine OnOff
private IEnumerator StartOnBoard()
{
while (true)
{
yield return new WaitForSeconds(0.1f);
if (_State == AttachedState.Attached)
{
Debug.Log("Coroutine_ShotAndOver");
yield break;
}
Debug.Log("CoroutineRunning");
}
}
3. Foreach 는 for에 비해서 가독성이 좋고 편리해서 이용 . array로 구성해 주나 어떤 array인지는 모름 Unity에서의 foreach는 가비지가 발생할 수 있음으로 사용 자제하는 것이 좋음
http://wnsgp.tistory.com/60
댓글
댓글 쓰기