Dialogue System + Rewired + ORK integration

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
rmagn
Posts: 21
Joined: Tue Jul 09, 2024 6:05 am

Dialogue System + Rewired + ORK integration

Post by rmagn »

hi,

im trying to use rewired with DS and ORK. i successfully setup the ork input keys with rewired.
i set the DS third party support and added
1. Input Device manager rewired into Dialogue Manager
2. Change UI Button Key trigger on dialogue UI continue button from Submit to RAccept (configured in rewired, works on ORK input).
3. Rewired Event System
img1
img2
img3

and the RAccept is accepted as input by rewired (before i didnt set ui button key trigger and is set to Submit and i got a warning, when i changed to RAccept, the warning disappeared)

but when conversation is started and waiting for continue button, the conversation didnt get continued when i press joystick / keyboard corresponding to RAccept.

1) how can i fix that?
2) is there anyway dialogue system to change rewired map category (from default to Dialogue map category)when starting conversation? i would like to change the rewired only to enable RAccept and disable other input. is there a way to do that using the current available integration?
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Dialogue System + Rewired + ORK integration

Post by Tony Li »

Hi,

Your screenshots look good. Your Dialogue Manager has an InputDeviceManager component and an InputDeviceManagerRewired component, correct?

Are there any errors or warnings in the Console window?

To change the Rewired map category, add a script to the Dialogue Manager that has OnConversationStart(Transform) and OnConversationEnd(Transform) special script methods. In OnConversationStart, set the Dialogue map. In OnConversationEnd, set the other map.
rmagn
Posts: 21
Joined: Tue Jul 09, 2024 6:05 am

Re: Dialogue System + Rewired + ORK integration

Post by rmagn »

Hi,

1) yes, i have inputdevicemanager and inputdevicemanagerrewired on dialoguemanager object like this img . and yes it doesnt show any warning / error, after i changed the Submit button name on UI Button Key Trigger component to RAccept (rewired).
it's just it doesnt respond to that key, and i can still open menu because i havent changed the rewired map category. (meaning rewired should be detecting RAccept as well)
i also have key "Space" set on continue button's UI Button Key Trigger component, and if i use it, it works, only the RAccept didnt work img2

2) i added DIalogue System Event component to Dialogue Manager, is it right? for change rewired map, is there any DS 3rd party integration function that can do it or i should make a new script to notify rewired manually?
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Dialogue System + Rewired + ORK integration

Post by Tony Li »

Here's an example scene:

DS_RewiredContinueUIButtonKeyTriggerExample_2024-07-29.unitypackage

The 'E' key starts a conversation and acts as the UI Submit input (e.g., to click a response button).

The 'C' key is mapped to the Rewired action "Continue", which is assigned to the continue button's UIButtonKeyTrigger component.

It uses the latest Rewired integration package, which was updated for the upcoming version 2.2.48. The only change is that DialogueSystemRewired is just an empty subclass of InputDeviceManagerRewired now.

DS_RewiredSupport_2024-07-29.unitypackage


> 2) i added DIalogue System Event component to Dialogue Manager, is it right? for change rewired map, is there any DS 3rd party integration function that can do it or i should make a new script to notify rewired manually?

Make a custom script, since everyone's needs are different.
rmagn
Posts: 21
Joined: Tue Jul 09, 2024 6:05 am

Re: Dialogue System + Rewired + ORK integration

Post by rmagn »

hi
1) i tried the package you provided (example and newest Rewired support packages) and run Rewired Continue UIButtonKeyTrigger Example scene. but when i got here and press C key on my keyboard, nothing happens...
2) thank you for confirming. i created the custom script and i can switch map categories now
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Dialogue System + Rewired + ORK integration

Post by Tony Li »

Hi,

Your screenshot shows the response menu. The response menu uses Unity UI's EventSystem, not the continue button's UIButtonKeyTrigger. In the example scene, the EventSystem uses a RewiredStandaloneInputModule. The EventSystem's Submit input is set to the Rewired action "UISubmit", which is mapped to the 'E' key. If you press the 'E' key, it will click the response ("Okay, what's the problem?").

The continue button comes into play before that:
rewiredContinue.png
rewiredContinue.png (661.02 KiB) Viewed 502 times
rmagn
Posts: 21
Joined: Tue Jul 09, 2024 6:05 am

Re: Dialogue System + Rewired + ORK integration

Post by rmagn »

Hi,

ah my bad, i misunderstood... i confirm the C key is working on NPC subtitle XD
also my control seems to be working on dialogue now, but everytime i want to click RAccept button (either on keyboard / joystick) i need to click on the screen using mouse , it feels like it keeps losing focus.. do you know what might the cause be? XD

EDIT : now its working. i followed your settings, where inputdevicemanager's Submit button should not be the same as Continue button's UI button key trigger button's name

thank you Tony!
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Dialogue System + Rewired + ORK integration

Post by Tony Li »

Glad to help!
Post Reply