v0.2.3: refactored logic to distinguish between a Hero's class name, and given name.
Note that given name is only going to be set by donation features, which are not in the open source, but the refactor is generally beneficial so I'm putting it in anyway.
This commit is contained in:
@@ -241,6 +241,10 @@ public class Hero extends Char {
|
||||
public String className() {
|
||||
return subClass == null || subClass == HeroSubClass.NONE ? heroClass.title() : subClass.title();
|
||||
}
|
||||
|
||||
public String givenName(){
|
||||
return name.equals("you") ? className() : name;
|
||||
}
|
||||
|
||||
public void live() {
|
||||
Buff.affect( this, Regeneration.class );
|
||||
|
||||
Reference in New Issue
Block a user