Is there any way to do stuff like this as a plugin?