# Refresh Counters causes havoc with some Layer Traits

**URL:** <https://forum.vassalengine.org/t/refresh-counters-causes-havoc-with-some-layer-traits/90472>\
**Category:** Module Design\
**Created:** [August 30, 2026, 7:01pm UTC](https://forum.vassalengine.org/t/refresh-counters-causes-havoc-with-some-layer-traits/90472 "2026-08-30T19:01:13Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![cholmcc](https://forum.vassalengine.org/user_avatar/forum.vassalengine.org/cholmcc/32/8319_2.png) [@cholmcc](https://forum.vassalengine.org/u/cholmcc)\
**Post date:** [September 7, 2026, 9:10pm UTC](https://forum.vassalengine.org/t/refresh-counters-causes-havoc-with-some-layer-traits/90472/5 "2026-09-07T21:10:46Z")

</div>

> [@wargamerx](#):
>
> Yes, this has been a long-running PITA for some of my modules.

I will take this opportunity to direct your attention to the tool `vsavwrite.py` that I made. You can find a bit more [here](https://forum.vassalengine.org/t/editing-vsav-files-as-text/74765/13). You provide the script with your module (`.vmod`) and a JSON (`.json`) file, the latter contains your set-up of pieces in a somewhat human-readable format, and then it writes a save file `.vsav` for you.

The benefit of that, is that you can generate the save (or setup) from data (the JSON file), and it will automatically have the latest and greatest pieces.

Beware that the script is not omnipotent. If you need additional set-up, you _may_ need to write some Python code - using the [`pywargame`](https://gitlab.com/wargames_tex/pywargame) API - but then you can practically do almost anything you like.

The module [Advanced Squad Leader: Starter Kit #1](https://vassalengine.org/library/projects/advanced_squad_leader_starter_kit_1_cholmcc) - source code at [GitLab](https://gitlab.com/wargames_tex/aslsk1) - is an example of that technique.

Yours,  
_Christian_

---

_[View the full topic](https://forum.vassalengine.org/t/refresh-counters-causes-havoc-with-some-layer-traits/90472)._
