diff --git a/static/webui/index.html b/static/webui/index.html
index 2183cdd6..dcb2539c 100644
--- a/static/webui/index.html
+++ b/static/webui/index.html
@@ -193,10 +193,15 @@
-
+
@@ -299,11 +304,14 @@
-
+
@@ -625,6 +633,7 @@
+
@@ -633,6 +642,9 @@
+
+
+
diff --git a/static/webui/script.js b/static/webui/script.js
index ec036756..ebcb3ca2 100644
--- a/static/webui/script.js
+++ b/static/webui/script.js
@@ -185,6 +185,21 @@ function fetchItemList() {
name: loc("code_traumaticPeculiar")
});
+ // Add modular weapons
+ data.OperatorAmps ??= [];
+ data.OperatorAmps.push({
+ uniqueName: "/Lotus/Weapons/Operator/Pistols/DrifterPistol/DrifterPistolPlayerWeapon",
+ name: loc("code_sirocco")
+ });
+ data.OperatorAmps.push({
+ uniqueName: "/Lotus/Weapons/Sentients/OperatorAmplifiers/OperatorAmpWeapon",
+ name: loc("code_amp")
+ });
+ data.Melee.push({
+ uniqueName: "/Lotus/Weapons/Ostron/Melee/LotusModularWeapon",
+ name: loc("code_zaw")
+ });
+
const itemMap = {
// Generics for rivens
"/Lotus/Weapons/Tenno/Archwing/Primary/ArchGun": { name: loc("code_archgun") },
@@ -201,14 +216,9 @@ function fetchItemList() {
"/Lotus/Weapons/SolarisUnited/Secondary/LotusModularSecondary": { name: loc("code_kitgun") },
"/Lotus/Weapons/SolarisUnited/Secondary/LotusModularSecondaryBeam": { name: loc("code_kitgun") },
"/Lotus/Weapons/SolarisUnited/Secondary/LotusModularSecondaryShotgun": { name: loc("code_kitgun") },
- "/Lotus/Weapons/Ostron/Melee/LotusModularWeapon": { name: loc("code_zaw") },
"/Lotus/Weapons/Sentients/OperatorAmplifiers/SentTrainingAmplifier/OperatorTrainingAmpWeapon": {
name: loc("code_moteAmp")
},
- "/Lotus/Weapons/Sentients/OperatorAmplifiers/OperatorAmpWeapon": { name: loc("code_amp") },
- "/Lotus/Weapons/Operator/Pistols/DrifterPistol/DrifterPistolPlayerWeapon": {
- name: loc("code_sirocco")
- },
"/Lotus/Types/Vehicles/Hoverboard/HoverboardSuit": { name: loc("code_kDrive") }
};
for (const [type, items] of Object.entries(data)) {
@@ -241,7 +251,10 @@ function fetchItemList() {
"LWPT_HB_JET",
"LWPT_AMP_OCULUS",
"LWPT_AMP_CORE",
- "LWPT_AMP_BRACE"
+ "LWPT_AMP_BRACE",
+ "LWPT_BLADE",
+ "LWPT_HILT",
+ "LWPT_HILT_WEIGHT"
];
if (supportedModularParts.includes(item.partType)) {
const option = document.createElement("option");
@@ -646,8 +659,7 @@ function doAcquireEquipment(category) {
});
}
-function doAcquireModularEquipment(category) {
- let ItemType;
+function doAcquireModularEquipment(category, ItemType) {
let requiredParts;
let ModularParts = [];
switch (category) {
@@ -656,9 +668,11 @@ function doAcquireModularEquipment(category) {
requiredParts = ["HB_DECK", "HB_ENGINE", "HB_FRONT", "HB_JET"];
break;
case "OperatorAmps":
- ItemType = "/Lotus/Weapons/Sentients/OperatorAmplifiers/OperatorAmpWeapon";
requiredParts = ["AMP_OCULUS", "AMP_CORE", "AMP_BRACE"];
break;
+ case "Melee":
+ requiredParts = ["BLADE", "HILT", "HILT_WEIGHT"];
+ break;
}
requiredParts.forEach(part => {
const partName = getKey(document.getElementById("acquire-type-" + category + "-" + part));
@@ -692,6 +706,11 @@ function doAcquireModularEquipment(category) {
})
});
req.done(() => {
+ const mainInput = document.getElementById("acquire-type-" + category);
+ if (mainInput) {
+ mainInput.value = "";
+ document.getElementById("modular-" + category).style.display = "none";
+ }
requiredParts.forEach(part => {
document.getElementById("acquire-type-" + category + "-" + part).value = "";
});
@@ -1299,3 +1318,34 @@ function toast(text) {
toast.appendChild(div);
new bootstrap.Toast(document.querySelector(".toast-container").appendChild(toast)).show();
}
+
+function handleModularSelection(category) {
+ const modularWeapons = [
+ "/Lotus/Weapons/Sentients/OperatorAmplifiers/OperatorAmpWeapon",
+ "/Lotus/Weapons/Ostron/Melee/LotusModularWeapon"
+ ];
+ const itemType = getKey(document.getElementById("acquire-type-" + category));
+
+ if (modularWeapons.includes(itemType)) {
+ doAcquireModularEquipment(category, itemType);
+ } else {
+ doAcquireEquipment(category);
+ }
+}
+{
+ const modularWeapons = [
+ "/Lotus/Weapons/Sentients/OperatorAmplifiers/OperatorAmpWeapon",
+ "/Lotus/Weapons/Ostron/Melee/LotusModularWeapon"
+ ];
+ const supportedModularInventoryCategory = ["OperatorAmps", "Melee"];
+ supportedModularInventoryCategory.forEach(inventoryCategory => {
+ document.getElementById("acquire-type-" + inventoryCategory).addEventListener("input", function () {
+ const modularFields = document.getElementById("modular-" + inventoryCategory);
+ if (modularWeapons.includes(getKey(this))) {
+ modularFields.style.display = "";
+ } else {
+ modularFields.style.display = "none";
+ }
+ });
+ });
+}