blob: 4ecc20f22346ffffda2dfc24b36a707fed48d4db (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
using System;
using MonoGame.Extended.Entities;
namespace Celesteia.Resources.Types {
public class EntityType : IResourceType {
private byte id;
public byte GetID() => id;
public void SetID(byte value) => id = value;
private Action<Entity> InstantiateAction;
public EntityType(Action<Entity> instantiate) {
InstantiateAction = instantiate;
}
public void Instantiate(Entity entity) {
InstantiateAction.Invoke(entity);
}
}
}
|