迁移 EntityData 到 Base 中
- 新增 EntityDataFactory 工厂类,提供创建 EntityData 的统一入口 - 移出 EntityData 及派生类对 GameEntry 的依赖并移入 SepCore.Base 程序集中
This commit is contained in:
@@ -7,6 +7,7 @@ using Entity.EntityData;
|
||||
using GameFramework.Event;
|
||||
using UnityGameFramework.Runtime;
|
||||
using Entity.Weapon;
|
||||
using SepCore.Utility;
|
||||
|
||||
namespace Entity
|
||||
{
|
||||
@@ -140,7 +141,8 @@ namespace Entity
|
||||
// BackpackComponent
|
||||
Coin = role.Coin;
|
||||
_backpackComponent.OnInit(this, role.WeaponCapacity);
|
||||
GameEntry.Entity.ShowWeapon(new WeaponKnifeData(GameEntry.Entity.GenerateSerialId(), Id, _playerData.Camp));
|
||||
GameEntry.Entity.ShowWeapon(EntityDataFactory.Create(GameEntry.Entity.GenerateSerialId(),
|
||||
WeaponType.WeaponKnife, Id, _playerData.Camp));
|
||||
|
||||
// StatComponent
|
||||
foreach (var modifier in role.InitialProperties)
|
||||
|
||||
Reference in New Issue
Block a user