| 29 | |
| 30 | ==== solution(1) |
| 31 | Simply adding `|| false` to |
| 32 | [https://code.wildfiregames.com/source/0ad/browse/ps/trunk/binaries/data/mods/public/gui/session/trade/TradeDialogBarterPanel.js$27 Line 27] in `TradeDialogBarterPanel.js` |
| 33 | |
| 34 | {{{ |
| 35 | #!js lineno=20 |
| 36 | update() |
| 37 | { |
| 38 | let playerState = GetSimState().players[g_ViewedPlayer]; |
| 39 | let canBarter = playerState && playerState.canBarter; |
| 40 | |
| 41 | this.barterButtonManager.setViewedPlayer(g_ViewedPlayer); |
| 42 | this.barterButtonManager.update(); |
| 43 | this.barterNoMarketsMessage.hidden = canBarter *|| false*; |
| 44 | this.barterResources.hidden = !canBarter; |
| 45 | this.barterHelp.hidden = !canBarter; |
| 46 | this.barterHelp.tooltip = sprintf( |
| 47 | translate(this.InstructionsTooltip), { |
| 48 | "quantity": this.barterButtonManager.getSelectedButton().BarterResourceSellQuantity, |
| 49 | "hotkey": colorizeHotkey("%(hotkey)s", "session.massbarter"), |
| 50 | "multiplier": this.barterButtonManager.getSelectedButton().Multiplier |
| 51 | }); |
| 52 | } |
| 53 | }; |