# I need help passing dynamic information to Convai characters

**URL:** <https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741>\
**Category:** Unity SDK\
**Tags:** question, unity\
**Created:** [September 22, 2024, 9:54pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741 "2024-09-22T21:54:10Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:54pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/1 "2024-09-22T21:54:10Z")

</div>

**Original Discord Post by \_drhydra | 2024-09-22 21:54:10**

I’m creating a detective game where clues about a crime are distributed to the players and Convai characters. I need these clues to be communicated to the characters so that players can interrogate them and discover which clues they possess.

I was considering using the method `_convaiChatUIHandler.SendPlayerText(input);` to pass the clues they hold. I also thought about using the **‘Knowledge Bank,’** but since the clues change between playthroughs, this might not be ideal. I believe using the \*\*‘Narrative Design’ \*\*feature wouldn’t work either, for the same reason—the clues vary between sessions.

Additionally, it wouldn’t be ideal for players to see what clues the characters received in the chat history.

Could someone recommend the best way to handle this?  
🥹

**Images:**

 ![image.png](https://canada1.discourse-cdn.com/flex004/uploads/convai/original/2X/7/7bd468dd28f3ef847dddfaedbf3975221641e3cc.jpeg)

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:55pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/2 "2024-09-22T21:55:42Z")

</div>

**Reply by k3kalinix | 2024-09-22 21:55:42**

Hello \<@467453703893418017\> 👋🏻,

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:56pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/3 "2024-09-22T21:56:49Z")

</div>

**Reply by \_drhydra | 2024-09-22 21:56:49**

Hello \<@1023671043287699568\> 👋

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:57pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/4 "2024-09-22T21:57:07Z")

</div>

**Reply by k3kalinix | 2024-09-22 21:57:07**

You can use _message_

Just try to get your NPC reference and call SendTextDataAsync

**Images:**

 ![image-19.png](https://canada1.discourse-cdn.com/flex004/uploads/convai/original/2X/0/034f02ea76547561792b7f5271584bf1e2738877.png)

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:57pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/5 "2024-09-22T21:57:23Z")

</div>

**Reply by k3kalinix | 2024-09-22 21:57:23**

Or you can use Narrative Design Trigger.

**Images:**

 ![image-12.png](https://canada1.discourse-cdn.com/flex004/uploads/convai/original/2X/1/1232fd8ec51833c4038c456cedfea6928d4253e4.png)

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:58pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/6 "2024-09-22T21:58:18Z")

</div>

**Reply by \_drhydra | 2024-09-22 21:58:18**

Okay, I’ll try that.  
Thanks 🫶

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 9:58pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/7 "2024-09-22T21:58:53Z")

</div>

**Reply by k3kalinix | 2024-09-22 21:58:53**

Basically,  
_clue_

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:01pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/8 "2024-09-22T22:01:00Z")

</div>

**Reply by \_drhydra | 2024-09-22 22:01:00**

Just a little question: will the characters remember the clue if I do it that way using SendTextDataAsync? And will this communication appear in the character chat?

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:01pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/9 "2024-09-22T22:01:34Z")

</div>

**Reply by k3kalinix | 2024-09-22 22:01:34**

1- In the same session yes.  
2- yes

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:04pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/10 "2024-09-22T22:04:01Z")

</div>

**Reply by \_drhydra | 2024-09-22 22:04:01**

Thank you for the response!  
Is there a way to pass the clue information to the character so that it is remembered during the session, but without showing up in the chat visible to the player?  
Since it’s an investigation game, I need the character to keep the clue without the player seeing the direct input in the conversation history.

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:06pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/11 "2024-09-22T22:06:43Z")

</div>

**Reply by k3kalinix | 2024-09-22 22:06:43**

You need to customize Convai scripts. So in ChatUIHandler you can create a bool called IsClue, set it to true when you send text and it won’t show.  
Set it to false when you send a normal message.

Customization is up to you. We cannot provide support on this…

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:09pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/12 "2024-09-22T22:09:16Z")

</div>

**Reply by \_drhydra | 2024-09-22 22:09:16**

Thank you so much for the guidance!  
I appreciate the clarification and the suggestion to customize the Convai scripts.  
I understand that the customization is on my side, and I’ll work on implementing the solution.  
Your help has been really valuable. Thanks again! 👋

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:09pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/13 "2024-09-22T22:09:45Z")

</div>

**Reply by k3kalinix | 2024-09-22 22:09:45**

\<@467453703893418017\>

If you have any other questions, please do not hesitate to ask.

We would be very grateful if you could leave a comment on our store pages with your company name or the name of your project. We value your feedback and comments as they help us improve our services and products.  
Asset Store: [NPC AI Engine - Dialog, actions, voice and lipsync - Convai | Behavior AI | Unity Asset Store](https://assetstore.unity.com/packages/tools/behavior-ai/npc-ai-dialog-actions-and-general-intelligence-by-convai-235621#reviews)

**Embedded Content:**  
**NPC AI Engine - Dialog, actions, voice and lipsync - Convai | Behav…**  
Get the NPC AI Engine - Dialog, actions, voice and lipsync - Convai package from Convai and speed up your game development process. Find this & other Behavior AI options on the Unity Asset Store.  
Link: [NPC AI Engine - Dialog, actions, voice and lipsync - Convai | Behavior AI | Unity Asset Store](https://assetstore.unity.com/packages/tools/behavior-ai/npc-ai-dialog-actions-and-general-intelligence-by-convai-235621)

 ![Thumbnail](https://canada1.discourse-cdn.com/flex004/uploads/convai/original/1X/007a1958390a9f1f94936341fcca5647e9775c13.jpeg)

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:11pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/14 "2024-09-22T22:11:06Z")

</div>

**Reply by \_drhydra | 2024-09-22 22:11:06**

Thank you for the help!  
I’ll be sure to leave a comment on the store page with my project details. Your support is much appreciated!

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [September 22, 2024, 10:13pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/15 "2024-09-22T22:13:52Z")

</div>

**Reply by \_drhydra | 2024-09-22 22:13:52**

By the way, can you mark this as solved for me?  
I can’t find the option: 😵

**Images:**

 ![image.png](https://canada1.discourse-cdn.com/flex004/uploads/convai/original/2X/c/c7d4121ecd9bc23d74e7a3a6985e46a8a4ca864f.png)

---

<div class="post-metadata">

**Author:** ![K3](https://yyz2.discourse-cdn.com/flex004/user_avatar/forum.convai.com/k3/32/2611_2.png) [@K3](https://forum.convai.com/u/K3)\
**Post date:** [November 25, 2024, 12:14pm UTC](https://forum.convai.com/t/i-need-help-passing-dynamic-information-to-convai-characters/1741/16 "2024-11-25T12:14:28Z")

</div>

Closed on November 25, 2024, 12:14pm UTC

This conversation happened on the Convai Discord Server, so this post will be closed.
