Entity Kind: `ScoutArmor`
Entity Type: Item (Armor)
Description: Scout Armor is a subclass-specific armor item for the Scout subclass (Elf class mastery path). It extends ElfArmor and can only be equipped by heroes with the Scout subclass.
Key Implementation Details:
public class ScoutArmor extends ElfArmor { public ScoutArmor() { name = StringsManager.getVar(R.string.ElfArmor_Name); image = 18; hasHelmet = false; } @Override public boolean doEquip(@NotNull Char hero) { if (hero.getSubClass() == HeroSubClass.SCOUT) { return super.doEquip(hero); } else { GLog.w(StringsManager.getVar(R.string.ElfArmor_NotElf)); return false; } } }
This armor is not defined in JSON configuration. It is a hardcoded Java item class that is automatically registered through the ItemFactory system.
Registration in ItemFactory:
// From ItemFactory.java import com.watabou.pixeldungeon.items.armor.ScoutArmor; registerItemClass(ScoutArmor.class);
ScoutArmor uses the parent class (ElfArmor) string resources:
English (`values/strings_all.xml`):
<string name="ElfArmor_Name">Scout Armor</string> <string name="ElfArmor_Desc">...</string> <string name="ElfArmor_NotElf">Only Scouts can wear this armor!</string>
Russian (`values-ru/strings_all.xml`):
<string name="ElfArmor_Name">Броня Разведчика</string> <string name="ElfArmor_Desc">...</string> <string name="ElfArmor_NotElf">Только Разведчики могут носить эту броню!</string>
This entity is implemented entirely in Java, no Lua script exists.