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

[转载发布] DreamX's Victory Aftermath Extension

[复制链接]
累计送礼:
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

    灌水之王

    发表于 前天 07:59 | 显示全部楼层 |阅读模式
    DreamX's Victory Aftermath Extension
            By DreamX

             
    Introduction/Features
            This is an extension for Yanfly's Victory Aftermath. It also extends Aftermath Level Up. The overall goal was to allow for victory quotes to be displayed during Victory Aftermath like the VX Ace version. But since you can use custom script calls, you can do other things too.


            Here's a video example of what can be done with the plugin.










    Script


    Patch Notes


            1.3a - In victory action effects for level up, you can now reference the actor by using the "actor" variable, i.e.


    console.log(actor.actorId());


            1.3 - Adds compatibility with Yanfly's Job Points. You can define actions specific to the job point window during the victory aftermath.


            1.1 - Adds parameters for window opacity. Adds compatibility with my Choice Help plugin. Adds random victory themes. Simply put multiple bgm file names in the parameter in Yanfly's Victory Aftermath separated by a space. Example: Town1 Theme2


    How to Use


    Place under Yanfly plugins.
            Right click the script link and select save link as a .js file.


            Requires Yanfly's Victory Aftermath and Aftermath Level Up (if you are going to do level up actions).


    /*:
    * @plugindesc v1.3 Perform actions like messages during Victory Aftermath
    * @author DreamX
    *
    * @param Always Use VX-Ace Style EXP Window
    * @desc Always use the VX-Ace style exp window even if there is no message to display. Default: false
    * @default false
    *
    * @param VX-Ace Style EXP Text
    * @desc When VX-Ace Style EXP window is used, this is used for the exp gained label. Default: EXP
    * @default EXP
    *
    * @param Victory EXP Opacity
    * @desc The opacity of the Victory EXP window. Default: 255
    * @default 255
    *
    * @param Victory Drop Opacity
    * @desc The opacity of the Victory Drop window. Default: 255
    * @default 255
    *
    * @param Victory Level Up Opacity
    * @desc The opacity of the Victory Level Up window. Default: 255
    * @default 255
    *
    * @param Victory Title Opacity
    * @desc The opacity of the Victory Title window that appears at the top. Default: 255
    * @default 255
    *
    * @help
    * //===========================================================================
    * // Notetags
    * //===========================================================================
    * You must use notetags in order to have actions during the victory aftermath
    * windows. Victory actions for the exp and drop windows may be put in any
    * actor's notebox, but actions for the level up windows (that Yanfly's
    * Aftermath Level Up extension provides) must be put into the notebox of the
    * actor associated. For example, if you want an action to occur when Harold
    * levels up, you must put that action in his notebox.
    *
    * <VICTORY ACTION TYPE: x>
    * This notetag is required. Replace x with the type of window where this action
    * will be performed. There are three options: exp, level, and drop. You can
    * also use jp if you are using Yanfly's Job Points plugin.
    * Example:
    * <VICTORY ACTION TYPE: drop>
    *
    * <VICTORY ACTION CONDITION>
    * x
    * </VICTORY ACTION CONDITION>
    * This notetag set is optional, but you need it if you want to set special
    * conditions for an action to occur. Replace x with a script condition.
    * Example:
    * <VICTORY ACTION CONDITION>
    * $gameSwitches.value(1)
    * </VICTORY ACTION CONDITION>
    * The condition in this example is that the switch 1 is on.
    *
    * <VICTORY ACTION PRIORITY>
    * x
    * </VICTORY ACTION PRIORITY>
    * This notetag set is optional. Replace x with a script. This is the priority
    * for the action. If there is more than one action that passes its condition,
    * this plugin will test the action's priority and choose the one with the
    * highest priority if possible. If there is more than one action with the
    * highest condition, a random one of those actions will be selected. By
    * default, every action's priority is 0, but you can override it with this
    * notetag set.
    * Example:
    * <VICTORY ACTION PRIORITY>
    * $gameVariables.value(1)
    * </VICTORY ACTION PRIORITY>
    * This script will set the priority of the action to be the value of variable
    * 1.
    *
    * <VICTORY ACTION NO MESSAGE>
    * This notetag is optional. If you use this for an action, it will not shorten
    * the Victory Aftermath windows in order to accomodate a message window. This
    * is useful for any action that does not cause a message to appear. Note that
    * if at least one level up action that will occur during the level up window
    * is not set with this notetag, the level up window will still be shortened to
    * accomodate for a message.
    *
    * <VICTORY ACTION EFFECT>
    * x
    * </VICTORY ACTION EFFECT>
    * This notetag set is required. Replace x with a script. This is the effect
    * performed when the action occurs. This notetag set also closes parsing for
    * this action, meaning this needs to be the last notetag for the action. After
    * this, you can start defining more actions in the same notebox.
    * Example:
    * <VICTORY ACTION EFFECT>
    * console.log("Hello World");
    * </VICTORY ACTION EFFECT>
    *
    * //===========================================================================
    * // Script calls provided by this plugin
    * //===========================================================================
    * To assist people in creating conditions or effects for an action, a couple
    * functions are provided by this plugin for that purpose. This should be
    * especially useful for people without much javascript experience.
    *
    * this.DXVACommonEvent("x") - Replace x with a common event id(s). This will
    * cause a common event to occur. You can use commas (for separate ids) or
    * dashes (for ranges) for multiple ids. A random common event of the ones
    * passed to this function will be chosen.
    * Example:
    * this.DXVACommonEvent("1-3, 7");
    * In this example, common event 1, 2, 3 or 7 will be chosen to occur.
    *
    * this.DXVADropsHasTag("x") - Replace with a notetag name. This function
    * returns whether one of the battle drops has a notetag. In other words, it
    * can be used as a condition.
    * Example:
    * this.DXVADropsHasTag("IsPotion");
    * In this example, the condition is that one of the battle drops has a notetag
    * named IsPotion, for example, <IsPotion:1>
    *
    * this.DXVAEnemiesHasTag("x") - Replace with a notetag name. This function
    * returns whether one of the enemies had a notetag. In other words, it
    * can be used as a condition.
    * Example:
    * this.DXVAEnemiesHasTag("IsImp");
    * In this example, the condition is that one of the battle drops has a notetag
    * named IsImp, for example, <IsImp:1>
    *
    * If you require javascript assistance, I recommend either asking in the
    * thread for this plugin or in the javascript help section.
    * ===========================================================================
    * Terms Of Use
    * ===========================================================================
    * Free to use and modify for commercial and noncommercial games, with credit.
    * ===========================================================================
    * Compatibility
    * ===========================================================================
    * Set under Yanfly plugins.
    * ===========================================================================
    * Credits
    * ===========================================================================
    * DreamX
    * Thanks to Yanfly for the original plugin which this is an extension of.
    */


            Here is an example of notetags.

                    Code:       
    1. // when the exp window appears, execute
    2. // common event 1
    3. -----
    4. <VICTORY ACTION TYPE: exp>
    5. <VICTORY ACTION EFFECT>
    6. this.DXVACommonEvent("1");
    7. </VICTORY ACTION EFFECT>
    8. // when the exp window appears, execute
    9. // common event 11 if one of the enemies
    10. // had a notetag name IsImp
    11. -----
    12. <VICTORY ACTION TYPE: exp>
    13. <VICTORY ACTION CONDITION>
    14. this.DXVAEnemiesHasTag("IsImp");
    15. </VICTORY ACTION CONDITION>
    16. <VICTORY ACTION PRIORITY>
    17. 1
    18. </VICTORY ACTION PRIORITY>
    19. <VICTORY ACTION EFFECT>
    20. this.DXVACommonEvent("11");
    21. </VICTORY ACTION EFFECT>
    22. // when a potion is dropped, execute
    23. // common event 8
    24. -------------------
    25. <VICTORY ACTION TYPE: drop>
    26. <VICTORY ACTION CONDITION>
    27. this.DXVADropsHasTag("IsPotion");
    28. </VICTORY ACTION CONDITION>
    29. <VICTORY ACTION EFFECT>
    30. this.DXVACommonEvent("8");
    31. </VICTORY ACTION EFFECT>
    32. // When Harold levels up, execute common
    33. // event 12
    34. -------------------
    35. <VICTORY ACTION TYPE: level>
    36. <VICTORY ACTION EFFECT>
    37. this.DXVACommonEvent("12");
    38. </VICTORY ACTION EFFECT>
    39. // if there was 3 or more unique items
    40. // dropped execute common event 10
    41. -----------
    42. <VICTORY ACTION TYPE: drop>
    43. <VICTORY ACTION CONDITION>
    44. BattleManager._rewards.items.length >= 3
    45. </VICTORY ACTION CONDITION>
    46. <VICTORY ACTION EFFECT>
    47. this.DXVACommonEvent("10");
    48. </VICTORY ACTION EFFECT>
    复制代码




    本贴来自国际rpgmaker官方论坛作者:DreamX处,因国际论坛即将永久关站,为了存档多年珍贵资料,署名转载到本论坛存档,由于官方帖子为英文原帖,需要中文翻译请点击论坛顶部切换语言为中文就可以将帖子翻译成中文浏览,方便大家随时查看,原文地址:https://forums.rpgmakerweb.com/threads/dreamxs-victory-aftermath-extension.60509/
    天天去同能,天天有童年!
    回复 送礼论坛版权

    使用道具 举报

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

    本版积分规则

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

    幸运抽奖

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

    立即查看

    聊天机器人
    Loading...

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

    GMT+8, 2026-8-1 01:34 , Processed in 0.142427 second(s), 52 queries .

    Powered by Discuz! X3.4

    Copyright © 2001-2020, Tencent Cloud.

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