MemeMayhem / ModExamples

11 stars 3 forks source link

能否给wiki中的方法加一点点注释 #100

Closed fuxiao1563 closed 3 weeks ago

fuxiao1563 commented 1 month ago

每次都找的挺辛苦的)

GoodCrispyShark commented 1 month ago

请指明需要注释的部分

fuxiao1563 commented 1 month ago

CombatUnit Methods AttackManager Methods 这两个

GoodCrispyShark commented 1 month ago

CombatUnit是战斗双方的基类 AttackMannager是战斗双方弹夹的基类

并不是所有方法都暴露出来了 最好能指明需要哪些方法的注释

fuxiao1563 commented 1 month ago

那这 CombatUnit Methods zh_CN 和 AttackManager Methods 中比较长的这些的吧

CombatUnit Methods zh_CN

---@param callback fun(level)
CombatUnit:RegisterOnUnitCreateCallback(perk_or_relic_name, callback)

---@param callback fun(level)
CombatUnit:RegisterOnBeforeCombatStartCallback(perk_or_relic_name, callback)

---@param callback fun(level, target)
CombatUnit:RegisterOnCombatStartCallback(perk_or_relic_name, callback)

---@param callback fun(level)
CombatUnit:RegisterOnCombatEndCallback(perk_or_relic_name, callback)

---@param callback fun(level, time)
CombatUnit:RegisterOnCombatPeriodicCallback(perk_or_relic_name, callback)

---@param callback fun(level, time)
CombatUnit:RegisterOnCombatDelayedCallback(perk_or_relic_name, callback)

---@param callback fun(level, damage_amount, attacker, defender)
CombatUnit:RegisterOnDamageTakenCallback(perk_or_relic_name, callback)

---@param callback fun(level, damage_amount, attacker, defender)
CombatUnit:RegisterOnDamageDealCallback(perk_or_relic_name, callback)

---@param callback fun(level, heal_amount, healer)
CombatUnit:RegisterOnHealCallback(perk_or_relic_name, callback)

---@param callback fun(level, consume_amount)
CombatUnit:RegisterOnGoldConsumeCallback(perk_or_relic_name, callback)

---@param callback fun(level, current_gold)
CombatUnit:RegisterOnPlayerGoldChangeCallback(perk_or_relic_name, callback)

---@param callback fun(level, perk_id)
CombatUnit:RegisterOnBuyPerkCallback(perk_or_relic_name, callback)

---@param callback fun(level, relic_id)
CombatUnit:RegisterOnBuyRelicCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnStunnedCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnEnemyStunnedCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnStunnedEndCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnEnemyStunnedEndCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnPoolymorphedCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
CombatUnit:RegisterOnEnemyPoolymorphedCallback(perk_or_relic_name, callback)

---@param callback fun(level, attribute, old_value, new_value)
CombatUnit:RegisterOnSetAttributeCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster)
CombatUnit:RegisterOnOpponentMissileLaunchCallback(perk_or_relic_name, callback)

AttackManager Methods

---@param target CombatUnit
---@param missile_id string
AttackManager:NewMissileAttack(target, missile_id)

---@param target CombatUnit
---@param from_open_hand boolean
AttackManager:NewUltimateAttack(target, from_open_hand)

---@param callback fun(level)
AttackManager:RegisterOnMagazineResetCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target)
AttackManager:RegisterOnMissileLaunchCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target)
AttackManager:RegisterOnMissileHitCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target)
AttackManager:RegisterOnMissileImpactCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target, block)
AttackManager:RegisterOnMissileDamageBlockCallback(perk_or_relic_name, callback)

---@param callback fun(level, caster, target)
AttackManager:RegisterOnUltimateLaunchCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target)
AttackManager:RegisterOnUltimateImpactCallback(perk_or_relic_name, callback)

---@param callback fun(level, attack_data, caster, target)
AttackManager:RegisterOnUltimateHitCallback(perk_or_relic_name, callback)
fx013 commented 1 month ago

@NinjaAqua445 AttackManager和CombatUnit wiki现在只有列表,有时间的时候帮忙加些解释吧。

ninjaaquaoutlook commented 3 weeks ago

已添加。