scmJS docs

UPGR

How far each player may research each upgrade, and the level they start at, for the 46 upgrades of the original game. Laid out as PUNI is: each player's own values, the defaults, and whether each player uses the defaults. A Brood War file has PUPx in its place; in an older file the game reads this table and then PUPx on top, if the file has one. Only Use Map Settings reads either.

Name UPGR (55 50 47 52)
Size 1748 bytes.
Read by The game, at the start of a Use Map Settings game, in a VER 59 or 63 file, or Remastered's 64. A Brood War file's copy is never read.
Required For Use Map Settings in a StarCraft 1.00 or hybrid file (VER 59 or 63), and in Remastered's VER 64.
The game accepts Exactly 1748 bytes. Any other length refuses the map.
More than one copy The last copy replaces the others. Every copy must still be the right size, or the map is refused.
In scmJS Read, and written again when you change what it holds.

Layout:

Offset Type Holds
0 u8 × 552 Per player, per upgrade: the highest level they may research. Player 1's 46 bytes first
552 u8 × 552 Per player, per upgrade: the level they start at
1104 u8 × 46 Per upgrade: the default highest level
1150 u8 × 46 Per upgrade: the default starting level
1196 u8 × 552 Per player, per upgrade: 0 to use this player's own values above; anything else for the defaults