I was going to reply with the snarky answer that the sensor you need is an attentive parent, but where is the fun in that? This sounds like a fun project. :-)
Let me start by saying that the features you seek are not available yet as of R066 of the Almond+ firmware. Once the Securifi folks have built out the home automation features this type of thing should be possible but we're not quite there yet. The missing link you'll need is a way to say that data from input sensor A should turn off binary switch B.
Let's assume we've got that, for the sake of argument. A switch for turning off the TV is the easy part. Anything that can take an on/off message and cut the power on command should do. The tricky part will be a sensor that detects the presence of a person within a set distance from the TV. The only Zigbee or Z-wave sensors I've seen do motion sensing rather than distance sensing, however. A motion sensor has a range associated with it, but this is more of an outer limit of sensitivity rather than a feature that could be used to measure distance. A motion sensor is generally used for security and can tell you if a room or an area of your yard is occupied by a moving object with a temperature in the vicinity of a warm-blooded animal. What you are really after is a distance sensor that can tell you how far away the nearest object is. These sensors exist and will often use sonar to get an accurate distance. The catch is that they're not typically available in a package that also includes a Zigbee or Z-wave chip. (Though I would love to be wrong about this! Let me know if anyone knows otherwise.)
Don't let that deter you, however. It might be possible to use a standard motion sensor in a non-standard way to achieve the effect you want. What you would need is a somewhat "near-sighted" motion sensor and some creative installation that will block the sensor's "view" until a warm-blooded object gets too close to the TV. Careful arrangement should achieve what you are looking for. A future firmware update should get us the ability to link sensors with actions in some way. I look forward to building some simple "behaviors" like this into certain rooms in my house as well.