Esempio n. 1
0
 internal void QueueResponse(NetworkChunk Chunk)
 {
     Incomming[Chunk.ChunkCoords] = Chunk;
     if (Outgoing.Keys.Contains(Chunk.ChunkCoords)) {
         Outgoing.Remove(Chunk.ChunkCoords);
     }
 }
Esempio n. 2
0
        public void QueueRequest(Vector3i Position)
        {
            NetworkChunk Target;
            Vector3i ChunkCoords = Position / NetworkChunk.Size;

            //Only make a new request if one hasn't been made, and if one isn't being resolved.
            if (!Outgoing.TryGetValue(ChunkCoords, out Target) && !Incomming.TryGetValue(ChunkCoords, out Target)) {
                Target = new NetworkChunk(Realm, ChunkCoords);
                Outgoing[ChunkCoords] = Target;
            }
        }