Does the script only execute once, after being attached to the script?
Yes, only once. Moreover, some of the functions, that are constantly called in play mode, are not available for edit mode.
Look more here.
P.S. However, I am not sure, but, as far as I remember, function will be recalled when you save any changes in the script.
Update works, it’s just infrequent, it’ll fire when moving around, dragging, etc.
Oh, yeah I was wrong, Update works, but only when something in the scene changed.
That is good to know. I am making a map generating script and I needed more than what the documentation gave me.
And we needed more information than you gave us. Why the function that occurs only once does not fit your purposes?