Intros: Trainer Sprites
Section 7.J.1
The trainer sprites used by this plugin are long strips which contain each frame of the trainer's entire intro animation. The dimensions for these strips must always be broken up into squares. So for example, if you have a sprite 96 pixels tall that has 10 frames of animation, then the final dimensions for this sprite strip must be 960x96 so that each "frame" of this strip is a perfect square (96x96).
As long as your strips produce perfect squares for each frame, there is no set sizes that are required for your sprites. They can be as large or as small as you'd like, as long as they follow the square rule.
Sprite Scaling
As mentioned above, there are no limitations on how small or how large your sprites may be. The reason for this is because this plugin includes sprite scaling features that allow you to scale up or scale down any trainer sprite to your liking. This means that no matter what size your sprites are, they can be modified to fit within your game without having to manually edit the individual sprite itself.
There are two ways to affect sprite scaling. I'll cover both methods below.
Animation Speed
There are no minimum requirements for how long your sprite strips may be for each trainer. Some trainers may have only 3 or 4 frames of animation, while others may have dozens. This means that some trainers may have really long animations, while others may have really short ones.
However, regardless of the number of frames in a trainer's animation, all trainer sprites will complete their intro animations within the same amount of time. This is to keep all trainer intros consistent with one another, so that they always take up the same amount of time at the start of a battle regardless of how long their sprite strips are.
The exact amount of time trainer intros take is controlled with the plugin Setting TRAINER_ANIMATION_SPEED
. This sets the number of seconds a trainer's intro animation should last before completing. By default, this is set to 1.5, meaning all trainers will complete their entire intro in one and a half seconds at the start of the battle. You can adjust this to your liking if you'd prefer trainers to take longer or shorter to animate at the start of battle.
Note that the number set here should always be a float number, meaning it should always include a decimal place. For example, if you would like to set the trainer intros to last 2 seconds, you would set this value to 2.0
, not just 2
.
Shadow Sprites
In vanilla Essentials, trainers do not cast any shadows on the battlefield, unlike Pokemon sprites. However, this plugin makes it so that trainers will cast shadows when they appear in battle, and these shadows will even animate along with the trainer.
This is implemented by creating a copy of the trainer's sprite and modifying it to appear greyed out, stretched, and transparent. However, it will still animate exactly as the normal sprite does, following the trainer's actions exactly.
The shadow sprite for each trainer type can be tweaked to set the coordinates in which they appear, as well as their visibility. This can easily be accomplished by adding new lines of data for that particular Trainer Type in the various trainer_types.txt
PBS files.
Sprite Hues
This plugin allows you to modify the hue of a trainer's sprites so that you can tweak their coloration. This can give you a way of making a variety of different trainer types that all share the same sprite, but utilize different colors. This can help you cut down on having to make duplicate sprites.
Note that setting a hue for a particular trainer type will affect all sprites for that trainer, including their front sprite, back sprite (if any), and their mugshots (if any). Their overworld sprite, however, will not be affected.
You can easily set a hue for a trainer by adding new lines of data for that particular Trainer Type in the various trainer_types.txt
PBS files. To so so, you can simply add the line SpriteHue
and set it to a number between -255 to 255. By default, all trainers are assumed to have a hue of 0.
Last updated
Was this helpful?