mirror of
https://github.com/project-redbud/FunGame-Core.git
synced 2025-12-05 00:06:02 +00:00
优化代码;修复队友助攻另一个队友被击杀的问题
This commit is contained in:
parent
d163e00730
commit
c4ea6a7c90
@ -38,15 +38,13 @@ namespace Milimoe.FunGame.Core.Api.Utility
|
|||||||
/// <param name="error"></param>
|
/// <param name="error"></param>
|
||||||
public void AddTask(string name, TimeSpan timeOfDay, Action action, Action<Exception>? error = null)
|
public void AddTask(string name, TimeSpan timeOfDay, Action action, Action<Exception>? error = null)
|
||||||
{
|
{
|
||||||
lock (_lock)
|
using Lock.Scope scope = _lock.EnterScope();
|
||||||
|
ScheduledTask task = new(name, timeOfDay, action, error);
|
||||||
|
if (DateTime.Now > DateTime.Today.Add(timeOfDay))
|
||||||
{
|
{
|
||||||
ScheduledTask task = new(name, timeOfDay, action, error);
|
task.LastRun = DateTime.Today.Add(timeOfDay);
|
||||||
if (DateTime.Now > DateTime.Today.Add(timeOfDay))
|
|
||||||
{
|
|
||||||
task.LastRun = DateTime.Today.Add(timeOfDay);
|
|
||||||
}
|
|
||||||
_tasks.Add(task);
|
|
||||||
}
|
}
|
||||||
|
_tasks.Add(task);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -59,17 +57,15 @@ namespace Milimoe.FunGame.Core.Api.Utility
|
|||||||
/// <param name="error"></param>
|
/// <param name="error"></param>
|
||||||
public void AddRecurringTask(string name, TimeSpan interval, Action action, bool startNow = false, Action<Exception>? error = null)
|
public void AddRecurringTask(string name, TimeSpan interval, Action action, bool startNow = false, Action<Exception>? error = null)
|
||||||
{
|
{
|
||||||
lock (_lock)
|
using Lock.Scope scope = _lock.EnterScope();
|
||||||
|
DateTime now = DateTime.Now;
|
||||||
|
now = new DateTime(now.Year, now.Month, now.Day, now.Hour, now.Minute, now.Second, 0);
|
||||||
|
DateTime nextRun = startNow ? now : now.Add(interval);
|
||||||
|
RecurringTask recurringTask = new(name, interval, action, error)
|
||||||
{
|
{
|
||||||
DateTime now = DateTime.Now;
|
NextRun = nextRun
|
||||||
now = new DateTime(now.Year, now.Month, now.Day, now.Hour, now.Minute, now.Second, 0);
|
};
|
||||||
DateTime nextRun = startNow ? now : now.Add(interval);
|
_recurringTasks.Add(recurringTask);
|
||||||
RecurringTask recurringTask = new(name, interval, action, error)
|
|
||||||
{
|
|
||||||
NextRun = nextRun
|
|
||||||
};
|
|
||||||
_recurringTasks.Add(recurringTask);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -78,11 +74,9 @@ namespace Milimoe.FunGame.Core.Api.Utility
|
|||||||
/// <param name="name"></param>
|
/// <param name="name"></param>
|
||||||
public void RemoveTask(string name)
|
public void RemoveTask(string name)
|
||||||
{
|
{
|
||||||
lock (_lock)
|
using Lock.Scope scope = _lock.EnterScope();
|
||||||
{
|
int removeTasks = _tasks.RemoveAll(t => t.Name == name);
|
||||||
int removeTasks = _tasks.RemoveAll(t => t.Name == name);
|
int removeRecurringTasks = _recurringTasks.RemoveAll(t => t.Name == name);
|
||||||
int removeRecurringTasks = _recurringTasks.RemoveAll(t => t.Name == name);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
@ -167,56 +161,54 @@ namespace Milimoe.FunGame.Core.Api.Utility
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
private void CheckAndRunTasks()
|
private void CheckAndRunTasks()
|
||||||
{
|
{
|
||||||
lock (_lock)
|
using Lock.Scope scope = _lock.EnterScope();
|
||||||
|
DateTime now = DateTime.Now;
|
||||||
|
|
||||||
|
foreach (ScheduledTask task in _tasks)
|
||||||
{
|
{
|
||||||
DateTime now = DateTime.Now;
|
if (!task.IsTodayRun)
|
||||||
|
|
||||||
foreach (ScheduledTask task in _tasks)
|
|
||||||
{
|
{
|
||||||
if (!task.IsTodayRun)
|
if (now.TimeOfDay >= task.TimeOfDay && now.TimeOfDay < task.TimeOfDay.Add(TimeSpan.FromSeconds(10)))
|
||||||
{
|
{
|
||||||
if (now.TimeOfDay >= task.TimeOfDay && now.TimeOfDay < task.TimeOfDay.Add(TimeSpan.FromSeconds(10)))
|
task.LastRun = now;
|
||||||
{
|
|
||||||
task.LastRun = now;
|
|
||||||
Task.Run(() =>
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
task.Action();
|
|
||||||
}
|
|
||||||
catch (Exception ex)
|
|
||||||
{
|
|
||||||
task.Error = ex;
|
|
||||||
TXTHelper.AppendErrorLog(ex.ToString());
|
|
||||||
task.ErrorHandler?.Invoke(ex);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
foreach (RecurringTask recurringTask in _recurringTasks)
|
|
||||||
{
|
|
||||||
if (now >= recurringTask.NextRun)
|
|
||||||
{
|
|
||||||
recurringTask.LastRun = now;
|
|
||||||
recurringTask.NextRun = recurringTask.NextRun.Add(recurringTask.Interval);
|
|
||||||
Task.Run(() =>
|
Task.Run(() =>
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
recurringTask.Action();
|
task.Action();
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
recurringTask.Error = ex;
|
task.Error = ex;
|
||||||
TXTHelper.AppendErrorLog(ex.ToString());
|
TXTHelper.AppendErrorLog(ex.ToString());
|
||||||
recurringTask.ErrorHandler?.Invoke(ex);
|
task.ErrorHandler?.Invoke(ex);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
foreach (RecurringTask recurringTask in _recurringTasks)
|
||||||
|
{
|
||||||
|
if (now >= recurringTask.NextRun)
|
||||||
|
{
|
||||||
|
recurringTask.LastRun = now;
|
||||||
|
recurringTask.NextRun = recurringTask.NextRun.Add(recurringTask.Interval);
|
||||||
|
Task.Run(() =>
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
recurringTask.Action();
|
||||||
|
}
|
||||||
|
catch (Exception ex)
|
||||||
|
{
|
||||||
|
recurringTask.Error = ex;
|
||||||
|
TXTHelper.AppendErrorLog(ex.ToString());
|
||||||
|
recurringTask.ErrorHandler?.Invoke(ex);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -40,28 +40,31 @@ namespace Milimoe.FunGame.Core.Entity
|
|||||||
{
|
{
|
||||||
baseMultiplier = Character.EquipSlot.Weapon.WeaponType switch
|
baseMultiplier = Character.EquipSlot.Weapon.WeaponType switch
|
||||||
{
|
{
|
||||||
WeaponType.OneHandedSword => 1.0,
|
WeaponType.OneHandedSword => GameplayEquilibriumConstant.OneHandedSwordBaseMultiplier,
|
||||||
WeaponType.TwoHandedSword => 1.2,
|
WeaponType.TwoHandedSword => GameplayEquilibriumConstant.TwoHandedSwordBaseMultiplier,
|
||||||
WeaponType.Bow => 0.9,
|
WeaponType.Bow => GameplayEquilibriumConstant.BowBaseMultiplier,
|
||||||
WeaponType.Pistol => 0.8,
|
WeaponType.Pistol => GameplayEquilibriumConstant.PistolBaseMultiplier,
|
||||||
WeaponType.Rifle => 1.1,
|
WeaponType.Rifle => GameplayEquilibriumConstant.RifleBaseMultiplier,
|
||||||
WeaponType.DualDaggers => 0.85,
|
WeaponType.DualDaggers => GameplayEquilibriumConstant.DualDaggersBaseMultiplier,
|
||||||
WeaponType.Talisman => 1.0,
|
WeaponType.Talisman => GameplayEquilibriumConstant.TalismanBaseMultiplier,
|
||||||
WeaponType.Staff => 1.15,
|
WeaponType.Staff => GameplayEquilibriumConstant.StaffBaseMultiplier,
|
||||||
WeaponType.Polearm => 0.95,
|
WeaponType.Polearm => GameplayEquilibriumConstant.PolearmBaseMultiplier,
|
||||||
WeaponType.Gauntlet => 1.05,
|
WeaponType.Gauntlet => GameplayEquilibriumConstant.GauntletBaseMultiplier,
|
||||||
WeaponType.HiddenWeapon => 0.9,
|
WeaponType.HiddenWeapon => GameplayEquilibriumConstant.HiddenWeaponBaseMultiplier,
|
||||||
_ => 1.0
|
_ => 1.0
|
||||||
};
|
};
|
||||||
double levelBonus = Character.EquipSlot.Weapon.WeaponType switch
|
double levelBonus = Character.EquipSlot.Weapon.WeaponType switch
|
||||||
{
|
{
|
||||||
WeaponType.TwoHandedSword => 0.06,
|
WeaponType.OneHandedSword => GameplayEquilibriumConstant.OneHandedSwordLevelBonus,
|
||||||
WeaponType.Staff => 0.056,
|
WeaponType.TwoHandedSword => GameplayEquilibriumConstant.TwoHandedSwordLevelBonus,
|
||||||
WeaponType.Bow => 0.045,
|
WeaponType.Bow => GameplayEquilibriumConstant.BowLevelBonus,
|
||||||
WeaponType.Pistol => 0.0375,
|
WeaponType.Pistol => GameplayEquilibriumConstant.PistolLevelBonus,
|
||||||
WeaponType.DualDaggers => 0.0375,
|
WeaponType.Rifle => GameplayEquilibriumConstant.RifleLevelBonus,
|
||||||
WeaponType.Polearm => 0.044,
|
WeaponType.DualDaggers => GameplayEquilibriumConstant.DualDaggersLevelBonus,
|
||||||
WeaponType.HiddenWeapon => 0.044,
|
WeaponType.Staff => GameplayEquilibriumConstant.StaffLevelBonus,
|
||||||
|
WeaponType.Polearm => GameplayEquilibriumConstant.PolearmLevelBonus,
|
||||||
|
WeaponType.Gauntlet => GameplayEquilibriumConstant.GauntletLevelBonus,
|
||||||
|
WeaponType.HiddenWeapon => GameplayEquilibriumConstant.HiddenWeaponLevelBonus,
|
||||||
_ => 0.05
|
_ => 0.05
|
||||||
};
|
};
|
||||||
baseMultiplier += levelBonus * (Level - 1);
|
baseMultiplier += levelBonus * (Level - 1);
|
||||||
@ -137,17 +140,17 @@ namespace Milimoe.FunGame.Core.Entity
|
|||||||
{
|
{
|
||||||
ht = Character.EquipSlot.Weapon.WeaponType switch
|
ht = Character.EquipSlot.Weapon.WeaponType switch
|
||||||
{
|
{
|
||||||
WeaponType.OneHandedSword => 8,
|
WeaponType.OneHandedSword => GameplayEquilibriumConstant.OneHandedSwordHardness,
|
||||||
WeaponType.TwoHandedSword => 12,
|
WeaponType.TwoHandedSword => GameplayEquilibriumConstant.TwoHandedSwordHardness,
|
||||||
WeaponType.Bow => 9,
|
WeaponType.Bow => GameplayEquilibriumConstant.BowHardness,
|
||||||
WeaponType.Pistol => 6,
|
WeaponType.Pistol => GameplayEquilibriumConstant.PistolHardness,
|
||||||
WeaponType.Rifle => 11,
|
WeaponType.Rifle => GameplayEquilibriumConstant.RifleHardness,
|
||||||
WeaponType.DualDaggers => 7,
|
WeaponType.DualDaggers => GameplayEquilibriumConstant.DualDaggersHardness,
|
||||||
WeaponType.Talisman => 10,
|
WeaponType.Talisman => GameplayEquilibriumConstant.TalismanHardness,
|
||||||
WeaponType.Staff => 12,
|
WeaponType.Staff => GameplayEquilibriumConstant.StaffHardness,
|
||||||
WeaponType.Polearm => 10,
|
WeaponType.Polearm => GameplayEquilibriumConstant.PolearmHardness,
|
||||||
WeaponType.Gauntlet => 8,
|
WeaponType.Gauntlet => GameplayEquilibriumConstant.GauntletHardness,
|
||||||
WeaponType.HiddenWeapon => 7,
|
WeaponType.HiddenWeapon => GameplayEquilibriumConstant.HiddenWeaponHardness,
|
||||||
_ => 10,
|
_ => 10,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -68,7 +68,7 @@ namespace Milimoe.FunGame.Core.Entity
|
|||||||
if (ActorContinuousKilling.Count > 0) builder.AppendLine($"{string.Join("\r\n", ActorContinuousKilling)}");
|
if (ActorContinuousKilling.Count > 0) builder.AppendLine($"{string.Join("\r\n", ActorContinuousKilling)}");
|
||||||
if (Assists.Count > 0) builder.AppendLine($"本回合助攻:[ {string.Join(" ] / [ ", Assists)} ]");
|
if (Assists.Count > 0) builder.AppendLine($"本回合助攻:[ {string.Join(" ] / [ ", Assists)} ]");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ActionType == CharacterActionType.PreCastSkill && Skill != null)
|
if (ActionType == CharacterActionType.PreCastSkill && Skill != null)
|
||||||
{
|
{
|
||||||
if (Skill.IsMagic)
|
if (Skill.IsMagic)
|
||||||
@ -77,11 +77,17 @@ namespace Milimoe.FunGame.Core.Entity
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
builder.AppendLine($"[ {Actor} ]:{Skill.Name}({SkillCost})-> ");
|
builder.Append($"[ {Actor} ] {Skill.Name}({SkillCost})-> ");
|
||||||
builder.AppendLine(string.Join(" / ", GetTargetsState()));
|
builder.AppendLine(string.Join(" / ", GetTargetsState()));
|
||||||
builder.AppendLine($"[ {Actor} ] 回合结束,硬直时间:{HardnessTime:0.##}");
|
builder.AppendLine($"[ {Actor} ] 回合结束,硬直时间:{HardnessTime:0.##}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (ActionType == CharacterActionType.UseItem && Item != null)
|
||||||
|
{
|
||||||
|
builder.Append($"[ {Actor} ] {Item.Name}{(SkillCost != "" ? $"({SkillCost})" : " ")}-> ");
|
||||||
|
builder.AppendLine(string.Join(" / ", GetTargetsState()));
|
||||||
|
builder.AppendLine($"[ {Actor} ] 回合结束,硬直时间:{HardnessTime:0.##}");
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
builder.AppendLine($"[ {Actor} ] 回合结束,硬直时间:{HardnessTime:0.##}");
|
builder.AppendLine($"[ {Actor} ] 回合结束,硬直时间:{HardnessTime:0.##}");
|
||||||
@ -140,7 +146,9 @@ namespace Milimoe.FunGame.Core.Entity
|
|||||||
hasDamage = "免疫";
|
hasDamage = "免疫";
|
||||||
}
|
}
|
||||||
string[] strs = [hasDamage, hasHeal, hasEffect];
|
string[] strs = [hasDamage, hasHeal, hasEffect];
|
||||||
strings.Add($"[ {target}({string.Join(" / ", strs.Where(s => s != ""))})])");
|
strs = [.. strs.Where(s => s != "")];
|
||||||
|
if (strs.Length == 0) strings.Add($"[ {target} ])");
|
||||||
|
else strings.Add($"[ {target}({string.Join(" / ", strs)})])");
|
||||||
}
|
}
|
||||||
return strings;
|
return strings;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -719,6 +719,7 @@ namespace Milimoe.FunGame.Core.Library.Constant
|
|||||||
EffectType.GrievousWound => "重伤",
|
EffectType.GrievousWound => "重伤",
|
||||||
EffectType.WeakDispelling => "持续性弱驱散",
|
EffectType.WeakDispelling => "持续性弱驱散",
|
||||||
EffectType.StrongDispelling => "持续性强驱散",
|
EffectType.StrongDispelling => "持续性强驱散",
|
||||||
|
EffectType.Recovery => "恢复",
|
||||||
_ => "未知效果"
|
_ => "未知效果"
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@ -776,6 +777,7 @@ namespace Milimoe.FunGame.Core.Library.Constant
|
|||||||
EffectType.Lifesteal => DispelledType.Weak,
|
EffectType.Lifesteal => DispelledType.Weak,
|
||||||
EffectType.GrievousWound => DispelledType.Weak,
|
EffectType.GrievousWound => DispelledType.Weak,
|
||||||
EffectType.WeakDispelling => DispelledType.Weak,
|
EffectType.WeakDispelling => DispelledType.Weak,
|
||||||
|
EffectType.Recovery => DispelledType.Weak,
|
||||||
_ => DispelledType.Weak
|
_ => DispelledType.Weak
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@ -831,6 +833,9 @@ namespace Milimoe.FunGame.Core.Library.Constant
|
|||||||
EffectType.EvadeBoost => false,
|
EffectType.EvadeBoost => false,
|
||||||
EffectType.Lifesteal => false,
|
EffectType.Lifesteal => false,
|
||||||
EffectType.GrievousWound => true,
|
EffectType.GrievousWound => true,
|
||||||
|
EffectType.WeakDispelling => false,
|
||||||
|
EffectType.StrongDispelling => false,
|
||||||
|
EffectType.Recovery => false,
|
||||||
_ => false
|
_ => false
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@ -479,7 +479,12 @@ namespace Milimoe.FunGame.Core.Library.Constant
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 持续性强驱散
|
/// 持续性强驱散
|
||||||
/// </summary>
|
/// </summary>
|
||||||
StrongDispelling
|
StrongDispelling,
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 恢复
|
||||||
|
/// </summary>
|
||||||
|
Recovery
|
||||||
}
|
}
|
||||||
|
|
||||||
public enum ItemType
|
public enum ItemType
|
||||||
|
|||||||
@ -295,6 +295,171 @@ namespace Milimoe.FunGame.Core.Model
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
public double TakenDamageGetEPMax { get; set; } = 15;
|
public double TakenDamageGetEPMax { get; set; } = 15;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 单手剑的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double OneHandedSwordBaseMultiplier { get; set; } = 1.0;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 单手剑的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double OneHandedSwordLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双手剑的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double TwoHandedSwordBaseMultiplier { get; set; } = 1.2;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双手剑的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double TwoHandedSwordLevelBonus { get; set; } = 0.06;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 弓的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double BowBaseMultiplier { get; set; } = 0.9;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 弓的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double BowLevelBonus { get; set; } = 0.04;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 手枪的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double PistolBaseMultiplier { get; set; } = 0.9;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 手枪的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double PistolLevelBonus { get; set; } = 0.03;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步枪的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double RifleBaseMultiplier { get; set; } = 1.1;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步枪的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double RifleLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双持短刀的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double DualDaggersBaseMultiplier { get; set; } = 0.85;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双持短刀的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double DualDaggersLevelBonus { get; set; } = 0.04;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法器的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double TalismanBaseMultiplier { get; set; } = 1.0;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法器的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double TalismanLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法杖的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double StaffBaseMultiplier { get; set; } = 1.15;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法杖的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double StaffLevelBonus { get; set; } = 0.04;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 长柄武器的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double PolearmBaseMultiplier { get; set; } = 0.95;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 长柄武器的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double PolearmLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 拳套的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double GauntletBaseMultiplier { get; set; } = 1.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 拳套的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double GauntletLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 暗器的基础伤害倍率
|
||||||
|
/// </summary>
|
||||||
|
public double HiddenWeaponBaseMultiplier { get; set; } = 0.9;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 暗器的基础伤害倍率成长
|
||||||
|
/// </summary>
|
||||||
|
public double HiddenWeaponLevelBonus { get; set; } = 0.05;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 单手剑的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double OneHandedSwordHardness { get; set; } = 8;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双手剑的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double TwoHandedSwordHardness { get; set; } = 12;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 弓的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double BowHardness { get; set; } = 9;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 手枪的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double PistolHardness { get; set; } = 6;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 步枪的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double RifleHardness { get; set; } = 11;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 双持短刀的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double DualDaggersHardness { get; set; } = 7;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法器的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double TalismanHardness { get; set; } = 10;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 法杖的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double StaffHardness { get; set; } = 12;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 长柄武器的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double PolearmHardness { get; set; } = 10;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 拳套的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double GauntletHardness { get; set; } = 8;
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// 暗器的硬直时间
|
||||||
|
/// </summary>
|
||||||
|
public double HiddenWeaponHardness { get; set; } = 7;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 应用此游戏平衡常数给实体
|
/// 应用此游戏平衡常数给实体
|
||||||
/// </summary>
|
/// </summary>
|
||||||
|
|||||||
@ -1730,7 +1730,10 @@ namespace Milimoe.FunGame.Core.Model
|
|||||||
CalculateCharacterDamageStatistics(actor, enemy, damage, damageType, actualDamage);
|
CalculateCharacterDamageStatistics(actor, enemy, damage, damageType, actualDamage);
|
||||||
|
|
||||||
// 计算助攻
|
// 计算助攻
|
||||||
_assistDetail[actor][enemy, TotalTime] += damage;
|
if (actor != enemy && !IsTeammate(actor, enemy))
|
||||||
|
{
|
||||||
|
_assistDetail[actor][enemy, TotalTime] += damage;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -2875,7 +2878,7 @@ namespace Milimoe.FunGame.Core.Model
|
|||||||
{
|
{
|
||||||
foreach (Character target in targets)
|
foreach (Character target in targets)
|
||||||
{
|
{
|
||||||
if (character == target) continue;
|
if (character == target || IsTeammate(character, target)) continue;
|
||||||
_assistDetail[character].NotDamageAssistLastTime[target] = TotalTime;
|
_assistDetail[character].NotDamageAssistLastTime[target] = TotalTime;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user