本文整理了Java中com.artemis.Entity.<init>()
方法的一些代码示例,展示了Entity.<init>()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Entity.<init>()
方法的具体详情如下:
包路径:com.artemis.Entity
类名称:Entity
方法名:<init>
[英]Create an entity for the specified world.
[中]为指定的世界创建实体。
代码示例来源:origin: junkdog/artemis-odb
public static Entity create(World world, int entityId) {
return new Entity(world, entityId);
}
}
代码示例来源:origin: apotapov/gdx-artemis
@Override
protected Entity newObject() {
return new Entity(world);
}
代码示例来源:origin: net.onedaybeard.artemis/artemis-odb-serializer
public static Entity create(World world, int entityId) {
return new Entity(world, entityId);
}
}
代码示例来源:origin: junkdog/artemis-odb
/**
* Instantiates an Entity without registering it into the world.
* @param id The ID to be set on the Entity
*/
private Entity createEntity(int id) {
Entity e = new Entity(world, id);
if (e.id >= entities.getCapacity()) {
growEntityStores();
}
// can't use unsafe set, as we need to track highest id
// for faster iteration when syncing up new subscriptions
// in ComponentManager#synchronize
entities.set(e.id, e);
return e;
}
代码示例来源:origin: net.onedaybeard.artemis/artemis-odb
/**
* Instantiates an Entity without registering it into the world.
* @param id The ID to be set on the Entity
*/
private Entity createEntity(int id) {
Entity e = new Entity(world, id);
if (e.id >= entities.getCapacity()) {
growEntityStores();
}
// can't use unsafe set, as we need to track highest id
// for faster iteration when syncing up new subscriptions
// in ComponentManager#synchronize
entities.set(e.id, e);
return e;
}
内容来源于网络,如有侵权,请联系作者删除!