Documentation

Unity Engine

Download Unity

Unity Engine

RemoveRange(int, int)

Removes "N" elements in a range, shifting everything above the range down by "N". Decrements the length by "N".
Read time 1 minuteLast updated a month ago

Definition

  • Type: Method
  • Namespace: Unity.Collections
  • Assembly: UnityEngine.ManagedKernelModule
public void RemoveRange(int index, int count)

Parameters

index

The index of the first element to remove.

count

The number of elements to remove.

Remarks

If you don't care about preserving the order of the elements,
RemoveRangeSwapBackWithBeginEnd
is a more efficient way to remove elements.