This commit is contained in:
PC-20230316NUNE\Administrator
2024-10-22 20:36:46 +08:00
parent 0e94e376fb
commit a3257421ad
26 changed files with 694 additions and 112 deletions

View File

@@ -27,11 +27,12 @@ namespace GASSamples.Scripts.Game.Entity.Nodes.Component.Components
GetSystem<JNGASSystem>().Unregister(ASC);
}
public void InitWithPreset(AbilitySystemComponentPreset ascPreset,int level)
public void InitWithPreset(IAbilitySystemComponentPreset ascPreset,int level)
{
// ASC.SetPreset(ascPreset);
// ASC.SetLevel(level);
// ASC.InitWithPreset(ASC.Level,ASC.Preset);
ASC.SetPreset(ascPreset);
ASC.SetLevel(level);
if (ASC.Preset == null) return;
// ASC.Init(asc.PresetBaseTags(), asc.PresetAttributeSetTypes(), asc.Preset.LinkAbilities, entityId, level);
}
/// <summary>

View File

@@ -17,7 +17,7 @@ namespace GASSamples.Scripts.Game.Entity.Nodes.Component.Controller
base.OnSyncStart();
//设置GAS 角色
GAS.InitWithPreset(GetSystem<DDataSystem>().Preset,1);
// GAS.InitWithPreset(GetSystem<DDataSystem>().Preset,1);
//附加效果测试
// GAS.ApplyGameplayEffectToSelf(new GameplayEffect(GetSystem<DDataSystem>().GE_JisolDemo1));

View File

@@ -79,11 +79,6 @@ namespace GAS.Runtime
{ typeof(AS_BaseAttribute), nameof(AS_BaseAttribute) },
};
public static void RecycleSetInstance(object obj)
{
ObjectPool.Instance.Recycle(obj);
}
public static List<string> AttributeFullNames = new List<string>()
{
"AS_BaseAttribute.HP",