Lets say you have a project, like: https://scratch.mit.edu/projects/996734829/ (by me) and only signed in scratchers can use it, because if you don't have an account, the scratcher won't be notified. Here is the script:
when green flag clicked
if <[(username)] = []> then
next costume
end

Most likely you will not use the
 next costume 
Use the switch costume block.
The script will look like this:
when green flag clicked
if <[(username)] = []> then
switch costume to [ v]

end
Thanks for reading hope this was helpful!