mr:doctor_class
Table of Contents
Doctor Class - Code References
Java Classes
- HeroClass.java - DOCTOR enum definition (line with DOCTOR(R.string.HeroClass_Doctor, DoctorArmor.class))
- HeroClass.attackSkillBonus() - Bone Saw accuracy penalty (-5 attack skill when not wielding Bone Saw, 5% chance to warn per attack)
- Hero.java - Hero base class with class-specific initialization
- DoctorArmor.java - Class-specific armor
JSON Configuration
Starting configuration in initHeroes.json:
"DOCTOR": {
"weapon": {
"kind": "BoneSaw",
"identified": true
},
"ring1": {
"kind": "PlagueDoctorMask"
},
"armor": {
"kind": "NoItem"
},
"knownItems": [
{ "kind": "PotionOfHealing" },
{ "kind": "PotionOfToxicGas" },
{ "kind": "PotionOfParalyticGas" }
]
}
- initHeroes.json - Starting equipment and known items
String Resources
English string resources:
<string name="HeroClass_Doctor">Plague Doctor</string> <string name="Accuracy_DecreasedDoctor">Accuracy decreased with %s</string> <string name="Accuracy_DecreasedDoctorBareHands">Accuracy decreased while barehanded</string>
- And other localization files
Lua Scripts
This entity is implemented in Java. No Lua script exists for the Doctor hero class.
Key Code Fragments
Java Implementation (HeroClass.java - DOCTOR enum):
DOCTOR(R.string.HeroClass_Doctor, DoctorArmor.class);
Attack Skill Bonus (Bone Saw Requirement):
@Override public int attackSkillBonus(Char chr) { switch (this) { case DOCTOR: if(!chr.getActiveWeapon().getEntityKind().equals(BONE_SAW) && !chr.getSecondaryWeapon().getEntityKind().equals(BONE_SAW)) { if(Math.random()<0.05) { Item badWeapon = chr.getActiveWeapon(); if (!badWeapon.valid()) { badWeapon = chr.getSecondaryWeapon(); } if(badWeapon.valid()) { chr.yell(Utils.format(R.string.Accuracy_DecreasedDoctor, badWeapon.name())); } else { chr.yell(R.string.Accuracy_DecreasedDoctorBareHands); } } return -5; } } return 0; }
Related mr: Entities
- Bone Saw (Item) - Starting weapon
- Plague Doctor Mask (Item) - Starting accessory
- Plague Doctor (NPC) - Related quest NPC
- Potion of Healing (Item) - Known item
- Potion of Toxic Gas (Item) - Known item
- Potion of Paralytic Gas (Item) - Known item
- Hero Class (Base) - Base class reference
Related Wiki Pages
- Doctor Class - Human-readable page
- Hero Classes - Overview of all classes
- Plague Doctor NPC - Related quest
- Potions - Core mechanic for Doctor
mr/doctor_class.txt · Last modified: by 127.0.0.1

