This commit is contained in:
liuliang 2024-12-23 22:33:19 +08:00
commit c0e9f2e103
3 changed files with 11 additions and 5 deletions

View File

@ -5,6 +5,8 @@ using UnityEngine;
public class SkillUp : MonoBehaviour
{
[Header("基类")] public Role role;
[HideInInspector]public Fun fun;//用于buff的创建
[Header("攻击伤害加成倍数")] public float DamageUp=1f;
[Header("攻击范围加成倍数")] public float AttackRange = 1f;
[Header("攻击冷却加成倍速")] public float AttackCooldown = 1f;

View File

@ -1,6 +1,10 @@
using System;
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEditor.U2D.Path.GUIFramework;
using UnityEngine;
using static Google.Protobuf.Reflection.ExtensionRangeOptions.Types;
public class laohuSkillUp :SkillUp
{
@ -9,7 +13,6 @@ public class laohuSkillUp :SkillUp
/// </summary>
public override void Skill_1_1()
{
base.Skill_1_1();
base.AttackRange *= 2;
}
/// <summary>
@ -18,7 +21,11 @@ public class laohuSkillUp :SkillUp
public override void Skill_1_3()
{
base.AttackRange *= 0.75f;
//buff
// 创建一个眩晕 Buff持续1秒20%概率)
Action<Role> decelerationBuff = fun.CreateDecelerationBuff(1f, 0.2f);
// 将 Buff 添加到玩家的 storageBuff 列表中
role.AddBuff(role.storageBuff,decelerationBuff);
}
/// <summary>
/// 喷火冷却时间减少50%,持续喷火时间减少50%

View File

@ -6,11 +6,8 @@ public class enemy : Role
{
public string enemyId;
[Header("移动速度")] public float moveSpeed;
[HideInInspector]
public float harmNumber = 0; // 伤害
public float HarmNumber
{
get => harmNumber;