get triggered sensor?

Is there any way (in python) to get the sensor that triggered the connected python script?

Say i have a box with each side a different object. They all have a collision sensor that triggers a python script on the “master empty” that all the sides are parented. Depending on what side gets hit I want the python script to do different things. Is there any way to do this?



c = GameLogic.getCurrentController()
sensors = c.getSensors()

for s in sensors:
   if s.isPositive():
      # do your thing

… or something, you may be able to test as well tho I don’t know