I don't know of a tutorial that shows how to do NBT for a player, but I have used it before.
NBT is basically data that is saved. Because trying to use variables on a block will affect every instance of it, you can do the check on player's NBT. NBT saves the player's inventory, things with tile entities, etc.
In the case of doing a Player's NBT, using ExtendedEntityData did not work for me.
Here is some example code:
NBTTagCompound entityData = p.getEntityData();
NBTTagCompound persist;
if (!entityData.hasKey(EntityPlayer.PERSISTED_NBT_TAG)) {
entityData.setTag(EntityPlayer.PERSISTED_NBT_TAG, (persist = new NBTTagCompound()));
} else {
persist = entityData.getCompoundTag(EntityPlayer.PERSISTED_NBT_TAG);
}
Where p is an entityplayer. This gets the Player's persisted NBT data, so if he dies the player keeps your boolean. It also keeps the data if the player logs off.
With this code, persist becomes a place where you can save and read data. For example you can call setBoolean(key, value); on persist.
That will save a boolean value to the player, with the name of key and the boolean value of value.
So if key was "TEST" and value was true, then if you later called getBoolean(key);, where key was still "TEST" you would get true because you assigned "TEST" to true. You can use that to store various other data for the player, from int to byte to char, string, and boolean.
So you can make a method with the code I put above that returns persist, then call yourMethod(EntityPlayer p).setBoolean("EnderCooldown", true); when the player uses it, then before you teleport the player you can check if "EnderCooldown" in the NBT is true, if it is then set it to false and don't teleport. If it is false then teleport them.
Hope I helped.
I hope I helped.