Happy party here hehe
The first thing that you have to choose is on what level of uniqueness you want the tables to be.
For each unit type? For each specific unit? etc.
If it should be for each unit type, then you pretty much already have your stuff done following the above replies.
However, it could be helpfull to give you a small explaination of what you really want to store in that hashtable.
What you describe as a table is simple one, 1, fourhundred minus threehundred-nintynine object.
An object can be anything that you want it to be and in this case it is a table of items.
In JASS/vJASS (meaning GUI as well), objects are referenced simply by an integer.
The integer is used to access the fields (data) of that object from arrays or a hashtable where the actual data is stored.
In those arrays, you will have stored a few items with their corresponding drop rates and amounts and whatever you want to have as features.
What you want to store per unit type is simply that integer that is used as index.
Unfortunately, in JNGP (which you should have though), you cant use keys in GUI to access hashtable data.
So you should use a small custom script to get the unit type id of a unit to use it as an integer as key of the hashtable.
"Custom Script: set udg_TempInteger = GetUnitTypeId(udg_TempUnit)"
This custom script will store the unit type id of
TempUnit (a global variable) in
TempInteger (another global variable)
Then you can use TempInteger in the hashtable as key.