Forum Discussion

stupbbqx2a3f's avatar
stupbbqx2a3f
Rising Novice
2 months ago
Solved

Scrolling around the map

Hi all.

I am running the game on my android tablet, using Firefox and scripts via Tamper Monkey, the game is running fine except I cannot scroll around the map or zoom in and out. So I can only see what's immediately around me! Is there a script or shortcut I am missing to do this, I can only make small jumps, if lots of other bases around me it means I cant move anywhere unless free space that's very close?



Thank you 😊 

  • (function () {
        const androidHelper = () => {
            if (!window.ClientLib || !window.qx || !qx.core.Init.getApplication().initDone) {
                return setTimeout(androidHelper, 100)
            }
            const region = ClientLib.Vis.VisMain.GetInstance().get_Region();
            const ZoomSpinner = new qx.ui.form.Spinner().set({
                value: parseFloat(region.get_ZoomFactor().toFixed(2)),
                minimum: region.get_MinZoomFactor(),
                maximum: region.get_MaxZoomFactor(),
                singleStep: .1,
                toolTipText: 'Adjust zoom factor',
                opacity: 0.7
            });
            ZoomSpinner.addListener("changeValue", e => region.set_ZoomFactor(e.getData()));
            qx.core.Init.getApplication().getBackgroundArea().add(ZoomSpinner, {
                right: 125,
                bottom: 5
            })
        }
        androidHelper()
    })();

    this one's for zoom in/out...
    updates/alternatives will be posted on github.com/ffi82/CnC-TA

    for Right/Left/Up/Down, maybe use the on screen keyboard arrows (i don't know how you can bring it up whenever u need/want it...) ?
    (i don't have a test device yet...)

10 Replies

  • stupbbqx2a3f Playing on a tablet isn't a supported platform.

    I've not tried it, but on a PC if you zoom out you can see more of the map.  Is there a way to zoom out in the game as you play it?  

  • I don't know tablets but the best you can do on android is switch to desktop view.  You can then navigate around by object coordinates and centering the object on your screen.

     

     

  • stupbbqx2a3f's avatar
    stupbbqx2a3f
    Rising Novice
    2 months ago

    Zooming with pinch and stretch doesn't work, neither does scrolling with fingers

  • stupbbqx2a3f's avatar
    stupbbqx2a3f
    Rising Novice
    2 months ago

    I have tried desktop view and normal view, neither scrolling or zooming works in both

  • ffi82's avatar
    ffi82
    Rising Traveler
    2 months ago
    (function () {
        const androidHelper = () => {
            if (!window.ClientLib || !window.qx || !qx.core.Init.getApplication().initDone) {
                return setTimeout(androidHelper, 100)
            }
            const region = ClientLib.Vis.VisMain.GetInstance().get_Region();
            const ZoomSpinner = new qx.ui.form.Spinner().set({
                value: parseFloat(region.get_ZoomFactor().toFixed(2)),
                minimum: region.get_MinZoomFactor(),
                maximum: region.get_MaxZoomFactor(),
                singleStep: .1,
                toolTipText: 'Adjust zoom factor',
                opacity: 0.7
            });
            ZoomSpinner.addListener("changeValue", e => region.set_ZoomFactor(e.getData()));
            qx.core.Init.getApplication().getBackgroundArea().add(ZoomSpinner, {
                right: 125,
                bottom: 5
            })
        }
        androidHelper()
    })();

    this one's for zoom in/out...
    updates/alternatives will be posted on github.com/ffi82/CnC-TA

    for Right/Left/Up/Down, maybe use the on screen keyboard arrows (i don't know how you can bring it up whenever u need/want it...) ?
    (i don't have a test device yet...)

  • stupbbqx2a3f's avatar
    stupbbqx2a3f
    Rising Novice
    2 months ago

    Hi , thank you for your help, I have installed the script and its enabled but I still cannot zoom?

    This is the keyboard, there are no scroll buttons except left and right at the bottom right?

  • ffi82's avatar
    ffi82
    Rising Traveler
    2 months ago

    i believe you can manage your keyboard layout in your tablet settings?
    ____________________________________________________
    this is where the zoom spinner should be (no keyboard needed for this):

     

  • stupbbqx2a3f's avatar
    stupbbqx2a3f
    Rising Novice
    2 months ago

    Hi, thank you very much 😊  I have a working zoom , this will now make the game playable on android. Much appreciated 🙏

  • ffi82's avatar
    ffi82
    Rising Traveler
    2 months ago

    update: added directional controls also... moves are not smooth but it works.
    these overlap with Raid Helper button... i'll fix it another day i think (if needed).

    (i don't have true Android tablet to try and implement and test the touch event handlers for smooth navigation instead of using these buttons...)

    ___________________________________
    edit:
    update again: on my emulator, the Unicode labels were not rendered so i replaced the lebels with icons.

     

     

  • stupbbqx2a3f's avatar
    stupbbqx2a3f
    Rising Novice
    2 months ago

    The scrolling buttons work perfectly, thank you very much 😊  🙏👍

About Tiberium Alliances Technical Issues

Having problems running the game or a script? Get help with Command and Conquer: Tiberium Alliances with the community!1,627 PostsLatest Activity: 10 days ago