I have been trying to figure out why my channels keep getting closed on me, and I see now it's because of this logic
// Close the channel if it wasn't persistent
if ((!persistent || playerLimit < 1) && players.size == 0)
{
closed = true;
for (int i = 0; i < rfcs.size; ++i)
{
RFC r = rfcs;
if (r.data != null) r.data.Recycle();
}
rfcs.Clear();
I did mark the channel persistent, but I didn't specify a playerlimit (0). So because of that, when the last player leaves it closes.
My plan involves giving different players 'assigned channels' so they can leave and come back to the same one. This close behavior kind of messes with that. I can get around it probably just by artificially upping the player limit, but I was wondering what the reason was for that behavior?
Thanks.