I\'m not quite sure what this means or whats it doing, Could some one elaborate?
Player player = (Player) sender;
That's a plain old java type cast. See the JLS Casting conversion for the full details.
It assumes that sender is type-compatible with a Player.
sender
Player