Instant Turn Battle

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Instant Turn Battle
By DreamX

 
Introduction/Features


Battlers perform actions instantly in an order decided by their agility. A turn ends after each battler acts. The order will be adjusted in-turn if a battler's agility is increased or decreased. This means that an example action order could be Enemy-Actor-Enemy-Enemy-Actor-Actor-Enemy.


My goal for this plugin is to make a battle system that is easy to understand and balance, and fast to play. One of my disappointments with the default battle system is how you need to process each actor's input before the actions are performed. This makes things feel sluggish. In addition, you could not adjust your tactics during the turn in response to how the battle was developing. I have noticed that some people have found difficulty balancing or understanding the turn mechanics in CTB and ATB scripts, so I believe the more predictable nature of this ITB script may be appreciated.


This script itself was  based off of Yanfly's CTB script.


As mentioned in the script documentation, please remember to credit them should you use the script.


Script


How To Use


Set the battle type to itb in Yanfly's Battle Engine Core.


Set under Yanfly plugins.


You MUST turn Dynamic Actions off if you're using YEP Battle AI Core!


I should note that you shouldn't be using anything less than 100% for Action Times+ trait in states. You can, but it'll be considered 100% by the plugin. The reason for this is that I need to keep track of the action times+ states with every action, so having less than 100% is not very compatible. If you want a chance to add an extra action, apply that to the state itself (from skill/item effect) rather than the trait.


Compatibility


There's a good chance that this plugin is not very compatible with other plugins that either alter or are based off of a different turn structure. If you spot incompatibility and would like me to introduce either a compatibility patch or intergration of what that plugin offered, let me know.


Future Updates

  • I'd like to have the visible turn order also predict the new turn order when hovering over skills that would alter it.
  • Be able to have skills that have be charged up for x amount of turns before use.
  • Be able to have team-up skills that require two or more actors to use.


Code:
 * ============================================================================
 * How To Use
 * ============================================================================
 Set the battle type to itb in Yanfly's Battle Engine Core.
 Use <free_itb_action> as a skill/item notetag to prevent
 it from consuming an action for the battler - they will be able to act
 again after it is used.
 Do NOT use YEP Instant Cast to do this - it won't work.
 
 Make sure to set the parameters to your liking.
 Put the <noExtraElemenWeaknessAction> notetag on a state to disallow opponents
 from getting an extra action from hitting the battler in their weakness.
 
 Put <elemWeaknessState:x> with x as the state id as a notetag for an actor or
 enemy to define which state is applied when they are hit in their weakness.
 This overrides the parameter setting for that actor or enemy. Use 0 to disable
 states from being applied from being hit in the weakness.
 
 Use <reAddBattler> in a skill/item to readd a battler to the pool of battlers
 if they had already finished their previous actions. Must be used with a state
 that increases action times.
 
 To use a custom ready overlay, use a file in the same folder and same style as
 States.png in img/system, make sure the parameter is set to the custom file
 name.
 * ============================================================================
 * Turn Order Window
 * ============================================================================
 Use <ITBSheet: x y z> with x being whatever you want, y being the number of 
 columns and z being the number of rows, to specify the image sheet for the 
 turn order window icon for the actor or enemy. The filename required for the 
 image will be the notetag without leading spaces. See example below.
 
 Use <ITBSheetIndex: x> to specify the index used for that image with x as 
 the index.
 
 Example:
 <ITBSheet: TurnIcons 9 10>
 <ITBSheetIndex: 1>
 
 This will use the sheet "TurnIcons 10 10.png" with 9 rows and 10 columns.
 The index will be 1. Indices start at 0.
 If you do not specify the rows and columns in the filename, the default 
 parameters will be used instead.
 
 You will name the end turn sheet used in the parameter "End Turn Sheet" 
 the same way.
 
 The plugin will trim the spaces in the beginning and end of the 
 notetag/parameter so do not use leading and trailing spaces in your filename.
 
 For example, use (without quotes)
 "turnIcons 9 10.png"
 
 instead of
 "     turnIcons 9 10   .png"
 * ============================================================================
 * Patch Notes/Known Issues/Future Updates
 * ============================================================================
 * See the forum thread for patch notes:
 * http://forums.rpgmakerweb.com/index.php?/topic/54880-instant-turn-battle-system/
 * ============================================================================
 * Terms Of Use
 * ============================================================================
 Free to use and modify for commercial and noncommercial games, with credit.
 This script was based off of Yanfly's Battle System - Charge Turn Battle
 and was programmed using Yanfly's Battle Engine Core turned on. Please credit
 them for both scripts.
 * ============================================================================
 * Credits
 * ============================================================================
 DreamX
 Yanfly - "Battle System - Charge Turn Battle" & "Battle Engine Core"
 
Last edited by a moderator:

Henryetha

Veteran
Veteran
Joined
Jan 14, 2016
Messages
388
Reaction score
206
First Language
german
Primarily Uses
Ok, tried this one and first round worked as supposed, all actors and all enemies attacked once each - at their respective turn.


But then 1 enemy kept having turns, using different attacks/skills but kept acting - no other enemy and no actors were given a turn anymore.


Used the default settings of the plugin and changed the dtb to itb in yanfly battle core.
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Ok, tried this one and first round worked as supposed, all actors and all enemies attacked once each - at their respective turn.


But then 1 enemy kept having turns, using different attacks/skills but kept acting - no other enemy and no actors were given a turn anymore.


Used the default settings of the plugin and changed the dtb to itb in yanfly battle core.


Is this plugin at the bottom of the list? What other plugins are you using that may affect it? You can try to isolate by turning off other plugins until you find the one that is causing it. If you find it, I'll try to introduce compatibility.
 

Henryetha

Veteran
Veteran
Joined
Jan 14, 2016
Messages
388
Reaction score
206
First Language
german
Primarily Uses
And again bottom on list solved it.


Had this right under Yanflys Battle Core, don't know why I didn't try, after this worked for the affixes plugin aswell :x


Thank you again!


(*Note to myself: -> plugin to the bottom.. lol )
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
No problem. Generally speaking I would place most other plugins under Yanfly Plugins, especially since Yanfly doesn't update their plugins to make them compatible with random other ones.
 

beenbaba

Slowly getting there
Veteran
Joined
Apr 28, 2015
Messages
289
Reaction score
158
First Language
English
I just realised you've move this to released from development! Congrats! (probably well overdue haha)


I would love to see the turn order added to this when you get around to it. That would be mega sweet!


I do have a request, if it's not too much to ask. Would you be able to add a pop up to the actor when they step forward like 'Ready' or 'Active' or have it hover above their head whilst you're choosing what to do? The sound is good but the visual feedback would be extra good. Obviously, if this doesn't seem worth the effort that's fine :D
 

andai

Veteran
Veteran
Joined
Oct 19, 2014
Messages
54
Reaction score
25
First Language
English
Primarily Uses
Good stuff! Really looking forward to that visible turn order! =D
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
I just realised you've move this to released from development! Congrats! (probably well overdue haha)


I would love to see the turn order added to this when you get around to it. That would be mega sweet!


I do have a request, if it's not too much to ask. Would you be able to add a pop up to the actor when they step forward like 'Ready' or 'Active' or have it hover above their head whilst you're choosing what to do? The sound is good but the visual feedback would be extra good. Obviously, if this doesn't seem worth the effort that's fine :D
v1.12 - Adds optional ready overlay for actors that are currently choosing. Use an image that is in the same style and folder as States.png in img/system.
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Turn window is coming along. It'll be in the same style as Yanfly's CTB. I mostly just need parameterize it and adjust the positioning. Predictive turn order will come later, though.
 

Bogsy

Veteran
Veteran
Joined
Oct 25, 2015
Messages
42
Reaction score
14
First Language
English
Impressive, this is coming along nicely.


Anyway to gain multiple actions hitting enemies' weaknesses but not more than once per turn cycle? 


Similar to SMT: Nocturne/Digital Devil Saga battle system.
 
Last edited by a moderator:

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Impressive, this is coming along nicely.


Anyway to gain multiple actions hitting enemies' weaknesses but not more than once per turn cycle? 


Similar to SMT: Nocturne/Digital Devil Saga battle system.
Set the parameter Max Elemental Extra Actions to 1.
 

Bogsy

Veteran
Veteran
Joined
Oct 25, 2015
Messages
42
Reaction score
14
First Language
English
Set the parameter Max Elemental Extra Actions to 1.
Was testing it before and did that but it only granted me 1 action and no more than that.


Sorry if I lacked explanation in what I meant.


Below ideal situation vs actual setting;


Actor vs Enemy1, Enemy2, Enemy3


Actor hits Enemy1 with weakness attack = +1 action


Actor goes again and hits Enemy2 with weakness attack = +1 action


Actor goes again and hits Enemy3 with weakness attack = +1 action


Actor goes again and hits Enemy1 with weakness attack = 0 action because bonus action already gained from target enemy during their turn, now goes to enemy turn.


Edit:  Ideally, if Actor uses a skill that affects all enemies with their weakness as an attack, Actor would only benefit +1 turn.


Tried setting extra actions to 1 but in only turns out like this;


Actor hits Enemy1 with weakness attack = +1 action


Actor goes again and hits Enemy2 with weakness attack = 0 action, now goes to enemy turn.


Not sure if this is affected because of my other plugins, but CTB isn't set because ITB is.
 
Last edited by a moderator:

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Was testing it before and did that but it only granted me 1 action and no more than that.


Sorry if I lacked explanation in what I meant.


Below ideal situation vs actual setting;


Actor vs Enemy1, Enemy2, Enemy3


Actor hits Enemy1 with weakness attack = +1 action


Actor goes again and hits Enemy2 with weakness attack = +1 action


Actor goes again and hits Enemy3 with weakness attack = +1 action


Actor goes again and hits Enemy1 with weakness attack = 0 action because bonus already gained on target enemy during their turn, now goes to enemy turn.


Tried setting extra actions to 1 but in only turns out like this;


Actor hits Enemy1 with weakness attack = +1 action


Actor goes again and hits Enemy2 with weakness attack = 0 action, now goes to enemy turn.


Not sure if this is affected because of my other plugins, but CTB isn't set because ITB is.
Let's say that the actor you are using in the example is Actor 1. If Actor 2 hits enemy 1 after Actor 1 had hit that enemy in its weakness (in the same turn), does Actor 2 ideally get an extra action? If not, you can achieve that using states that expire after a turn and the notetag <noExtraElemenWeaknessAction:1> .


If Actor 2 does ideally get an extra action in this example, there's nothing in the script for that yet, but I will be happy to script something for that when I can.
 

Bogsy

Veteran
Veteran
Joined
Oct 25, 2015
Messages
42
Reaction score
14
First Language
English
Let's say that the actor you are using in the example is Actor 1. If Actor 2 hits enemy 1 after Actor 1 had hit that enemy in its weakness (in the same turn), does Actor 2 ideally get an extra action? If not, you can achieve that using states that expire after a turn and the notetag <noExtraElemenWeaknessAction:1> .


If Actor 2 does ideally get an extra action in this example, there's nothing in the script for that yet, but I will be happy to script something for that when I can.


Yeah, Actor 2 does get the extra action.


No rush, glad there's a script for MV like this around in the works. Keep it up.~
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
@Bogsy @andai @beenbaba


v1.14 - Adds a parameter for the maximum amount of extra turns you can get per opponent for hitting them in their weakness. Also adds parameter to display turn order. The turn order is still WIP, I still have to parameterize everything, but you can turn it on to see it if you need to in the meantime.
 

Bogsy

Veteran
Veteran
Joined
Oct 25, 2015
Messages
42
Reaction score
14
First Language
English
@Bogsy @andai @beenbaba


v1.14 - Adds a parameter for the maximum amount of extra turns you can get per opponent for hitting them in their weakness. Also adds parameter to display turn order. The turn order is still WIP, I still have to parameterize everything, but you can turn it on to see it if you need to in the meantime.


Words cannot express how awesome this is! This is great!


Took me awhile to figure out why the maximum amount of extra turns hitting opp weaknesses wasn't working as I intended. Was gonna ask you but I wanted to see if I could solve it haha.


For anyone else wanting the P3/P4 battle like system, just set Extra Actions to -1 (infinite) and the per opponent to 1.





P.S I know turn order is still in works, but turning it on gives undefined errors.
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
Words cannot express how awesome this is! This is great!


Took me awhile to figure out why the maximum amount of extra turns hitting opp weaknesses wasn't working as I intended. Was gonna ask you but I wanted to see if I could solve it haha.


For anyone else wanting the P3/P4 battle like system, just set Extra Actions to -1 (infinite) and the per opponent to 1.





P.S I know turn order is still in works, but turning it on gives undefined errors.
No problem, I'm happy you like it.


I'm not currently getting any errors from turn order. Could you copy and paste the error from the console? It may also help to try to turn other plugins off to narrow it down.
 

Bogsy

Veteran
Veteran
Joined
Oct 25, 2015
Messages
42
Reaction score
14
First Language
English
No problem, I'm happy you like it.


I'm not currently getting any errors from turn order. Could you copy and paste the error from the console? It may also help to try to turn other plugins off to narrow it down.
Code:
rpg_managers.js:1618 TypeError: undefined is not a function
    at Window_ITBIcon.isReduceOpacity (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:1239:22)
    at Window_ITBIcon.updateOpacity (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:1215:18)
    at Window_ITBIcon.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:879:14)
    at file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:112:19
    at Array.forEach (native)
    at Scene_Battle.Scene_Base.updateChildren (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:110:19)
    at Scene_Battle.Scene_Base.update (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:42:10)
    at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:2044:33)
    at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/YEP_BattleEngineCore.js:3960:36)
    at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/YEP_VictoryAftermath.js:817:35)
 

DreamX

Veteran
Veteran
Joined
May 30, 2015
Messages
816
Reaction score
824
First Language
English
Primarily Uses
rpg_managers.js:1618 TypeError: undefined is not a function
at Window_ITBIcon.isReduceOpacity (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:1239:22)
at Window_ITBIcon.updateOpacity (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:1215:18)
at Window_ITBIcon.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/DreamX_ITB.js:879:14)
at file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:112:19
at Array.forEach (native)
at Scene_Battle.Scene_Base.updateChildren (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:110:19)
at Scene_Battle.Scene_Base.update (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:42:10)
at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/rpg_scenes.js:2044:33)
at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/YEP_BattleEngineCore.js:3960:36)
at Scene_Battle.update (file:///C:/Users/Game/Documents/Games/public_html/js/plugins/YEP_VictoryAftermath.js:817:35)
Thank you. Hopefully the version I have just uploaded will fix this error.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Stream will be live shortly with some Darkest Dungeon! Feel free to drop by!
Ah! Another nice "clear day" in....
//Smacks a nearby fleshy mass
No you! Me time, not you time! :kaolivid:
//Looks back
Where was I? Oh yes, another...
//deep breath and coughs
...nice clear day in Silent Hill. :LZSexcite:
Finally logged back to my RM central account... it's been a while.
2018 joining project as scripter*
Owner "Check it out, got all the YEP plugins!!!
2020 joining project as scripter*
Owner "Sorry, I keep meaning to get rid of these..."

Forum statistics

Threads
103,460
Messages
999,475
Members
134,999
Latest member
Azadwarf
Top