Skip to content
Snippets Groups Projects
Commit 9928f8d8 authored by svornost's avatar svornost
Browse files

Don't force a page refresh just to update the sidebar, it's automatic now.

parent 70638222
No related branches found
No related tags found
No related merge requests found
......@@ -255,7 +255,7 @@ App.Neighbor.Interact = (function() {
* @param {string} itemName - the item name to check to see if the player already has this item
* @param {string} category - the category to check to see if the player already has this item
* @param {string} itemDisplay - a display name for a group of the item; as in, "a shipment of XXX" or "enough XXX"
* @param {function} property - adjusts the global property controlling whether this item has been acquired
* @param {function(): void} property - adjusts the global property controlling whether this item has been acquired
* @param {number} [itemPrice] - the price the player should pay for the item; by default, basePrice (computed above)
*/
function addAcquisitionBlock(fsRequired, itemName, category, itemDisplay, property, itemPrice = basePrice) {
......@@ -277,8 +277,8 @@ App.Neighbor.Interact = (function() {
const link = App.UI.DOM.link(`Divert an outgoing shipment of ${itemDisplay}`, (f) => {
property();
cashX(forceNeg(itemPrice), "capEx");
// replaceDetails(arcID); - cash changed, force passage transition for sidebar update
}, [], "Neighbor Interact");
replaceDetails(arcID);
});
const div = App.UI.DOM.appendNewElement("div", container, link);
App.UI.DOM.appendNewElement("span", div, `Will cost ${cashFormat(itemPrice)}`, "detail");
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment