简单重构拆分 SimulationWorld
This commit is contained in:
+9
@@ -0,0 +1,9 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyAttackSim : ISimulationComponent
|
||||
{
|
||||
public const float DefaultAttackRange = 1f;
|
||||
|
||||
public float AttackRange;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 35d153869faa1494c9fbb7218bbdd5b0
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyBehaviorSim : ISimulationComponent
|
||||
{
|
||||
public const int StateIdle = 0;
|
||||
public const int StateChasing = 1;
|
||||
public const int StateInAttackRange = 2;
|
||||
|
||||
public int State;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 23b79d0c84ef6904588ff8da30bf4108
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyIdentitySim : ISimulationComponent
|
||||
{
|
||||
public int EntityId;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f89e25340a7475048a94caab1c77e745
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyMoveConfigSim : ISimulationComponent
|
||||
{
|
||||
public bool AvoidOverlap;
|
||||
public float BodyRadius;
|
||||
public int SeparationIterations;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: fa8be64dc4a8e0c4598f5b0be7fa7e03
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyMoveInputSim : ISimulationComponent
|
||||
{
|
||||
public float Speed;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b8883455a6bb9c94eba26c839184ca0b
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
using Unity.Mathematics;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemySeparationSim : ISimulationComponent
|
||||
{
|
||||
public float2 PreviousPush;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: eaeb6060e86ea424f956a2a478bc6126
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,65 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal sealed class EnemyStore : EntityComponentStore
|
||||
{
|
||||
private Column<EnemyIdentitySim> _identity;
|
||||
private Column<EnemyTransformSim> _transform;
|
||||
private Column<EnemyMoveInputSim> _moveInput;
|
||||
private Column<EnemyMoveConfigSim> _moveConfig;
|
||||
private Column<EnemyAttackSim> _attack;
|
||||
private Column<EnemyBehaviorSim> _behavior;
|
||||
private Column<EnemySeparationSim> _separation;
|
||||
|
||||
public Column<EnemyIdentitySim> Identity => _identity;
|
||||
public Column<EnemyTransformSim> Transform => _transform;
|
||||
public Column<EnemyMoveInputSim> MoveInput => _moveInput;
|
||||
public Column<EnemyMoveConfigSim> MoveConfig => _moveConfig;
|
||||
public Column<EnemyAttackSim> Attack => _attack;
|
||||
public Column<EnemyBehaviorSim> Behavior => _behavior;
|
||||
public Column<EnemySeparationSim> Separation => _separation;
|
||||
|
||||
public void Initialize(int capacity)
|
||||
{
|
||||
if (IsCreated)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Dispose();
|
||||
_identity = Register<EnemyIdentitySim>(capacity);
|
||||
_transform = Register<EnemyTransformSim>(capacity);
|
||||
_moveInput = Register<EnemyMoveInputSim>(capacity);
|
||||
_moveConfig = Register<EnemyMoveConfigSim>(capacity);
|
||||
_attack = Register<EnemyAttackSim>(capacity);
|
||||
_behavior = Register<EnemyBehaviorSim>(capacity);
|
||||
_separation = Register<EnemySeparationSim>(capacity);
|
||||
MarkInitialized();
|
||||
}
|
||||
|
||||
public int Add(in EnemyIdentitySim identity, in EnemyTransformSim transform, in EnemyMoveInputSim moveInput,
|
||||
in EnemyMoveConfigSim moveConfig, in EnemyAttackSim attack, in EnemyBehaviorSim behavior)
|
||||
{
|
||||
int index = AppendRow(identity.EntityId);
|
||||
_identity.Data.Add(identity);
|
||||
_transform.Data.Add(transform);
|
||||
_moveInput.Data.Add(moveInput);
|
||||
_moveConfig.Data.Add(moveConfig);
|
||||
_attack.Data.Add(attack);
|
||||
_behavior.Data.Add(behavior);
|
||||
_separation.Data.Add(default);
|
||||
return index;
|
||||
}
|
||||
|
||||
public override void Dispose()
|
||||
{
|
||||
base.Dispose();
|
||||
_identity = null;
|
||||
_transform = null;
|
||||
_moveInput = null;
|
||||
_moveConfig = null;
|
||||
_attack = null;
|
||||
_behavior = null;
|
||||
_separation = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 21d84c6a187090e46a1ec7637519c5a7
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
using Unity.Mathematics;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct EnemyTransformSim : ISimulationComponent
|
||||
{
|
||||
public float3 Position;
|
||||
public float3 Forward;
|
||||
public quaternion Rotation;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5d8966797f1b08648886988017716ea3
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+164
@@ -0,0 +1,164 @@
|
||||
using System.Collections.Generic;
|
||||
using Unity.Collections;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal abstract class EntityComponentStore
|
||||
{
|
||||
internal interface IColumn
|
||||
{
|
||||
bool IsCreated { get; }
|
||||
void EnsureCapacity(int count);
|
||||
void SwapBackRemove(int index, int lastIndex);
|
||||
void Clear();
|
||||
void Dispose();
|
||||
}
|
||||
|
||||
internal sealed class Column<T> : IColumn where T : unmanaged, ISimulationComponent
|
||||
{
|
||||
private NativeList<T> _data;
|
||||
|
||||
public Column(int capacity)
|
||||
{
|
||||
_data = new NativeList<T>(capacity, Allocator.Persistent);
|
||||
}
|
||||
|
||||
public NativeList<T> Data => _data;
|
||||
|
||||
public bool IsCreated => _data.IsCreated;
|
||||
|
||||
public ref T this[int index] => ref _data.ElementAt(index);
|
||||
|
||||
public void EnsureCapacity(int count)
|
||||
{
|
||||
if (_data.IsCreated && _data.Capacity < count)
|
||||
{
|
||||
_data.Capacity = count;
|
||||
}
|
||||
}
|
||||
|
||||
public void SwapBackRemove(int index, int lastIndex)
|
||||
{
|
||||
if (index != lastIndex)
|
||||
{
|
||||
_data[index] = _data[lastIndex];
|
||||
}
|
||||
|
||||
_data.RemoveAt(lastIndex);
|
||||
}
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
if (_data.IsCreated)
|
||||
{
|
||||
_data.Clear();
|
||||
}
|
||||
}
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
if (_data.IsCreated)
|
||||
{
|
||||
_data.Dispose();
|
||||
}
|
||||
|
||||
_data = default;
|
||||
}
|
||||
}
|
||||
|
||||
private readonly EntityBinding _binding = new();
|
||||
private readonly List<IColumn> _columns = new();
|
||||
private int _count;
|
||||
|
||||
public int Count => _count;
|
||||
|
||||
public bool IsCreated { get; private set; }
|
||||
|
||||
public void EnsureCapacity(int count)
|
||||
{
|
||||
for (int i = 0; i < _columns.Count; i++)
|
||||
{
|
||||
_columns[i].EnsureCapacity(count);
|
||||
}
|
||||
}
|
||||
|
||||
public bool TryGetSimulationIndex(int entityId, out int index)
|
||||
{
|
||||
return _binding.TryGetSimulationIndex(entityId, out index);
|
||||
}
|
||||
|
||||
public bool RemoveByEntityId(int entityId)
|
||||
{
|
||||
if (!_binding.TryGetSimulationIndex(entityId, out int index))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
int lastIndex = _count - 1;
|
||||
bool hasMovedRow = index != lastIndex;
|
||||
int movedEntityId = 0;
|
||||
if (hasMovedRow)
|
||||
{
|
||||
_binding.TryGetEntityId(lastIndex, out movedEntityId);
|
||||
}
|
||||
|
||||
for (int i = 0; i < _columns.Count; i++)
|
||||
{
|
||||
_columns[i].SwapBackRemove(index, lastIndex);
|
||||
}
|
||||
|
||||
_binding.UnbindByEntityId(entityId);
|
||||
if (hasMovedRow)
|
||||
{
|
||||
_binding.RemapIndex(movedEntityId, index);
|
||||
}
|
||||
|
||||
_count--;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void Clear()
|
||||
{
|
||||
for (int i = 0; i < _columns.Count; i++)
|
||||
{
|
||||
_columns[i].Clear();
|
||||
}
|
||||
|
||||
_binding.Clear();
|
||||
_count = 0;
|
||||
}
|
||||
|
||||
public virtual void Dispose()
|
||||
{
|
||||
for (int i = 0; i < _columns.Count; i++)
|
||||
{
|
||||
_columns[i].Dispose();
|
||||
}
|
||||
|
||||
_columns.Clear();
|
||||
_binding.Clear();
|
||||
_count = 0;
|
||||
IsCreated = false;
|
||||
}
|
||||
|
||||
protected Column<T> Register<T>(int capacity) where T : unmanaged, ISimulationComponent
|
||||
{
|
||||
Column<T> column = new Column<T>(capacity);
|
||||
_columns.Add(column);
|
||||
return column;
|
||||
}
|
||||
|
||||
protected void MarkInitialized()
|
||||
{
|
||||
IsCreated = true;
|
||||
}
|
||||
|
||||
protected int AppendRow(int entityId)
|
||||
{
|
||||
int index = _count;
|
||||
_binding.Bind(entityId, index);
|
||||
_count++;
|
||||
return index;
|
||||
}
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: ea8b87c1fbddf6743a7ce3339dc943a2
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+6
@@ -0,0 +1,6 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal interface ISimulationComponent
|
||||
{
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4f605b392ae908a439b2028cf5a4eb05
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct PickupIdentitySim : ISimulationComponent
|
||||
{
|
||||
public int EntityId;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: be2030806e57ecc4f9276b506c800542
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+7
@@ -0,0 +1,7 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct PickupRadiusSim : ISimulationComponent
|
||||
{
|
||||
public float Radius;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d5d8bf9445be1f14bba1ccf4093045f1
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct PickupStateSim : ISimulationComponent
|
||||
{
|
||||
public const int StateIdle = 0;
|
||||
public const int StateAbsorbing = 1;
|
||||
|
||||
public int State;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e505617febb37c54bbec57f8882d3a8a
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -0,0 +1,50 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal sealed class PickupStore : EntityComponentStore
|
||||
{
|
||||
private Column<PickupIdentitySim> _identity;
|
||||
private Column<PickupTransformSim> _transform;
|
||||
private Column<PickupRadiusSim> _radius;
|
||||
private Column<PickupStateSim> _state;
|
||||
|
||||
public Column<PickupIdentitySim> Identity => _identity;
|
||||
public Column<PickupTransformSim> Transform => _transform;
|
||||
public Column<PickupRadiusSim> Radius => _radius;
|
||||
public Column<PickupStateSim> State => _state;
|
||||
|
||||
public void Initialize(int capacity)
|
||||
{
|
||||
if (IsCreated)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Dispose();
|
||||
_identity = Register<PickupIdentitySim>(capacity);
|
||||
_transform = Register<PickupTransformSim>(capacity);
|
||||
_radius = Register<PickupRadiusSim>(capacity);
|
||||
_state = Register<PickupStateSim>(capacity);
|
||||
MarkInitialized();
|
||||
}
|
||||
|
||||
public int Add(in PickupIdentitySim identity, in PickupTransformSim transform, in PickupRadiusSim radius,
|
||||
in PickupStateSim state = default)
|
||||
{
|
||||
int index = AppendRow(identity.EntityId);
|
||||
_identity.Data.Add(identity);
|
||||
_transform.Data.Add(transform);
|
||||
_radius.Data.Add(radius);
|
||||
_state.Data.Add(state);
|
||||
return index;
|
||||
}
|
||||
|
||||
public override void Dispose()
|
||||
{
|
||||
base.Dispose();
|
||||
_identity = null;
|
||||
_transform = null;
|
||||
_radius = null;
|
||||
_state = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 88ed8cf0bf6d9cb459e071ff5b93dc54
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
using Unity.Mathematics;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct PickupTransformSim : ISimulationComponent
|
||||
{
|
||||
public float3 Position;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8046df9b31763ac448c52a088f9fd9d5
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct ProjectileIdentitySim : ISimulationComponent
|
||||
{
|
||||
public int EntityId;
|
||||
public int OwnerEntityId;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 52b2efbbc6a2ee94a81016767ef6a6bb
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct ProjectileLifeSim : ISimulationComponent
|
||||
{
|
||||
public float Age;
|
||||
public float LifeTime;
|
||||
public bool Active;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 4b7fb93b432358948ae81a913129bcf7
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+50
@@ -0,0 +1,50 @@
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal sealed class ProjectileStore : EntityComponentStore
|
||||
{
|
||||
private Column<ProjectileIdentitySim> _identity;
|
||||
private Column<ProjectileTransformSim> _transform;
|
||||
private Column<ProjectileVelocitySim> _velocity;
|
||||
private Column<ProjectileLifeSim> _life;
|
||||
|
||||
public Column<ProjectileIdentitySim> Identity => _identity;
|
||||
public Column<ProjectileTransformSim> Transform => _transform;
|
||||
public Column<ProjectileVelocitySim> Velocity => _velocity;
|
||||
public Column<ProjectileLifeSim> Life => _life;
|
||||
|
||||
public void Initialize(int capacity)
|
||||
{
|
||||
if (IsCreated)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Dispose();
|
||||
_identity = Register<ProjectileIdentitySim>(capacity);
|
||||
_transform = Register<ProjectileTransformSim>(capacity);
|
||||
_velocity = Register<ProjectileVelocitySim>(capacity);
|
||||
_life = Register<ProjectileLifeSim>(capacity);
|
||||
MarkInitialized();
|
||||
}
|
||||
|
||||
public int Add(in ProjectileIdentitySim identity, in ProjectileTransformSim transform,
|
||||
in ProjectileVelocitySim velocity, in ProjectileLifeSim life)
|
||||
{
|
||||
int index = AppendRow(identity.EntityId);
|
||||
_identity.Data.Add(identity);
|
||||
_transform.Data.Add(transform);
|
||||
_velocity.Data.Add(velocity);
|
||||
_life.Data.Add(life);
|
||||
return index;
|
||||
}
|
||||
|
||||
public override void Dispose()
|
||||
{
|
||||
base.Dispose();
|
||||
_identity = null;
|
||||
_transform = null;
|
||||
_velocity = null;
|
||||
_life = null;
|
||||
}
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 6de5ba3f6e96dc845b50ca960aa5ae32
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
using Unity.Mathematics;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct ProjectileTransformSim : ISimulationComponent
|
||||
{
|
||||
public float3 Position;
|
||||
public float3 Forward;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 59b7c7f9782759b498e3b1d9a507ca81
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
using Unity.Mathematics;
|
||||
|
||||
namespace SepCore.Simulation
|
||||
{
|
||||
internal struct ProjectileVelocitySim : ISimulationComponent
|
||||
{
|
||||
public float3 Velocity;
|
||||
}
|
||||
}
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 01a59e095dd7381469d25c36b4a7e878
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user