After the statement is executed to the second await Task.Delay, it does not continue to await Task.Yiedl() but to Debug.Log("123").
public async void DoSomeThing()
{
await SomeThing();
}
public async Task SomeThing()
{ await Task.Delay(1000) ;
Debug.Log("123");
foreach (int unitID in UnitsID)
{
dataBaseSO.UnitSpawn(unitID);
}
await Task.Delay(1000);
await Task.Yield();
Debug.Log("456");
}