public void SetType(int id, Unit unit) { ID = id; srcPrefabID = unit.prefabID; if (unit.IsTower()) { srcType = _SrcType.Tower; } if (unit.IsCreep()) { srcType = _SrcType.Creep; } }
public void SetType(int id, Ability ability) { ID = id; srcPrefabID = ability.prefabID; srcType = _SrcType.Ability; }