Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

I've Searched for hours and no luck HELP!

Ok I've played around with RMXP for about a year now and now I discovered these nice new scripts. I have came Across a Script before that allows your skills to change when your class changes
ex: Fighter Lv. 10 : Crosscut lv. 1
=------------------Faint Cut lv. 5
=------------------Slash blah lv. 10
=----------Change Class to Mage
=----Mage Lv.10 : Fire lv.1
=------------------water lv. 2
=------------------Ice lv. 5
=------------------thunder lv. 10
= ->Loses old skills and learns the new ones plus the others!
Does anyone know what Im talking about yet???

and is there a script someone can post here that lets you setup the battle menu for each class
ex : Fighter : Attack Mage : Support Blah : Attack
= --------------Skill--------------Skill---------Support
= -------------Defend-----------Defend--------Taunt
=---------------Item-------------Item---------Focus

were the support are skills and taunt acts as the attack but lowers attack or defense or etc.

and lastly is there a script that will disallow enemies to attack the leader??

thanks for the help and I will credit the first person to help me in each catagory!!!:D
 
First request.
Do you ask for a script or edit an already existing script? If asking for a new script, I think my last script can help (just need some edit then).

Second request.
Have you tried Trickster's Advanced Individual Battle Command (or something like that, I forgot the script name)?

Third request.
Leader of whom: your party or enemy troop?
A. If it's the leader of your party...
How will you determine the leader? By actor ID or by position?
B. If it's the leader of enemy troop...
Will each troop have a leader?

But I think you'll answer A. Well, just offering :D
 
OK I think what he wants is some what the same as in the Dragon Quest/Warrior games, were as if you change the character's class they acquire new magic spells or fighting techs. I'm sure someone could make one like that but it'll be a wile before they could create it. So don't be rushing into the scripting request area without thinking first. It may seem like a long time but in the end it'll be worth it.
 
for you second request you can use Tricksters Advanced Battle Commands. Demo to it can be found on the link on his signature. Its' SDK dependent though.
-OR-
you can use the one Vash made, which isn't SDK dependent.
Code:
#==============================================================================
# ** Individual Commands
#==============================================================================
# Vash (rmxp.org)
# 2006-08-24 (Date Reposted)
#------------------------------------------------------------------------------
# * Instructions:
# Change the "Attack1" and "Skills1" (same for the others) to 
# whatever you want (corresponding to the class' id), if you have more than 4 
# classes, you can add {'CLASS_ID'=>5,'Attack'=>'Attack5'} and as much as you 
# need...
#==============================================================================

#==============================================================================
# ** Scene_Battle
#==============================================================================
class Scene_Battle
Attack_command_names = [
  {'CLASS_ID'=>1,'Attack'=>'Attack'}, # Change "Attack1" to what you want.
  {'CLASS_ID'=>2,'Attack'=>'Attack'},
  {'CLASS_ID'=>3,'Attack'=>'Attack'},
  {'CLASS_ID'=>4,'Attack'=>'Attack'},
  {'CLASS_ID'=>5,'Attack'=>'Attack'},
  {'CLASS_ID'=>6,'Attack'=>'Attack'},
  {'CLASS_ID'=>7,'Attack'=>'Attack'} # Only the last one doesn't have a , .
]

Skills_command_names = [
  {'CLASS_ID'=>1,'Skills'=>'Skills1'}, # Change "Skills1" to what you want.
  {'CLASS_ID'=>2,'Skills'=>'Skills1'},
  {'CLASS_ID'=>3,'Skills'=>'Skills1'},
  {'CLASS_ID'=>4,'Skills'=>'Skills1'},
  {'CLASS_ID'=>5,'Skills'=>'Skills1'},
  {'CLASS_ID'=>6,'Skills'=>'Skills1'},
  {'CLASS_ID'=>7,'Skills'=>'Skills1'} #Only the last one doesn't have a , .
]
end

#==============================================================================
# ** Window_Command
#==============================================================================
class Window_Command
def set_command_name(index,name)
  @commands[index] = name
  refresh
 end
end

#==============================================================================
# ** Scene_Battle (Attack)
#==============================================================================
class Scene_Battle
alias diverse_attack_commands_phase3_setup_command_window phase3_setup_command_window
def phase3_setup_command_window
  diverse_attack_commands_phase3_setup_command_window
  return if @active_battler.nil?
  Attack_command_names.each do |names|
    if names['CLASS_ID'] == @active_battler.class_id
# The number represents each command 0:attack, 1:skills, 3:defend, and 4:items
      @actor_command_window.set_command_name(0,names['Attack']) 
      break
     end
   end
 end
end

#==============================================================================
# ** Scene_Battle (Skills)
#==============================================================================
class Scene_Battle
alias diverse_skills_commands_phase3_setup_command_window phase3_setup_command_window
def phase3_setup_command_window
  diverse_skills_commands_phase3_setup_command_window
  return if @active_battler.nil?
  Skills_command_names.each do |names|
    if names['CLASS_ID'] == @active_battler.class_id
# The number represents each command 0:attack, 1:skills, 3:defend, and 4:items
      @actor_command_window.set_command_name(1,names['Skills'])
      break
     end
   end
 end
end
 
The first one is pretty much done for me thanks alot!!! just a minor bug!

The second one I tried Vash's Script and it runs through but nothing changes!
so I'm lost on that one...

and the third script I do say its the lead party member ex: the First Member in position 0 and the class ID is 001!

so if I can get some help I'd be greatful...
 
For the Vash script just change :
Code:
{'CLASS_ID'=>1,'Skills'=>'Skills1'}
to something like :
Code:
{'CLASS_ID'=>1,'Skills'=>'Magic'}

So if you're first class (Classes Tab) in the database is a Magician or something then it should change to that.
 
I've worked on first, check your post.

I'll try working on the third right now.

EDIT:

Does this (party leader cannot be attacked) apply to skills to? S/He'll be invincible then :)

LATEST EDIT:

Here is it. I added an option so enemies can attack the leader when there's no more actor left (otherwise, enemies won't attack leader at all). Leader can only be attacked by skills that target all actors.

Code:
# Settings begin here
# In which position the leader is?
LEADER_POS = 0
# Leader's actor ID
LEADER_ID = 1
# Can leader still be attacked when there's no more actor left?
LEADER_ATTACKED_LAST = false
# Settings end here

class Game_Actor < Game_Battler
  # do not attack this actor if s/he is the leader
  def targetable?
    # Get actor position
    for actor in $game_party.actors
      if actor.id == id
        actor_pos = $game_party.actors.index(actor)
        break
      end
    end
    # Not targetable if actor is in leader position and actor is leader
    return false if actor_pos == LEADER_POS and id == LEADER_ID
    return true
  end
end

class Game_Party
  #--------------------------------------------------------------------------
  # * Random Selection of Target Actor
  #     hp0 : limited to actors with 0 HP
  #--------------------------------------------------------------------------
  def random_target_actor(hp0 = false)
    # Initialize roulette
    roulette = []
    # Loop
    for actor in @actors
      # If it fits the conditions
      if ((not hp0 and actor.exist? and actor.targetable?) or (hp0 and actor.hp0?))
        # Get actor class [position]
        position = $data_classes[actor.class_id].position
        # Front guard: n = 4; Mid guard: n = 3; Rear guard: n = 2
        n = 4 - position
        # Add actor to roulette n times
        n.times do
          roulette.push(actor)
        end
      end
    end
    # If roulette size is 0
    if roulette.size == 0
      # Lrader can be attacked when there's no more actor left?
      if LEADER_ATTACKED_LAST
        # Leader exist?
        leader = @actors[LEADER_POS]
        if leader.exist?
          roulette.push(leader)
        else
          return nil
        end
      else
        return nil
      end
    end
    # Spin the roulette, choose an actor
    return roulette[rand(roulette.size)]
  end
  #--------------------------------------------------------------------------
  # * Smooth Selection of Target Actor
  #     actor_index : actor index
  #--------------------------------------------------------------------------
  def smooth_target_actor(actor_index)
    # Get an actor
    actor = @actors[actor_index]
    # If an actor exists
    if actor != nil and actor.exist? and actor.targetable?
      return actor
    end
    # Loop
    for actor in @actors
      # If an actor exists
      if actor.exist? and actor.targetable?
        return actor
      end
    end
    # Attack leader when there's no more actor left
    return @actors[LEADER_POS] if LEADER_ATTACKED_LAST
  end
end

Tell me if there's any error and/or something doesn't match your request.
 
yes ex... he cannot be harmed by any enemy unless i call the event upon his harm... so yeah... but i want it as if the enemy ignores the 1st party member without any problems... like he isn't there... but hopefully with the script i can still have the enemy forced to attack by an event process...

need any information just tell me!!

and has anyone got an update for the second script... because i can't use tricksters, because the download section is offline...?
 
Sorry for late response, I was working on my final project for the last 2 months.

That's weird... I tried with 8 enemies at once and 3 party members, being the first one is the leader, with all settings left as in the script I posted above. The second actor can be attacked, although at a glance s/he might be attacked constantly (but it's still randomized)...
 
wow EX my old friend... your back!!!

no problem that you had to finish your project :thumb:

glad to hear your back to the fourms!

but yeah... i postponed that whole game... i need to work on everything for it... so i set it aside!
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top