12.10 进度 基本完成

This commit is contained in:
SoulliesOfficial
2025-12-10 18:22:26 -05:00
parent 8d6267e1a2
commit f7cab3e784
224 changed files with 11116 additions and 6240 deletions

View File

@@ -19,22 +19,12 @@ namespace Continentis.Mods.Basic.Buffs
this.statusSubmodule = new StatusSubmodule(this, StatusType.Protected);
this.contentSubmodule = new ContentSubmodule(this);//TODO: 以后增加角色的ContentSubmodule
this.contentSubmodule = new ContentSubmodule(this)
.AddParameterGetter("Protector", GetProtectorNames);
this.iconSubmodule = new IconSubmodule(this).SetTextFunctions();
this.eventSubmodule = new EventSubmodule(this);
/*
this.eventSubmodule.onOpponentDecideAction.Add("Protected",
new EventUnit<CharacterBase, IntendedCard, CharacterBase>((opponent, intendedCard, originalTarget) =>
{
if (opponent is CombatNPC npc)
{
intendedCard.targets.Remove(originalTarget);
//intendedCard.targets.Add(protector); //TODO: 后续用设计专门的函数决定目标改变
}
}));
*/
}
public override bool OnBuffApply(out CharacterCombatBuffBase existingBuff)
@@ -55,5 +45,24 @@ namespace Continentis.Mods.Basic.Buffs
return true;
}
private string GetProtectorNames()
{
List<string> names = new List<string>();
foreach (Protecting protector in protectingSources)
{
names.Add(protector.attachedCharacter.data.displayName);
Debug.Log($"Protector found: {protector.attachedCharacter.data.displayName}");
}
if (names.Count == 1)
{
return names[0];
}
else
{
return string.Join(", ", names);
}
}
}
}