(client) feat:实现血条显示,实现攻击交互,添加碰撞体;fix:修复部分朝向贴图加载失败的问题;chore:规范工作类和行为获取类命名

This commit is contained in:
m0_75251201
2025-08-13 22:53:57 +08:00
parent 9922f06990
commit 35924f3695
37 changed files with 1006 additions and 183 deletions

View File

@ -11,7 +11,7 @@ namespace AI
public abstract JobBase GetJob(Entity.Entity target);
}
public class Selector : AIBase
public class ThinkNode_Selector : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
@ -24,13 +24,13 @@ namespace AI
return null;
}
}
public class ConditionalAI : Selector
public class ThinkNode_Conditional : ThinkNode_Selector
{
// 条件函数,返回 true 表示满足条件
private Func<Entity.Entity, bool> condition;
// 构造函数,传入条件函数
public ConditionalAI(Func<Entity.Entity, bool> conditionFunc)
public ThinkNode_Conditional(Func<Entity.Entity, bool> conditionFunc)
{
condition = conditionFunc;
}
@ -48,7 +48,7 @@ namespace AI
return null;
}
}
public class SequenceAI : AIBase
public class ThinkNode_Sequence : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
@ -61,33 +61,5 @@ namespace AI
return null; // 所有子节点完成时返回 null
}
}
public class ContinuousMove : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new MoveJob();
}
}
public class TrackPlayer : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new TrackPlayerJob();
}
}
public class RandomWander : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new WanderJob();
}
}
public class Idel : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new IdleJob();
}
}
}

View File

@ -0,0 +1,33 @@
namespace AI
{
public class JobGiver_ContinuousMove : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new MoveJob();
}
}
public class JobGiver_Enemies : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new TrackPlayerJob();
}
}
public class JobGiver_RandomWander : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new WanderJob();
}
}
public class JobGiver_Idel : AIBase
{
public override JobBase GetJob(Entity.Entity target)
{
return new IdleJob();
}
}
}

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 30648f750dce43e493f5e94cb735988c
timeCreated: 1754974329