Motion activated light only if light is already off?

Check out BETA call for superState scene app (all better now!)

Yes, you can add custom attributes and methods to existing device types. Use the sendEvent() command to change the state of a switch device or a custom attribute of a switch device. Check out SendEvent and currentValue - #28 by tgauchat

Sort of. I know that you can see some information within the IDE. Again, if you want to have a SmartApp send any custom data to a device – and then have that device store that custom data, you need to edit the device type of the device and add custom attributes and either add new custom methods or modify existing methods so that the device can store this custom data.

Yes. include:

       defaultValue: ______ 

in the input section that you want a defaultValue. For example,

input “defLevel”, title: “Select the level you want the lights to be.”, multiple: false, required: false, defaultValue: 99

-t