- Added DownDash ability with cooldown and speed configuration. - Introduced DownDashState to handle down dashing mechanics, including gravity manipulation and animation playback. - Updated PlayerMovement to support DownDash functionality. - Enhanced PlayerStats to manage spring charge consumption and healing. - Modified PlayerCombat and WeaponHitBoxInstance to support new hit confirmation events. - Updated AbilityType to include new form types for character abilities. - Improved Gizmos for better visualization of enemy detection and attack ranges. - Added feedback systems for form switching in PlayerFeedback and IFeedbackPlayer. - Refactored combat and movement states to accommodate new abilities and ensure smooth transitions.
38 lines
1.3 KiB
C#
38 lines
1.3 KiB
C#
using UnityEngine;
|
|
|
|
namespace BaseGames.Player
|
|
{
|
|
[CreateAssetMenu(menuName = "BaseGames/Player/Stats")]
|
|
public class PlayerStatsSO : ScriptableObject
|
|
{
|
|
[Header("HP")]
|
|
public int MaxHP = 5;
|
|
|
|
[Header("Soul")]
|
|
public int MaxSoulPower = 100;
|
|
|
|
[Header("Spirit")]
|
|
public int MaxSpiritPower = 100;
|
|
public int SpiritRegenRate = 5; // 每秒回复量
|
|
|
|
[Header("Spring (治愈弹簧)")]
|
|
public int MaxSpringCharges = 3;
|
|
public int SpringHealAmount = 2;
|
|
public int SpringKillThreshold = 4; // 击杀数触发弹簧恢复
|
|
|
|
[Header("无敌帧")]
|
|
public float InvincibilityDuration = 0.6f;
|
|
|
|
[Header("初始货币")]
|
|
public int InitialLingZhu = 0;
|
|
|
|
[Header("初始已解锁能力")]
|
|
[Tooltip("角色出生时默认持有的能力([Flags] 位掩码)。\n\n" +
|
|
"FormTianHun:天魂形态默认解锁,请务必勾选。\n\n" +
|
|
"Dash:地面与空中冲刺统一控制,勾选后即可使用 DashState。\n\n" +
|
|
"DoubleJump:追加次数由 PlayerMovementConfigSO.MaxAirJumps 决定。\n" +
|
|
"落地或 Pogo 命中后次数自动重置。")]
|
|
public AbilityType InitialAbilities = AbilityType.FormTianHun;
|
|
}
|
|
}
|