Activate Settings panel with Button:

Original Discord Post by josegarciacordoba | 2024-08-30 09:54:01

I want to add a button to open the Settings panel, so that in addition to activating it by pressing F10, it is activated by the action of a button.

But I can’t find the way. It’s a Prefab, and I can’t find the settings for the controls.

Thanks.

Reply by k3kalinix | 2024-08-30 09:57:02

Hello <@992368851234869308>,

Reply by k3kalinix | 2024-08-30 10:04:01

Images:

Reply by k3kalinix | 2024-08-30 10:04:14

Images:

Reply by k3kalinix | 2024-08-30 10:04:33

Images:

Reply by k3kalinix | 2024-08-30 10:04:40

You can change from here.

Replying to k3kalinix’s Message

Reply by k3kalinix | 2024-08-30 10:04:14

Reply by josegarciacordoba | 2024-08-30 10:24:06

Thanks, I couldn’t find the asset.

In the end, I solved it in another way.

I just made the function public:

       public void ToggleSettings()

From UISettingsPanel.cs

And I call it when the button is pressed.

In case it helps anyone.

Thanks.

Reply by k3kalinix | 2024-08-30 10:25:05

Which version of Convai are you using?

Replying to k3kalinix’s Message

Reply by k3kalinix | 2024-08-30 10:25:05
Which version of Convai are you using?

Reply by josegarciacordoba | 2024-08-30 10:25:47

The new one, the one that came out a couple of days ago. I’ve already updated it.

Reply by k3kalinix | 2024-08-30 10:27:36

Could you please share a screenshot?
Assets / Convai / Resources / Controls.inputactions

Reply by josegarciacordoba | 2024-08-30 10:31:59

Images:

Reply by k3kalinix | 2024-08-30 10:32:06

Yes you have

Reply by k3kalinix | 2024-08-30 10:32:24

Images:
image.png

Reply by k3kalinix | 2024-08-30 10:32:28

Click on this.

Reply by k3kalinix | 2024-08-30 10:32:39

Add a new button

Replying to k3kalinix’s Message

Reply by k3kalinix | 2024-08-30 10:32:24

Reply by josegarciacordoba | 2024-08-30 10:34:10

But I activate it with a button that I added to the canvas. Can I add that from there?

Reply by k3kalinix | 2024-08-30 10:42:20

Yes

Reply by k3kalinix | 2024-08-30 10:42:25

Wait

Reply by k3kalinix | 2024-08-30 10:42:32

Do you mean UI button?

Reply by josegarciacordoba | 2024-08-30 10:42:49

The whole problem comes because I don’t want the mouse to disappear or lock. And automatically, when I click on the screen it locks it.

I know it’s this:

Cursor.lockState

But I’ve already changed it from UISettingsPanel.cs

But it must be somewhere else.

When I click anywhere on the screen, the cursor locks and disappears.