Make your entire program a subroutine in a larger program and change the work zeros; like this
All the stuff you normally put at the top.
G10 L2 G90 P1 Z0. this sets G54 to zero
G10 L2 G90 P2 Z(-thickness of one part) this sets G55 to one part thickness
G10 L2 G90 P3 Z(-thickness of two parts) this sets G56 two parts thickness
G54 M97 P1000
G55 M97 P1000
G56 M97 P1000
G53 G00 X0. Z0.
Here is your program
You set all your tool offsets in G54
Obviously I have omitted a lot of stuff but this gives the basic idea.