Resource icon

Trade Lens 0.2.2

BlobRoss

Chieftain
Joined
Feb 11, 2025
Messages
28
The lack of lenses available makes it difficult to easily see a lot of information across the map. I am looking to add more, starting with the Trade Lens.

Current Lenses Implemented:
  • Trade Lens
    • Allows you to view the trade route screen without having a Merchant
    • Adds an "X" to the trade route screen so you can exit it without having to click on another unit/city

Trade Lens.png


Trade Lens Full.png


Download:
 
i just bought a bunch of merchants in the Modern age, and i'm trying to send them all on assignment. i'm finding that the Trade Route panel closes when i hit Confirm on one merchant, but it doesn't reopen when i select the next merchant. to send the next merchant, i need to turn off the Trade lens and then turn it back on again. would be better if selecting a merchant always reopened the panel.
 
i just bought a bunch of merchants in the Modern age, and i'm trying to send them all on assignment. i'm finding that the Trade Route panel closes when i hit Confirm on one merchant, but it doesn't reopen when i select the next merchant. to send the next merchant, i need to turn off the Trade lens and then turn it back on again. would be better if selecting a merchant always reopened the panel.
Interesting, thanks for the bug report. I'll try to take a look at fixing this tomorrow.
 
BlobRoss updated More Lenses - Trade Lens with a new update entry:

Minor bugfix in modern era

Fixes a bug in the modern age where sending a merchant using the "Confirm" button in the trade panel wouldn't properly close the lens. This meant you would have to switch the lens off manually otherwise selecting another merchant would not bring up the trade route panel.

I looked into adding the "Confirm" button to the antiquity and exploration ages but there seems to be some core game function that prevents being able to auto-send merchants outside of the modern age.

Read the rest of this update entry...
 
Did this break with 1.1.0? I'm not seeing the lens in a fresh save with no other lens mods
 
Did this break with 1.1.0? I'm not seeing the lens in a fresh save with no other lens mods
yes, it broke all lens mods. the name of the underlying game element changed from 'panel-mini-map' to 'lens-panel' and so all lens mods need to change that in their Controls.decorate calls. as a workaround, you can find that line inside the mod and update it yourself.
 
it still conflict with discover-Lens and search lens , there is only 'discover' if use them together
Trade Lens works fine. Your issue is caused by Moxl Map Search. That one is not updated (yet) and will disable all updated lens mods if used, including Trade Lens. Remove Moxl's for now and this lens mod and your other lenses will work again.
 
Could you please make this compatible with Resource Screen Improvements? Both mods overwrite trade-route-chooser.js, but I think that you only add a close button in that one. The other mod also adds a close button, so I assume you wouldn't need your trade-route-chooser.js when Resource Screen Improvements is loaded. I think you can accomplish this by expanding the ActionCriteria and ActionGroups in your modinfo to the following. I've tested this and it seems to work.

XML:
    <ActionCriteria>
        <Criteria id="always">
            <AlwaysMet></AlwaysMet>
        </Criteria>
        <Criteria id="rsi-mod-not-active">
            <ModInUse inverse="1">resource-fixes-deadbeef</ModInUse>
        </Criteria>
    </ActionCriteria>
    <ActionGroups>
        <ActionGroup id="game-more-lens-no-rsi" scope="game" criteria="rsi-mod-not-active">
            <Actions>
                <ImportFiles>
                    <Item>ui/trade-route-chooser/trade-route-chooser.js</Item>
                </ImportFiles>
            </Actions>
        </ActionGroup>
        <ActionGroup id="game-more-lens-always" scope="game" criteria="always">
            <Actions>
                <UIScripts>
                    <Item>ui/utilities/trade-lens-panel-mini-map.js</Item>
                </UIScripts>
            </Actions>
        </ActionGroup>
    </ActionGroups>
 
Hello, I've created multilingual support for this mod including Simplified Chinese, Hong Kong Traditional Chinese, Korean, Japanese, Russian, Brazilian Portuguese, Italian, Spanish, Polish, and French. If possible, please consider integrating these translations into your mod in future updates to benefit more players. (I'm currently using DeepSeek Translate for communication - please excuse any unusual grammar you might notice.)
 

Attachments

Thanks for making this mod. It was very useful. So useful that Firaxis decided to fully integrate it into game update 1.1.1. No longer needed now, but it was good :cool:
 
Back
Top Bottom