Three ways around it:
1. store the eGameObject in question in a smart pointer, not a plain pointer. Then it won't get deleted in between. That's what I'll commit.
2. Iterate twice, first calling OnRoundBegin, then EnsureBorn
3. Get rid of OnRoundBegin. It was only added for the fortress teamfinding step which can just as well happen in OnBirth.
Three ways around it:
1. store the eGameObject in question in a smart pointer, not a plain pointer. Then it won't get deleted in between. That's what I'll commit.
2. Iterate twice, first calling OnRoundBegin, then EnsureBorn
3. Get rid of OnRoundBegin. It was only added for the fortress teamfinding step which can just as well happen in OnBirth.