fixed counter script