Refactored Actor.java