you can use a custom ini. just name the file the same as your esp, and the game will activate it as long as the esp is activated. when you package your mod include the ini in the same directory as the esp.
not sure about the second half of your question though