System for saving objects

I’m using button from controlP5 to access this function, and to use stack trace, I would need to know how. This is my full project: https://github.com/Rafhub69/Everythig