设为首页收藏本站同能贴吧 切换语言 繁体中文
开启辅助访问 切换到窄版
扫描二维码关注官方公众号
返回列表
+ 发新帖
查看: 99|回复: 0

[转载发布] Super Skill Nerf XP

[复制链接]
累计送礼:
0 个
累计收礼:
1 个
  • TA的每日心情
    开心
    2026-7-12 04:10
  • 签到天数: 209 天

    连续签到: 2 天

    [LV.7]常住居民III

    9015

    主题

    864

    回帖

    6万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

    VIP
    7
    卡币
    58751
    OK点
    16
    推广点
    0
    同能卷
    50
    积分
    68660

    灌水之王

    发表于 2026-7-27 13:45:10 | 显示全部楼层 |阅读模式
    Super Skill Nerf XP

    by Kyonides


    Introduction

    Nerf! Nerf! Nerf your favorite super duper skills!
    Yes, even up to the point where your heroes can only use them once per battle!
    Just add the Skill ID to the ONLY_ONCE_SKILL_IDS array and that's it!
    Or add it to the ONLY_TWICE_SKILL_IDS to cast the skill twice!

    Or Cool Them Down!
    Just add the Skill ID to the COOLDOWN_SKILL_IDS and how many turns that skill should not be used and that's it!

    Example:
                    Ruby:       
    1. COOLDOWN_SKILL_IDS = { 12 => 2, 20 => 4 }
    复制代码


    And just in case you want to clear this skill use limit once per call:
                    Ruby:       
    1. $game_party.clear_used_skills!
    复制代码


    If you want to clear the cooldowns ingame, use this:
                    Ruby:       
    1. $game_party.clear_skill_cooldowns!
    复制代码


    The Script - Simple Version

                    Ruby:       
    1. # * Super Skill Nerf XP * #
    2. #   Scripter : Kyonides
    3. #   v1.2.1 - 2025-09-25
    4. # Nerf! Nerf! Nerf your favorite super duper skills!
    5. # Even up to the point where your heroes can only use them once per battle!
    6. # Just add the Skill ID to the ONLY_ONCE_SKILL_IDS array and that's it!
    7. # Or add it to the ONLY_TWICE_SKILL_IDS to cast the skill twice!
    8. # Or Cool Them Down!
    9. # Just add the Skill ID to the COOLDOWN_SKILL_IDS and how many turns that skill
    10. # should not be used and that's it!
    11. # Example: COOLDOWN_SKILL_IDS = { 12 => 2, 20 => 4 }
    12. # * Optional Script Calls * #
    13. # - Just in case you want to clear this skill use limit once per call:
    14. # $game_party.clear_used_skills!
    15. # - Just in case you want to clear the skill cooldowns:
    16. # $game_party.clear_skill_cooldowns!
    17. module RPG
    18.   class Skill
    19.     ONLY_ONCE_SKILL_IDS  = [57]
    20.     ONLY_TWICE_SKILL_IDS = []
    21.     COOLDOWN_SKILL_IDS = { 7 => 2 }
    22.     def cast_once?
    23.       ONLY_ONCE_SKILL_IDS.include?(@id)
    24.     end
    25.     def cast_twice?
    26.       ONLY_TWICE_SKILL_IDS.include?(@id)
    27.     end
    28.     def has_cooldown?
    29.       COOLDOWN_SKILL_IDS.has_key?(@id)
    30.     end
    31.     def cooldown
    32.       COOLDOWN_SKILL_IDS[@id] || 0
    33.     end
    34.   end
    35. end
    36. class Game_Battler
    37.   alias :kyon_ssn_gm_btlr_sk_fx :skill_effect
    38.   def skill_effect(user, skill)
    39.     user.refresh_skill_data(skill) if user.actor?
    40.     kyon_ssn_gm_btlr_sk_fx(user, skill)
    41.   end
    42.   def actor?
    43.     false
    44.   end
    45. end
    46. class Game_Actor
    47.   alias :kyon_ssn_gm_act_stp :setup
    48.   alias :kyon_ssn_gm_act_sk_cn_use? :skill_can_use?
    49.   def setup(actor_id)
    50.     kyon_ssn_gm_act_stp(actor_id)
    51.     @used_skills = {}
    52.     @skill_cd = {}
    53.     @used_skills.default = 0
    54.     @skill_cd.default = 0
    55.   end
    56.   def skill_used?(skill_id)
    57.     @used_skills[skill_id] > 0
    58.   end
    59.   def skill_cd?(skill_id)
    60.     @skill_cd[skill_id] > 0
    61.   end
    62.   def skill_can_use?(skill_id)
    63.     skill = $data_skills[skill_id]
    64.     return unless skill
    65.     return if skill.has_cooldown? and skill_cd?(skill_id)
    66.     return if @used_skills[skill_id] != 0 and skill.cast_once?
    67.     return if @used_skills[skill_id] == 2 and skill.cast_twice?
    68.     kyon_ssn_gm_act_sk_cn_use?(skill_id)
    69.   end
    70.   def refresh_skill_data(skill)
    71.     @used_skills[skill.id] += 1
    72.     @skill_cd[skill.id] = skill.cooldown
    73.   end
    74.   def decrease_skill_cooldowns!
    75.     @skill_cd.keys.each {|k| @skill_cd[k] -= 1 }
    76.     @skill_cd.delete_if {|k, v| v < 1 }
    77.   end
    78.   def clear_used_skills!
    79.     @used_skills.clear
    80.   end
    81.   def clear_skill_cooldowns!
    82.     @skill_cd.clear
    83.   end
    84.   def actor?
    85.     true
    86.   end
    87.   attr_reader :used_skills, :skill_cd
    88. end
    89. class Game_Party
    90.   def decrease_skill_cooldowns!
    91.     @actors.each {|actor| actor.decrease_skill_cooldowns! }
    92.   end
    93.    
    94.   def clear_used_skills!
    95.     @actors.each {|actor| actor.clear_used_skills! }
    96.   end
    97.   def clear_skill_cooldowns!
    98.     @actors.each {|actor| actor.clear_skill_cooldowns! }
    99.   end
    100. end
    101. class Scene_Battle
    102.   alias :kyon_ssn_scn_btl_st_ph4 :start_phase4
    103.   alias :kyon_ssn_scn_btl_btl_end :battle_end
    104.   def start_phase4
    105.     $game_party.decrease_skill_cooldowns!
    106.     kyon_ssn_scn_btl_st_ph4
    107.   end
    108.   def battle_end(result)
    109.     $game_party.clear_used_skills!
    110.     $game_party.clear_skill_cooldowns!
    111.     kyon_ssn_scn_btl_btl_end(result)
    112.   end
    113. end
    复制代码


    You'd need to download a demo to get the Colored version.



    Terms & Conditions

    Free as in beer for non commercial games.
    Include my nickname in your game credits.
    Thank Opozorilo for making the script request. (Optional aka a Joke)
    That's it!



    本贴来自国际rpgmaker官方论坛作者:kyonides处,因国际论坛即将永久关站,为了存档多年珍贵资料,署名转载到本论坛存档,由于官方帖子为英文原帖,需要中文翻译请点击论坛顶部切换语言为中文就可以将帖子翻译成中文浏览,方便大家随时查看,原文地址:https://forums.rpgmakerweb.com/threads/super-skill-nerf-xp.179971/

    本帖子中包含更多资源

    您需要 登录 才可以下载或查看,没有账号?立即注册

    x
    天天去同能,天天有童年!
    回复 送礼论坛版权

    使用道具 举报

    文明发言,和谐互动
    文明发言,和谐互动
    高级模式
    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    简体中文
    繁體中文
    English(英语)
    日本語(日语)
    Deutsch(德语)
    Русский язык(俄语)
    بالعربية(阿拉伯语)
    Türkçe(土耳其语)
    Português(葡萄牙语)
    ภาษาไทย(泰国语)
    한어(朝鲜语/韩语)
    Français(法语)
    关闭

    幸运抽奖

    社区每日抽奖来袭,快来试试你是欧皇还是非酋~

    立即查看

    聊天机器人
    Loading...

    QQ|Archiver|手机版|小黑屋|同能RPG制作大师 ( 沪ICP备12027754号-3 )

    GMT+8, 2026-8-4 11:49 , Processed in 0.140453 second(s), 52 queries .

    Powered by Discuz! X3.4

    Copyright © 2001-2020, Tencent Cloud.

    快速回复 返回顶部 返回列表