模拟原神圣遗物系统-小森设计项目,设计第一个圣遗物套装(冒险家)死之羽

引言

emmm 怎么说呢 虽然休息了几十天。 感觉也就这样 先不管怎么加成 百分比加成 就算是有 也写不出来 所以首先先不管百分比,就说数值

Plumeofdeath::Plumeofdeath(int id, string name, int Level){
    this->id = id;
    this->name = name;
    this->level = Level;

}

死之羽 可能有点小改当然变化是有点的,但问题不是非常大

实现

int adventurerPlumeofdeath::ATK(){
    MainGlossary* mainGlossary = dynamic_cast<decltype(mainGlossary)>(m_Glossary);
    return (mainGlossary ? mainGlossary->Attack() : 0);
}

string adventurerPlumeofdeath::SubEntry()
{
    return string();
}

void adventurerPlumeofdeath::updateEntry()
{
   // int size = m_SubEntry.size();


    // UpdeateSubEntry = new UpdeateSubEntry(this);
    //switch (this->level) {

    //case 4:
    //    //if ((3 == size)) {
    //    //    //随机生成

    //    //}
    //    //else {
    //    //    //  UpdeateSubEntry. Updeate();
    //    //}

    //case 6:
    //    // UpdeateSubEntry. Updeate();
    //case 8:
    //    // UpdeateSubEntry. Updeate();

    //case 12:
    //    // UpdeateSubEntry. Updeate();

    //default:

    //};

}

ArtifactSetType adventurerPlumeofdeath::getArtifactSetType()
{
    return ArtifactSetType::adventurer;
}

adventurerPlumeofdeath::~adventurerPlumeofdeath(){
    delete this->m_Glossary;
}

设计思路
继承死之羽老爹的遗产 ,重写老爹的部分 就变成我冒险者

以下是一个简单的 Python 代码示例,用于输出神中的遗物类: ```python class Relic: def __init__(self, name, rarity, set_bonus): self.name = name self.rarity = rarity self.set_bonus = set_bonus class RelicSet: def __init__(self, name, two_piece_bonus, four_piece_bonus): self.name = name self.two_piece_bonus = two_piece_bonus self.four_piece_bonus = four_piece_bonus # 遗物类别 class Flower(Relic): pass class Feather(Relic): pass class Sands(Relic): pass class Goblet(Relic): pass class Circlet(Relic): pass # 遗物套装 class Adventurer(RelicSet): pass class LuckyDog(RelicSet): pass class Instructor(RelicSet): pass # 示例遗物 flower_of_life = Flower("生之花", "5星", "生之花套装效果:(2) 生之花套装效果提高生命值上限20%。") plume_of_death = Feather("死之羽", "5星", "死之羽套装效果:(2) 死之羽套装效果提高攻击力20点。") sands_of_eon = Sands("时之沙", "5星", "时之沙套装效果:(2) 时之沙套装效果提高元素充能效率25%。") goblet_of_eonothem = Goblet("空之杯", "5星", "空之杯套装效果:(2) 空之杯套装效果提高元素精通60点。") circlet_of_logos = Circlet("理之冠", "5星", "理之冠套装效果:(2) 理之冠套装效果提高暴击率20%。") adventurer_set = Adventurer("冒险家", "冒险家套装效果:(2) 获得15%的全伤害加成。", "冒险家套装效果:(4) 开宝箱获得的经验值提高20%。") lucky_dog_set = LuckyDog("幸运儿", "幸运儿套装效果:(2) 战斗结束后,有60%的几率获得一只幸运狗的祝福,持续300秒,提高所有队员获得的金币数10%。", "幸运儿套装效果:(4) 开宝箱获得的概率提高30%。") instructor_set = Instructor("教官", "教官套装效果:(2) 元素精通提高80点。", "教官套装效果:(4) 触发元素反应后,全队元素精通提高120点,持续8秒。") # 输出示例遗物信息 print(flower_of_life.name) print(flower_of_life.rarity) print(flower_of_life.set_bonus) print(plume_of_death.name) print(plume_of_death.rarity) print(plume_of_death.set_bonus) print(sands_of_eon.name) print(sands_of_eon.rarity) print(sands_of_eon.set_bonus) print(goblet_of_eonothem.name) print(goblet_of_eonothem.rarity) print(goblet_of_eonothem.set_bonus) print(circlet_of_logos.name) print(circlet_of_logos.rarity) print(circlet_of_logos.set_bonus) # 输出示例遗物套装信息 print(adventurer_set.name) print(adventurer_set.two_piece_bonus) print(adventurer_set.four_piece_bonus) print(lucky_dog_set.name) print(lucky_dog_set.two_piece_bonus) print(lucky_dog_set.four_piece_bonus) print(instructor_set.name) print(instructor_set.two_piece_bonus) print(instructor_set.four_piece_bonus) ``` 输出结果如下: ``` 生之花 5星 生之花套装效果:(2) 生之花套装效果提高生命值上限20%。 死之羽 5星 死之羽套装效果:(2) 死之羽套装效果提高攻击力20点。 时之沙 5星 时之沙套装效果:(2) 时之沙套装效果提高元素充能效率25%。 空之杯 5星 空之杯套装效果:(2) 空之杯套装效果提高元素精通60点。 理之冠 5星 理之冠套装效果:(2) 理之冠套装效果提高暴击率20%。 冒险家 冒险家套装效果:(2) 获得15%的全伤害加成。 冒险家套装效果:(4) 开宝箱获得的经验值提高20%。 幸运儿 幸运儿套装效果:(2) 战斗结束后,有60%的几率获得一只幸运狗的祝福,持续300秒,提高所有队员获得的金币数10%。 幸运儿套装效果:(4) 开宝箱获得的概率提高30%。 教官 教官套装效果:(2) 元素精通提高80点。 教官套装效果:(4) 触发元素反应后,全队元素精通提高120点,持续8秒。 ```
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

小森程序员

若能帮助到你,小费自愿付费

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值