Neither. "is" means that it is the same object instance, which is not always the case for instances representing the same player. "==" is not defined for CyPlayer instances so it falls back to "is" as well. To answer the question: kTriggeredData.ePlayer already is the player ID you are looking for, there is no need to go from there to CyPlayer first and then back to the player ID. But more generally, you can always get the player ID with CyPlayer.getID.