The Parliamentary Counsel Office keeps working as it has been.
You can think of it as a part of the government, but it is also a separate office that the Attorney-General is in charge of.
The Attorney-General is a Minister of the Crown, which means they work for the government.
When there is no Attorney-General, the Parliamentary Counsel Office is under the control of the Prime Minister.
The Prime Minister is the leader of the government, so they take charge of the office until a new Attorney-General is appointed.
This is how the office stays connected to the government.
You can find more information about this by looking at the Legislation Act from 2012, which is available on the legislation.govt.nz website.
This office has been around for a while, and it has been mentioned in laws before, like in section 58.
It is still an important part of the government today.