diff --git a/src/controllers/custom/getItemListsController.ts b/src/controllers/custom/getItemListsController.ts
index 92eedda0..ec768b83 100644
--- a/src/controllers/custom/getItemListsController.ts
+++ b/src/controllers/custom/getItemListsController.ts
@@ -18,7 +18,7 @@ function reduceItems(items: MinItem[]): ListedItem[] {
const getItemListsController: RequestHandler = (_req, res) => {
res.json({
warframes: reduceItems(warframes),
- weapons: reduceItems(weapons)
+ weapons: reduceItems(weapons.filter(item => item.productCategory != "OperatorAmps"))
});
};
diff --git a/src/services/inventoryService.ts b/src/services/inventoryService.ts
index 43675663..d199ccb4 100644
--- a/src/services/inventoryService.ts
+++ b/src/services/inventoryService.ts
@@ -178,7 +178,7 @@ export const addWeapon = async (
weaponIndex = inventory.Melee.push({ ItemType: weaponName, Configs: [], XP: 0 });
break;
default:
- throw new Error("unknown weapon type");
+ throw new Error("unknown weapon type: " + weaponType);
}
const changedInventory = await inventory.save();
diff --git a/static/webui/index.html b/static/webui/index.html
index ea91f01b..780792ec 100644
--- a/static/webui/index.html
+++ b/static/webui/index.html
@@ -26,6 +26,10 @@
Hello, ! Logout
+
+ Note: Changes made here will only be reflected in-game when the game re-downloads your inventory.
+ Visiting the navigation should be the easiest way to trigger that.
+
diff --git a/static/webui/script.js b/static/webui/script.js
index 0a3de30c..c7a0cdc0 100644
--- a/static/webui/script.js
+++ b/static/webui/script.js
@@ -69,7 +69,7 @@ function updateInventory() {
const tr = document.createElement("tr");
{
const td = document.createElement("td");
- td.textContent = itemMap[item.ItemType].name;
+ td.textContent = itemMap[item.ItemType]?.name ?? item.ItemType;
tr.appendChild(td);
}
{
@@ -78,17 +78,22 @@ function updateInventory() {
if (item.XP < 1_600_000) {
const a = document.createElement("a");
a.href = "#";
- a.onclick = function () {
+ a.onclick = function (event) {
+ event.preventDefault();
addGearExp("Suits", item.ItemId.$oid, 1_600_000 - item.XP);
};
a.textContent = "Make Rank 30";
td.appendChild(a);
- td.innerHTML += " · ";
+
+ const span = document.createElement("span");
+ span.innerHTML = " · ";
+ td.appendChild(span);
}
{
const a = document.createElement("a");
a.href = "#";
- a.onclick = function () {
+ a.onclick = function (event) {
+ event.preventDefault();
disposeOfGear("Suits", item.ItemId.$oid);
};
a.textContent = "Remove";
@@ -105,7 +110,7 @@ function updateInventory() {
const tr = document.createElement("tr");
{
const td = document.createElement("td");
- td.textContent = itemMap[item.ItemType].name;
+ td.textContent = itemMap[item.ItemType]?.name ?? item.ItemType;
tr.appendChild(td);
}
{
@@ -114,17 +119,22 @@ function updateInventory() {
if (item.XP < 800_000) {
const a = document.createElement("a");
a.href = "#";
- a.onclick = function () {
+ a.onclick = function (event) {
+ event.preventDefault();
addGearExp(category, item.ItemId.$oid, 800_000 - item.XP);
};
a.textContent = "Make Rank 30";
td.appendChild(a);
- td.innerHTML += " · ";
+
+ const span = document.createElement("span");
+ span.innerHTML = " · ";
+ td.appendChild(span);
}
{
const a = document.createElement("a");
a.href = "#";
- a.onclick = function () {
+ a.onclick = function (event) {
+ event.preventDefault();
disposeOfGear(category, item.ItemId.$oid);
};
a.textContent = "Remove";