Tsukihime 1,487 Posted September 27, 2012 (edited) This script extends the troop event system with "end phase triggers". This is simply a final check on all of the event pages when a victory/lose condition has been met. Any pages that can be run during this end phase will be executed and may change the outcome of the battle. This script is completely plug-and-play and requires no additional setup. Download Get it at Hime Works Usage Plug and play. Just set up your events as usual. Edited March 2, 2015 by Tsukihime 2 BigDon and Galv reacted to this Share this post Link to post Share on other sites
Galv 1,386 Posted September 27, 2012 (edited) You mean we no longer have to do the "Make enemy immortal" workaround just to run an event once they die? Sounds good to me. Nice one, I'll definitely try this out. Just replaced the troop setups in my game that required events run after death and did a bunch of tests. No problems found with those. Can't really think of anything suggestions, though. This alone was awesome and should have happened in default engine Edited September 27, 2012 by Galv Share this post Link to post Share on other sites
Tsukihime 1,487 Posted September 27, 2012 Here is how you can extend your page conditions: http://www.rpgmakervxace.net/topic/4174-event-extend-page-conditions/ Just set the comment as "page-condition" as the first command, followed by a conditional branch, and you can use any script call you want as the page condition. Share this post Link to post Share on other sites
estriole 326 Posted September 27, 2012 (edited) finally someone able to make real phase before victory >.<. i will try this script. but a question though. the event with the page condition comment tag must be first page in troop event or anywhere is fine? sorry i ask because i want to combine this with yanfly base troop event (only set this event in one troop and other troop will get the same event page . no need to copy paste if i have loooootttsss of troops) Edited September 27, 2012 by estriole Share this post Link to post Share on other sites
Tsukihime 1,487 Posted September 27, 2012 (edited) It's the first one because I don't want to parse the entire page to figure out whether we can run it or not. This is why I asked for a proper note box implementation and not just a crappy comment solution since the comment solution is not efficient. I also prefer some structure so I would like the page condition to appear somewhere near the top. Edited September 27, 2012 by Tsukihime Share this post Link to post Share on other sites
Coolie 147 Posted September 27, 2012 This opens up so many possibilities. Awesome. Share this post Link to post Share on other sites
estriole 326 Posted September 28, 2012 It's the first one because I don't want to parse the entire page to figure out whether we can run it or not. This is why I asked for a proper note box implementation and not just a crappy comment solution since the comment solution is not efficient. I also prefer some structure so I would like the page condition to appear somewhere near the top. First page, Got it...! . will try it tonight combined with yanfly base troop event. and praying that it works . Share this post Link to post Share on other sites
Tsukihime 1,487 Posted September 28, 2012 (edited) First event of the page doesn't matter which page it is. It is always a comment followed by a conditional branch. Edited September 28, 2012 by Tsukihime Share this post Link to post Share on other sites
estriole 326 Posted October 1, 2012 nice so basicly every page could run this phase. thx for great script. will try later having two page that executed after enemy dies. Share this post Link to post Share on other sites
Tsukihime 1,487 Posted October 2, 2012 There was a bug in my extended page condition script that didn't check whether a page was already executed. This caused looping to occur during the end phase event processing. I have fixed the issue so grab a new copy of that script. Share this post Link to post Share on other sites
estriole 326 Posted October 3, 2012 AH I SEE!. i thought it was incompatibility with yanfly base troop event . it made me switch to victor event condition(but with some my own modification to make the if no default condition set and have custom condition it will return the custom condition met instead of false and also to check if the event already executed before or not). and it work like charm. and this script is godly. i try it this way tsuki. i made three pages with the condition when all enemy dead it will recover all enemy (all same except first show message 1, second show message 2, third show message 3). and after all the enemy dies for the first time it run first event that show message 1. then i slay them again. run second event that show message 2. slay them again. run third event that show message 3. then slay them again for real this time and they didn't revive again . it's great to create variation in battle. we can implement the boss changing forms without new battle. when boss dies just change the boss and full recover . Really great script you've written. ps: I will try using your new page condition script again to see does it works with yanfly base troop event. and i would also try the order of page yanfly base troop event added. is it at front of original page or back (i think it's at back but need to test it first) Share this post Link to post Share on other sites
Tsukihime 1,487 Posted October 9, 2012 Currently there are only three end-phases: win, lose, abort You can use them with extended page conditions as such BattleManager.end_phase == :win To trigger when you win/lose/abort the battle. Share this post Link to post Share on other sites