|
|
@ -112,48 +112,48 @@ public class LootManager { |
|
|
|
} |
|
|
|
} |
|
|
|
return outItem; |
|
|
|
return outItem; |
|
|
|
} |
|
|
|
} |
|
|
|
public static void AddGenTableRow(int tableID, GenTable genTable, GenTableRow row){ |
|
|
|
public static void AddGenTableRow(int tableID,GenTableRow row){ |
|
|
|
if(!generalItemTables.containsKey(tableID)){ |
|
|
|
if(!generalItemTables.containsKey(tableID)){ |
|
|
|
//create the new table
|
|
|
|
//create the new table
|
|
|
|
generalItemTables.put(tableID,genTable); |
|
|
|
GenTable gt = new GenTable(); |
|
|
|
//add row to new table
|
|
|
|
gt.rows.add(row); |
|
|
|
generalItemTables.get(tableID).rows.add(row); |
|
|
|
generalItemTables.put(tableID,gt); |
|
|
|
} else{ |
|
|
|
} else{ |
|
|
|
//add row to existing table
|
|
|
|
//add row to existing table
|
|
|
|
GenTable toAdd = generalItemTables.get(tableID); |
|
|
|
GenTable toAdd = generalItemTables.get(tableID); |
|
|
|
toAdd.rows.add(row); |
|
|
|
toAdd.rows.add(row); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
public static void AddItemTableRow(int tableID,ItemTable itemTable, ItemTableRow row){ |
|
|
|
public static void AddItemTableRow(int tableID, ItemTableRow row){ |
|
|
|
if(!itemTables.containsKey(tableID)){ |
|
|
|
if(!itemTables.containsKey(tableID)){ |
|
|
|
//create the new table
|
|
|
|
//create the new table
|
|
|
|
itemTables.put(tableID,itemTable); |
|
|
|
ItemTable it = new ItemTable(); |
|
|
|
//add new row to table
|
|
|
|
it.rows.add(row); |
|
|
|
itemTables.get(tableID).rows.add(row); |
|
|
|
itemTables.put(tableID,it); |
|
|
|
} else{ |
|
|
|
} else{ |
|
|
|
//add row to existing table
|
|
|
|
//add row to existing table
|
|
|
|
ItemTable toAdd = itemTables.get(tableID); |
|
|
|
ItemTable toAdd = itemTables.get(tableID); |
|
|
|
toAdd.rows.add(row); |
|
|
|
toAdd.rows.add(row); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
public static void AddModTypeTableRow(int tableID,ModTypeTable modtypeTable, ModTypeTableRow row){ |
|
|
|
public static void AddModTypeTableRow(int tableID, ModTypeTableRow row){ |
|
|
|
if(!modTypeTables.containsKey(tableID)){ |
|
|
|
if(!modTypeTables.containsKey(tableID)){ |
|
|
|
//create the new table
|
|
|
|
//create the new table
|
|
|
|
modTypeTables.put(tableID,modtypeTable); |
|
|
|
ModTypeTable mtt = new ModTypeTable(); |
|
|
|
//add row to new table
|
|
|
|
mtt.rows.add(row); |
|
|
|
modTypeTables.get(tableID).rows.add(row); |
|
|
|
modTypeTables.put(tableID,mtt); |
|
|
|
} else{ |
|
|
|
} else{ |
|
|
|
//add row to existing table
|
|
|
|
//add row to existing table
|
|
|
|
ModTypeTable toAdd = modTypeTables.get(tableID); |
|
|
|
ModTypeTable toAdd = modTypeTables.get(tableID); |
|
|
|
toAdd.rows.add(row); |
|
|
|
toAdd.rows.add(row); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
public static void AddModTableRow(int tableID, ModTable modTable, ModTableRow row){ |
|
|
|
public static void AddModTableRow(int tableID,ModTableRow row){ |
|
|
|
if(!itemTables.containsKey(tableID)){ |
|
|
|
if(!itemTables.containsKey(tableID)){ |
|
|
|
//create the new table
|
|
|
|
//create the new table
|
|
|
|
modTables.put(tableID,modTable); |
|
|
|
ModTable mt = new ModTable(); |
|
|
|
//add row to new table
|
|
|
|
mt.rows.add(row); |
|
|
|
modTables.get(tableID).rows.add(row); |
|
|
|
modTables.put(tableID,mt); |
|
|
|
} else{ |
|
|
|
} else{ |
|
|
|
//add row to existing table
|
|
|
|
//add row to existing table
|
|
|
|
ModTable toAdd = modTables.get(tableID); |
|
|
|
ModTable toAdd = modTables.get(tableID); |
|
|
|