Tales Of~ Battle Advantage

MartaLualdi

Lullaby~
Veteran
Joined
Jan 6, 2014
Messages
35
Reaction score
5
Primarily Uses
For those who aren't familiar with the Tales Of Series, basically depending on which position you touch an enemy, you either get preemptive bonuses, or surprise attack debuffs. If you touch the enemy from behind, you get the advantage, on the other hand if the enemy touches your back they get the upper hand. (Might as well change the battle disadvantage to touching the enemy while being in front of it, to make it easier)

I was wondering if someone could give me an idea, or help me, do something more a less like this. I'm already aware of several battle advantage scripts, such as Yanfly's. Just wanted to know if there was some way to recreate this one.

I want to know if there is some way to determine from which direction you touch an event, based on the direction it is currently facing.

Thank you~ :D
 
Last edited by a moderator:

nio kasgami

VampCat
Veteran
Joined
May 21, 2013
Messages
8,949
Reaction score
3,042
First Language
French
Primarily Uses
RMMV
well if I understand you want something like a special encounter ....?
 

SoulPour777

Crownless King
Veteran
Joined
Aug 15, 2012
Messages
1,093
Reaction score
104
First Language
English
Primarily Uses
N/A
If your enemies are in the map and triggers a Battle Processing event, then there's an easy way to do this.
 

MartaLualdi

Lullaby~
Veteran
Joined
Jan 6, 2014
Messages
35
Reaction score
5
Primarily Uses
If your enemies are in the map and triggers a Battle Processing event, then there's an easy way to do this.
Yes they are in map and trigger the battles, I never really liked random encounters...

And... REALLY? :D !
 

AwesomeCool

Bratty and spoiled little sister
Veteran
Joined
Jul 20, 2013
Messages
2,862
Reaction score
1,947
First Language
English
Primarily Uses
N/A
I have a solution for you  :)    This script allows you to change prep to true to activate a preemptive encounter and surp to true if a surprise encounter.  All you have to do is event when you want this to happen.  (note: only works with touch encounters).  Hope this helps.  :)

Code:
#change via a script call : BattleManager.prep or surp = true or false#give credit to AwesomeCoolmodule BattleManager    class << self    attr_accessor :prep    attr_accessor :surp  end    #--------------------------------------------------------------------------  # * Initialize Member Variables  #--------------------------------------------------------------------------  def self.init_members    @phase = :init              # Battle Progress Phase    @can_escape = false         # Can Escape Flag    @can_lose = false           # Can Lose Flag    @event_proc = nil           # Event Callback#~     @preemptive = false         # Preemptive Attack Flag#~     @surprise = false           # Surprise Flag    @preemptive = ( rate_preemptive)    @surprise = ( rate_surprise && !preemptive )    @prep = false    @surp = false    @actor_index = -1           # Actor for Which Command Is Being Entered    @action_forced = nil        # Force Action    @map_bgm = nil              # For Memorizing Pre-Battle BGM    @map_bgs = nil              # For Memorizing Pre-Battle BGS    @action_battlers = []       # Action Order List  end    def self.rate_preemptive    if @prep == true      @preemptive = true    else      @preemptive = false    end  end  def self.rate_surprise    if @surp == true && @prep == !true      @surprise = true    else      @surprise = false    end  endend
 

MartaLualdi

Lullaby~
Veteran
Joined
Jan 6, 2014
Messages
35
Reaction score
5
Primarily Uses
I have a solution for you  :)    This script allows you to change prep to true to activate a preemptive encounter and surp to true if a surprise encounter.  All you have to do is event when you want this to happen.  (note: only works with touch encounters).  Hope this helps.  :)

#change via a script call : BattleManager.prep or surp = true or false#give credit to AwesomeCoolmodule BattleManager class << self attr_accessor :prep attr_accessor :surp end #-------------------------------------------------------------------------- # * Initialize Member Variables #-------------------------------------------------------------------------- def self.init_members @phase = :init # Battle Progress Phase @can_escape = false # Can Escape Flag @can_lose = false # Can Lose Flag @event_proc = nil # Event Callback#~ @preemptive = false # Preemptive Attack Flag#~ @surprise = false # Surprise Flag @preemptive = ( rate_preemptive) @surprise = ( rate_surprise && !preemptive ) @prep = false @surp = false @actor_index = -1 # Actor for Which Command Is Being Entered @action_forced = nil # Force Action @map_bgm = nil # For Memorizing Pre-Battle BGM @map_bgs = nil # For Memorizing Pre-Battle BGS @action_battlers = [] # Action Order List end def self.rate_preemptive if @prep == true @preemptive = true else @preemptive = false end end def self.rate_surprise if @surp == true && @prep == !true @surprise = true else @surprise = false end endend
Thank you! <3

However my problem is exactly that... I have no clue on how to event this. On making it a preemptive attack if you touch another event from behind, and making it a surprise attack if an enemy touches the character's back.

What I want to know is how to determine THAT, a way to know from which direction from the event's perspective, the player touched it. (If an enemy on map event is looking down, and you approach from above and touch "his back" before he turns to your direction preemptive happens.)

And the reason I believe this is possible is that whenever you place an NPC that doesn't move, and talk to it on any direction, it actually turns to the direction you are talking him from, instead of not turning at all. So it DOES know which direction you triggered the event from.
 

SoulPour777

Crownless King
Veteran
Joined
Aug 15, 2012
Messages
1,093
Reaction score
104
First Language
English
Primarily Uses
N/A
 

Yes. If they trigger the battle, the first thing you need to do is to determine whether the player is facing right, left, up, or down in Player Touch (on the enemy event). Since you need to determine all of this, you'll probably need the move route of your enemies chasing you.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,865
Messages
1,017,059
Members
137,575
Latest member
akekaphol101
Top