Requesting mouse left and right input plugin to active events

Hello, I want to build a city builder kind of rpg. I have searched far and wide for some mouse input plugins but none is built for this. Need to have a left, AND right click action button on mouse. The plugin should know which of them is used when clicking a event so that we can i.e make a tool-menu for the event with right click and a action menu when left click.
I dont mind actually how it gets solved as long as we can communicate to the engine that this event is rightclicked so i can run event commands.

Maybe with a comment on the event pages like this
click_right A true;
click_left B true;

I really think this covers it. Let me know if you are interested and or need more info. 😀 happy rpg making!
Hello, I want to build a city builder kind of rpg. I have searched far and wide for some mouse input plugins but none is built for this. Need to have a left, AND right click action button on mouse. The plugin should know which of them is used when clicking a event so that we can i.e make a tool-menu for the event with right click and a action menu when left click.
I dont mind actually how it gets solved as long as we can communicate to the engine that this event is rightclicked so i can run event commands.

Maybe with a comment on the event pages like this
click_right A true;
click_left B true;

I really think this covers it. Let me know if you are interested and or need more info. 😀 happy rpg making!
Something like this?
...this...
https://yanflyengineplugins.itch.io/event-click-trigger
..or maybe this?

...but with separate left/right click support?
(i think that only does left.. pretty sure at least)
Yeah, something like that, but just what i described. I think maybe that "Mouse system ex" can be modified to accept both TouchInput.isCancelled(); and touchinput.trigger. Hopefully someone understands it and throws us a bone 😀

Edit:
Im starting out, but I have very little experience so please help

add on line 1066
Code:
this.TDDP_MS.rightclickSwitch  = false;

add on line 1109
Code:
$._findInEventNotetags(this, /rightclick_switch\s(.*?)\s(.*?);/i, function(result) {
            this.TDDP_MS.rightclickSwitch = {};
            this.TDDP_MS.rightclickSwitch.key = String(result[1]);
            this.TDDP_MS.rightclickSwitch.val = String(result[2]);

        });





I think this part is the last, but have not edited it yet.
Line 982
Code:
    /**
    * Alias and extend _onTrigger() to only fire if we're not activating on click
    */ 
    var _TouchInput_onTrigger = TouchInput._onTrigger;
    TouchInput._onTrigger = function(x, y) {
        if (TouchInput._activateClickEvents(x, y)) {
            $gameTemp.clearDestination(); // Invalidate destination
        } else {
            _TouchInput_onTrigger.call(this, x, y);
        }
    };
    /**
    * Activate click events if valid and return true if so
    * @method _activateClickEvents
    * @param x {Number} Map X coordinate
    * @param y {Number} Map Y coordinate
    */
    TouchInput._activateClickEvents = function(x, y) {
        var found_click_event = false;
        if ($.conditionsValidForMouseHoverCheck()) {
            var x = $gameMap.canvasToMapX(x);
            var y = $gameMap.canvasToMapY(y);
            $._eventsXy(x, y).reverse().forEach(function(game_event) {
                if (game_event.TDDP_MS.clickActivate) {
                    game_event.start();
                    found_click_event = true;
                };
                if (game_event.TDDP_MS.clickSwitch) {
                    var key = [$gameMap._mapId, game_event._eventId, game_event.TDDP_MS.clickSwitch.key]
                    $gameSelfSwitches.setValue(key, game_event.TDDP_MS.clickSwitch.val === 'true');
                    found_click_event = true;
                };
            });
        }
        return found_click_event;
    }

Original thread: https://forums.rpgmakerweb.com/threads/requesting-mouse-left-and-right-input-plugin-to-active-events.120501/