A second mouse for a gamepad Player in a Splitscreen Multiplayer game

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Godot_Starter

So I made a splitscreen multiplayer game. One Player controlls it with keyboard and mouse and the second Player controlls it with a Gamepad (Xbox One Controller). But there is a Inventory system for both Players, which requires a mouse. Is there a way how I can make a second mouse, which is controlled by the gamepads joystick, so that the gamepad player can use his inventory?

Both players share the inventory system? Or do the players have separate inventories?

Ertain | 2020-07-18 03:21

:bust_in_silhouette: Reply From: whiteshampoo

Of couse you can.

Save the position in a Vector2, and modify it with the input-strength of the X- and Y-Axis of your chosen stick.
Register the left-click and the game-pad-button in the same action.
Then draw a small arrow to the position.

Now you can use the position-variable instead of get_*_mouse_position()