I reset the panel using the Settings Editor. I tried again with just the commandline:
xfconf-query -r -R -c xfce4-panel -p /panels xfconf-query -r -R -c xfce4-panel -p /plugins
Afterwards, the only setting left in xfce4-panel was configver. I added another plugin to the panel, and it was zero-indexed again.
I reset the panel using the Settings Editor. I tried again with just the commandline:
xfconf-query -r -R -c xfce4-panel -p /panels
xfconf-query -r -R -c xfce4-panel -p /plugins
Afterwards, the only setting left in xfce4-panel was configver. I added another plugin to the panel, and it was zero-indexed again.