diff --git a/OshimaModules/Skills/NiuNan/智慧与力量.cs b/OshimaModules/Skills/NiuNan/智慧与力量.cs index 2d768b2..c0be3ae 100644 --- a/OshimaModules/Skills/NiuNan/智慧与力量.cs +++ b/OshimaModules/Skills/NiuNan/智慧与力量.cs @@ -40,10 +40,7 @@ namespace Oshima.FunGame.OshimaModules.Skills public override void OnEffectLost(Character character) { - if (character.PrimaryAttribute == PrimaryAttribute.INT) - { - ResetEffect(character, false); - } + ResetEffect(character, false); } private void ResetEffect(Character character, bool isAdd) @@ -107,10 +104,7 @@ namespace Oshima.FunGame.OshimaModules.Skills c.ExINT -= 交换的基础智力; c.ExSTR += 交换的基础智力; c.Recovery(pastHP, pastMP, pastMaxHP, pastMaxMP); - if (已经加过) - { - ResetEffect(character, false); - } + ResetEffect(character, false); } } else @@ -126,10 +120,7 @@ namespace Oshima.FunGame.OshimaModules.Skills c.ExINT += 交换的基础智力; 交换的基础智力 = 0; c.Recovery(pastHP, pastMP, pastMaxHP, pastMaxMP); - if (!已经加过) - { - ResetEffect(character, true); - } + ResetEffect(character, true); } } } diff --git a/OshimaServers/FastAutoServer.cs b/OshimaServers/FastAutoServer.cs index 6f3be2f..9247fb0 100644 --- a/OshimaServers/FastAutoServer.cs +++ b/OshimaServers/FastAutoServer.cs @@ -171,6 +171,7 @@ namespace Oshima.FunGame.OshimaServers { SendAllGamingMessage(obj, data, str); }); + actionQueue.InitActionQueue(); actionQueue.SetCharactersToAIControl(false, inGameCharacters); // 总游戏时长 diff --git a/OshimaServers/Service/FunGameActionQueue.cs b/OshimaServers/Service/FunGameActionQueue.cs index d708846..1ec1202 100644 --- a/OshimaServers/Service/FunGameActionQueue.cs +++ b/OshimaServers/Service/FunGameActionQueue.cs @@ -35,6 +35,7 @@ namespace Oshima.FunGame.OshimaServers.Service MaxRespawnTimes = maxRespawnTimes, MaxScoreToWin = maxScoreToWin }; + actionQueue.InitActionQueue(); actionQueue.SetCharactersToAIControl(false, characters); foreach (Character dead in characters) { @@ -251,6 +252,7 @@ namespace Oshima.FunGame.OshimaServers.Service MaxRespawnTimes = maxRespawnTimes, MaxScoreToWin = maxScoreToWin }; + actionQueue.InitActionQueue(); actionQueue.SetCharactersToAIControl(false, characters); foreach (Character dead in characters) { diff --git a/OshimaServers/Service/FunGameSimulation.cs b/OshimaServers/Service/FunGameSimulation.cs index e3a5fe6..9d80546 100644 --- a/OshimaServers/Service/FunGameSimulation.cs +++ b/OshimaServers/Service/FunGameSimulation.cs @@ -125,6 +125,10 @@ namespace Oshima.FunGame.OshimaServers.Service Level = slevel }; c.Skills.Add(疾风步); + foreach (Effect e in c.Effects) + { + e.OnEffectLost(c); + } } // 创建顺序表并排序 @@ -201,9 +205,8 @@ namespace Oshima.FunGame.OshimaServers.Service // 显示角色信息 if (PrintOut) characters.ForEach(c => Console.WriteLine(c.GetInfo())); - // 因赋予了装备,所以清除排序重新排 - actionQueue.ClearQueue(); - actionQueue.InitCharacterQueue(characters); + // 初始化队列,准备开始游戏 + actionQueue.InitActionQueue(); actionQueue.SetCharactersToAIControl(false, characters); if (PrintOut) Console.WriteLine(); @@ -226,7 +229,7 @@ namespace Oshima.FunGame.OshimaServers.Service user.Username = FunGameService.GenerateRandomChineseUserName(); user.Inventory.Credits = 20; Character thisCharacter = shuffledCharacters[cid]; - thisCharacter.User = user; + //thisCharacter.User = user; if (cid % 2 == 0) { @@ -238,9 +241,9 @@ namespace Oshima.FunGame.OshimaServers.Service } } - // 添加到团队字典,第一个用户为队长 - tg.AddTeam($"{group1.First().User.Username}的小队", group1); - tg.AddTeam($"{group2.First().User.Username}的小队", group2); + // 添加到团队字典,第一个为队长 + tg.AddTeam($"{group1.First()}的小队", group1); + tg.AddTeam($"{group2.First()}的小队", group2); foreach (string team in tg.Teams.Keys) {