Entity.CopyTo(World).md

March 19, 2022 ยท View on GitHub

DefaultEcs

DefaultEcs.Entity

Entity.CopyTo(World) Method

Creates a copy of current Entity with all of its components in the given World.
This method is not thread safe.

public DefaultEcs.Entity CopyTo(DefaultEcs.World world);

Parameters

world World

The World instance to which copy current Entity and its components.

Returns

Entity
The created Entity in the given World.

Exceptions

System.InvalidOperationException
Entity was not created from a World.