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

[转载发布] Activate Equipment

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

    连续签到: 2 天

    [LV.7]常住居民III

    7959

    主题

    864

    回帖

    3万

    积分

    管理员

    Rank: 9Rank: 9Rank: 9

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

    灌水之王

    发表于 3 天前 | 显示全部楼层 |阅读模式
    Activate Equipment 1.2
    ATT_Turan


    Introduction
    This plugin was a request I received to be able to use equipment for effects in battle. Apparently the request was motivated by Dragon Quest, but it reminded me of the Shining Force and Phantasy Star games.

    I have tested the basic functionality, please let me know if you encounter any errors. I will consider making compatibility patches if the other plugin is free to use (or one I own, such as a Yanfly product) and unobfuscated. Otherwise, other authors are free to modify this code to make it compatible with theirs so long as I am still credited.

    Spoiler: Features
    Using this plugin, you can assign weapons and armor to have the function of consumable items or skills in your database. You will then be able to go into the Items menu in battle, and any equipment with that assignation the current actor has equipped will show up to be used.

    There are a number of options that can be configured. The default functionality lets the player freely activate equipped items as their turn  in battle. You can instead impose a limit so each actor may only activate each item once per battle. If using Yanfly's Item Core, you can also set a specific number of charges per item, and whether or not they recharge automatically.

    Finally, you can specify a chance that an item will "crack" when activated. This does not impair its basic weapon/armor functionality, but prevents it from being activated again until the item is repaired. This option requires the use of Yanfly's Item Core with the parameters set to make weapons and armor independent items. You can also set a second chance that when an item cracks it will break, destroying and immediately removing the item.
    Spoiler: Screenshots

    Spoiler: How to Use
    Use the following notetag in the notebox of your Weapons or Armor:

    <activateequipment: [skill/item] ID>

    Example: <activateequipment: skill 14>

    The word specifies whether the equipment is referencing a skill or item in your database. The ID determines which skill or item. Note that any costs associated with a skill are ignored when activating it from equipment.

    <activateonce>

    This notetag limits the equipment to being activated once per actor per battle.

    <cancrack: [chance]>

    Example: <cancrack: 40> would give the equipment a 40% chance to crack

    This does not change how frequently the equipment can be activated, but gives each activation the specified percent chance to crack. A cracked item still has all of its parameters and functions normally as equipment, but is not available to be activated again in battle. Once it's repaired, it can be activated again normally. This notetag will not function unless your project also has Yanfly's Item Core and weapons and armor are set to be independent items.

    <crackbreak: [chance]>

    Example: <crackbreak: 33> would give the equipment a 40% chance to break when it cracks

    This gives the equipment a chance to break and be permanently destroyed each time it cracks. This will have no effect unless the <cancrack> notetag is on the item.

    <breaktext: [text]>

    Example: <breaktext: The Holy Ring shatters into hundreds of pieces!>

    This will allow you to create a custom message to display when a piece of equipment breaks. If specified, it will display after the crack message.

    <activatecharges: [number]>

    Example: <activatecharges: 4>

    This will give the equipment a certain number of charges. Activating the equipment in battle spends one charge and equipment cannot be activated when it has no charges left. Charges will replenish at the start of each battle unless otherwise specified.

    <chargespersist>

    This notetag causes charges to persist between battles instead of refilling automatically.
    Spoiler: Plugin Commands / Script Calls
    RepairEquipment

    This plugin command will repair all cracked equipment owned by the party.

    RechargeEquipment

    This plugin command will reset all equipment owned by the party to their maximum charges.

    CrackRepair(item)

    This function can be used to repair an individual cracked equipment. This may be useful if you want to have vendors that charge for each repair, or if you want an actor to be able to repair their own items during battle.

    IsCracked(item)

    This will return whether a specified weapon/armor is cracked.

    RechargeItem(item)

    This function can be used to reset an individual piece of equipment back to its maximum charges.

    item.charges

    This variable tracks an item's current number of charges.

    actor.activating

    If an actor is activating a piece of equipment, a copy of it will be stored in this variable for the duration of that action.
    Terms and Credits
    Free for non-commercial and commercial use. Credit ATT_Turan.


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

    本帖子中包含更多资源

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

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

    使用道具 举报

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

    本版积分规则

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

    幸运抽奖

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

    立即查看

    聊天机器人
    Loading...

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

    GMT+8, 2026-8-1 05:52 , Processed in 0.084853 second(s), 53 queries .

    Powered by Discuz! X3.4

    Copyright © 2001-2020, Tencent Cloud.

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