Enemy Equips

Help spread the word!Share on FacebookShare on TumblrTweet about this on TwitterShare on Google+Share on LinkedInShare on RedditFlattr the author

Do you have a game where players can visually see what enemies are using? For example, depending on what armor they wear, their appearance will change.
Or perhaps you have a stealing mechanic that allows you to steal enemy weapons and armors, which would lower the enemy’s strength and defense after those equips have been pilfered!

This plugin provides you with the ability to give enemies equips.

Enemies will receive all of the parameter bonuses and traits that the equip provides. If a skill requires a certain weapon type to be equipped, enemies must have the weapon in order to use the skill.

Download

Plugin: download here (right-click and save-as)

Required Plugins

Installation

Start by installing the required plugins first.

Then, download ths plugin and place it in the “plugins” folder in your project’s “js” folder. Then open your Plugin Manager (F10), double-click an empty row, and select the HIME_EnemyEquips plugin.

Once it is in your list of plugins, turn the plugin on.

Usage

Setting up Equip Slots

For details information on how to set up equip slots, please see the usage section for Equip Slots Core.

If you already know how to set up equip slots, basically just note-tag enemies with

<equip slot: ETYPE>

If you want to set up initial equipment, use the note-tag of the following format:

<equip slot: ETYPE ITEM_CODE>

enemyEquips2

Setting up Equip Traits

Just a reminder, but like actors, enemies will need to have the appropriate “equip” features so that they can actually equip weapons and armors.

enemyEquips3

Changing Equips During the Game

You can use script calls to change enemy equips during the game. I will provide an example.

We start by getting the enemy that we want to change equips.

  var enemy = $gameTroop.members()[INDEX];

Where the INDEX is the index of the enemy you want to choose. 0 is the first enemy, 1 is the second enemy, and so on.

Once you have your enemy, you will need a weapon or an armor. Let’s say you wanted to get weapon 3 from the database. You
would use this script call

  var weapon = $dataWeapons[3];

Next, you just need to have the enemy change equips, using the following script call:

  enemy.changeEquip(SLOT_INDEX, EQUIP);

Where the SLOT_ID is which slot you want to set the equip to. 0 is the first slot, 1 is the second slot, and so on.
So the whole script call would look something like this:

  var enemy = $gameTroop.members()[INDEX];
  var weapon = $dataWeapons[3];
  enemy.changeEquip(0, weapon);

If successful, your equip will now be using weapon 3.

Show Weapons During Battle

This plugin provides functionality for equipping enemies. However, this does not mean your battle system will automatically display weapon animations. You will need to have the battle system you’re using updated to support enemy equips.

Help spread the word!Share on FacebookShare on TumblrTweet about this on TwitterShare on Google+Share on LinkedInShare on RedditFlattr the author

You may also like...

7 Responses

  1. Anonymous says:

    what if i want to change enemy’s armor during combat?

    • Hime says:

      You would have to use script calls for that. For example if you wanted to change the first enemy in the troop’s armor in slot 3 to armor 5 in the database, you would write

      var enemy = $gameTroop.members()[0];
      enemy.changeEquip(3, $dataArmors[5]);
      
  2. Anonymous says:

    what if i want to change enemy’s armor?

  3. Anonymous says:

    For the actors, I haven’t tried the enemies yet. But yea I turned the plugins off and the gun animation is working with the default setup. I will try again because your script is definitely what I want to use in my game. I don’t understand what happened to where it stopped working. I didn’t change anything major. My guns in the terms menu is #9 so my character note tag is

    • Hime says:

      Please disable all other plugins except Core Equip Slots and Enemy Equips and determine whether the gun animation works. My gun animation for actors works when Enemy Equips is installed. Or at least, I think it does. The actor just pulls out a gun and there’s a little yellow thing at the tip and that’s it.

  4. Anonymous says:

    I don’t know why but for some reason my gun attacks aren’t working now. Everything else is fine.

Leave a Reply

Your email address will not be published.

To create code blocks or other preformatted text, indent by four spaces:

    This will be displayed in a monospaced font. The first four 
    spaces will be stripped off, but all other whitespace
    will be preserved.
    
    Markdown is turned off in code blocks:
     [This is not a link](http://example.com)

To create not a block, but an inline code span, use backticks:

Here is some inline `code`.

For more help see http://daringfireball.net/projects/markdown/syntax