mirror of
https://github.com/SWG-Source/dsrc.git
synced 2026-01-15 23:04:31 -05:00
allows NPC vendors to exceed 70 to 75 item limit
This commit is contained in:
@@ -34,17 +34,21 @@ public class static_item extends script.base_script
|
||||
public static final String SET_BONUS_TABLE = "datatables/item/item_sets.iff";
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container) throws InterruptedException
|
||||
{
|
||||
return createNewItemFunction(itemName, container, null, 0);
|
||||
return createNewItemFunction(itemName, container, null, 0, false);
|
||||
}
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container, int charges) throws InterruptedException
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container, boolean overloaded) throws InterruptedException
|
||||
{
|
||||
return createNewItemFunction(itemName, container, null, charges);
|
||||
return createNewItemFunction(itemName, container, null, 0, overloaded);
|
||||
}
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container, location pos) throws InterruptedException
|
||||
{
|
||||
return createNewItemFunction(itemName, container, pos, 0);
|
||||
return createNewItemFunction(itemName, container, pos, 0, false);
|
||||
}
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container, location pos, int charges) throws InterruptedException
|
||||
{
|
||||
return createNewItemFunction(itemName, container, pos, charges, false);
|
||||
}
|
||||
public static obj_id createNewItemFunction(String itemName, obj_id container, location pos, int charges, boolean overloaded) throws InterruptedException
|
||||
{
|
||||
if (itemName == null || itemName.equals(""))
|
||||
{
|
||||
@@ -98,10 +102,18 @@ public class static_item extends script.base_script
|
||||
newItem = createObjectOverloaded(itemData.getString("template_name"), container);
|
||||
}
|
||||
else
|
||||
{
|
||||
if(overloaded)
|
||||
{
|
||||
newItem = createObjectOverloaded(itemData.getString("template_name"), container);
|
||||
}
|
||||
else
|
||||
{
|
||||
newItem = createObject(itemData.getString("template_name"), container, "");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!isIdValid(newItem))
|
||||
{
|
||||
LOG("loot", itemName + " could not be made because item is not valid");
|
||||
|
||||
@@ -88,7 +88,7 @@ public class vendor extends script.base_script
|
||||
obj_id objectForSale = obj_id.NULL_ID;
|
||||
if (static_item.isStaticItem(item))
|
||||
{
|
||||
objectForSale = static_item.createNewItemFunction(item, containerList[idx]);
|
||||
objectForSale = static_item.createNewItemFunction(item, containerList[idx], true);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user