TROOP QUESTION.
Posts
Pages:
1
When I use *2 to show two of the same enemy in a troop, such as Bats, it only says Bat appears. No mention that there are two, although there is Bat A and Bat B to attack. I tried using a comma; Bat, Bat. That didn't work, either. Thank you.
I would like to see:
Bat appears
Bat appears
I would like to see:
Bat appears
Bat appears
It might depend on the specific maker you're working with. However, a quick look-up of Ace's structure finds...
...this function. If you comment out the line that says...
...this, it looks like it will list non-unique enemies. Not 100% sure about MV. With MZ, there's...
...this function. My best guess is that you could set the condition to...
...this for a similar effect?
class Game_Troop < Game_Unit #-------------------------------------------------------------------------- # * Get Enemy Name Array # For display at start of battle. Overlapping names are removed. #-------------------------------------------------------------------------- def enemy_names names = [] members.each do |enemy| next unless enemy.alive? next if names.include?(enemy.original_name) names.push(enemy.original_name) end names end
...this function. If you comment out the line that says...
next if next if names.include?(enemy.original_name)
Game_Troop.prototype.enemyNames = function() { const names = []; for (const enemy of this.members()) { const name = enemy.originalName(); if (enemy.isAlive() && !names.includes(name)) { names.push(name); } } return names; };
...this function. My best guess is that you could set the condition to...
if (enemy.isAlive() { //&& !names.includes(name)) {
Copy the bat and call it bats, even though its 1.
Then when you put 2 together it will say bats.
Ta da.
author=kory_toombs
Copy the bat and call it bats, even though its 1.
Then when you put 2 together it will say bats.
Ta da.
I could see that working best if the graphics relayed that a singular "Bats" enemy was, itself, a group of bats. Though, at that point, there wouldn't be a "Bat" enemy, there would only be a "Bats" enemy.
On the other hand, copy-pasting for each enemy that could come in multiples just so that the emerge text is technically correct might get a little tedious. To say nothing about the target-window having the plural form, and that possibly making no sense.
author=kory_toombs
Copy the bat and call it bats, even though its 1.
Then when you put 2 together it will say bats.
Ta da.
Thank you both.
I could make more than one Enemy out of it.
Have a simple Bat Enemy for when there
is only one bat in the troop and have a Two Bats Enemy
for when there are two in the troop. No?
You could make a "Two Bats" enemy for where there are two bats in a Troop. There's nothing stopping you from doing that. It would probably look something like...
...this?
author=Emerge text
Two Bats appear!
author=Target window
Two Bats A Two Bats B
...this?
Pages:
1















