阶段性完成
This commit is contained in:
@@ -7,29 +7,58 @@ namespace Cielonos.MainGame.Characters
|
||||
{
|
||||
public class ReactionSubcontroller : SubcontrollerBase<CharacterBase>
|
||||
{
|
||||
public Dictionary<BreakthroughType, CompoundVariable<bool>> breakthroughResistances;
|
||||
public Dictionary<BreakthroughType, bool> originalBreakthroughResistances;
|
||||
public Dictionary<BreakthroughType, bool> breakthroughResistances;
|
||||
public DodgeSubmodule dodgeSm;
|
||||
public BlockSubmodule blockSm;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
breakthroughResistances = new Dictionary<BreakthroughType, CompoundVariable<bool>>()
|
||||
|
||||
originalBreakthroughResistances = new Dictionary<BreakthroughType, bool>()
|
||||
{
|
||||
{ BreakthroughType.None, new CompoundVariable<bool>(true) },
|
||||
{ BreakthroughType.Weak, new CompoundVariable<bool>(true) },
|
||||
{ BreakthroughType.Medium, new CompoundVariable<bool>(true) },
|
||||
{ BreakthroughType.Heavy, new CompoundVariable<bool>(false) },
|
||||
{ BreakthroughType.SuperHeavy, new CompoundVariable<bool>(false) }
|
||||
{ BreakthroughType.None, true },
|
||||
{ BreakthroughType.Weak, true },
|
||||
{ BreakthroughType.Medium, true },
|
||||
{ BreakthroughType.Heavy, true },
|
||||
{ BreakthroughType.Disruption, false },
|
||||
{ BreakthroughType.Forced, false },
|
||||
{ BreakthroughType.Unstoppable, false },
|
||||
};
|
||||
|
||||
breakthroughResistances = new Dictionary<BreakthroughType, bool>()
|
||||
{
|
||||
{ BreakthroughType.None, true },
|
||||
{ BreakthroughType.Weak, true },
|
||||
{ BreakthroughType.Medium, true },
|
||||
{ BreakthroughType.Heavy, true },
|
||||
{ BreakthroughType.Disruption, false },
|
||||
{ BreakthroughType.Forced, false },
|
||||
{ BreakthroughType.Unstoppable, false },
|
||||
};
|
||||
|
||||
dodgeSm = new DodgeSubmodule(this);
|
||||
blockSm = new BlockSubmodule(this);
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
if (owner.statusSm.isDead)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
dodgeSm.Update();
|
||||
blockSm.Update();
|
||||
}
|
||||
|
||||
public void ResetBreakthroughResistances()
|
||||
{
|
||||
foreach (var kvp in originalBreakthroughResistances)
|
||||
{
|
||||
breakthroughResistances[kvp.Key] = kvp.Value;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user