ChatdollKit icon indicating copy to clipboard operation
ChatdollKit copied to clipboard

help need with animation

Open chethanwiz opened this issue 1 year ago • 4 comments

hello am not able to understand how to add or create animation while talking, can you please guide me

chethanwiz avatar Apr 13 '24 20:04 chethanwiz

Hi @chethanwiz , I don't understand the conditions of your question, but if, for example, you want to use autonomous animation control by ChatGPT, and you want to use something other than what is included in the demo, then it would be as follows:

  1. Add the new animation clip to your AnimatorController and make transitions that will be fired, for example, when BaseParam == 100.

  2. Add code to register the new animation for ChatGPT to control it.

var llmContentSkill = gameObject.GetComponent<LLMContentSkill>()
llmContentSkill.RegisterAnimation("swim_like_dolphin", new Model.Animation("BaseParam", 100, 3.0f));
  1. Set it to prompt
# Animation

* You can express your emotions through the following animations:

- angry_hands_on_waist
- brave_hand_on_chest
      : etc.
- swim_like_dolphin

* If you want to express emotions with gestures, insert the animation into the response message like [anim:waving_arm].

Example
[anim:waving_arm]Hey, over here!

Then, when ChatGPT wants to swim like a dolphin, it says '[anim:swim_like_dolphin] I want to swim...'. ChatdollKIt handles the animation tag, sets the BaseParam to 100 internally, and then the animation associated with BaseParam == 100 is performed.

uezo avatar Apr 14 '24 23:04 uezo

Hello @uezo I apologize sincerely for the inconvenience. I'm still getting acquainted with Unity projects. Could you kindly guide me on where to insert these codes? I attempted to solve it independently, but encountered errors instead.

Also, are you available on Discord or any other platform.

chethanwiz avatar Apr 17 '24 20:04 chethanwiz

@chethanwiz You can insert the code in any executable section of a script, such as Start(). I'm unable to provide individual support, but you might find https://learn.unity.com/ helpful 👍

uezo avatar Apr 17 '24 23:04 uezo

Hey, @uezo

I'm sorry I asked about Discord; I've seen people maintaining servers and posting updates and stuff, so I was curious.

chethanwiz avatar Apr 20 '24 22:04 chethanwiz