If enough -1/-1 counters are put on Hangarback Walker at the same time to make its toughness 0 or less, the number of +1/+1 counters on it before it got any -1/-1 counters will be used to determine how many Thopter tokens you get. For example, if there are three +1/+1 counters on Hangarback Walker and it gets four -1/-1 counters, you'll get three Thopter tokens. That's because Hangarback Walker's triggered ability checks the creature's existence just before it leaves the battlefield, and it still has all those counters on it at that point.

Artwork
Loading artwork…
Hangarback Walker
Secrets of Strixhaven Commander · #348 · EN
Nonfoil—Foil—
Card rules
This creature enters with X +1/+1 counters on it.
When this creature dies, create a 1/1 colorless Thopter artifact creature token with flying for each +1/+1 counter on this creature.
1,
: Put a +1/+1 counter on this creature.
0/0
Rare · Illustrated by Daarken
Format legality
Brawl Legal
Commander Legal
Competitive Brawl Legal
Duel Legal
Gladiator Legal
Historic Legal
Legacy Legal
Modern Legal
Oathbreaker Legal
Pioneer Legal
Timeless Legal
Tlr Legal
Vintage Legal
Alchemy Not Legal
Future Not Legal
Old School Not Legal
Pauper Not Legal
Pauper Commander Not Legal
Penny Not Legal
PreDH Not Legal
Premodern Not Legal
Standard Not Legal
Standard Brawl Not Legal
Rulings
Published rulings from the downloaded Scryfall catalog. Source card record · Rules and interactions
The value of each X in Hangarback Walker's mana cost must be equal. For example, if X is 2, you'll pay 4 to cast Hangarback Walker and it will enter the battlefield with two +1/+1 counters on it.