Posts

A brief intrruduction to my ControlRig_LookAt implementation.

Image
A brief intrruduction to my ControlRig_LookAt implementation . There are total 7 controls. bool  EnableLookAt   and Vector3D  LookAtTarget . ELookAtHelper_TorsoOverwrite  EnableLookAt_Torso   and Vector3D  LookAtTarget_Torso . ELookAtHelper_Overwrite  EnableLookAt_Eye   and Vector3D  LookAtTarget_Eye . bool CapLookAtZ . When  EnableLookAt   == true, it rotates pelvis, spines, neck, head and eye bones. When  EnableLookAt_Torso   == Overwrites, you get to rotate pelvis & spines seperately. When  EnableLookAt_Torso   == Disable, rotates nothing below neck bone. When  EnableLookAt_Eye   == Overwrites, you get to rotate eyes seperately. CapLookAtZ == true, the system will 1.  prevent from happening if the target is too close or right in your face. and 2. prevent from happening if our target is right below your feet. Also, to prevent cross-eyed...

UE5 ControlRig issue - LevelSequencer

Image
Say, you have a Character. You asigned a AnimationBP to it. Inside the ABP, you have some AnimGraphNodes to switch between animation, ControlRig to manipulate bones, etc, etc. In Game, during runtime, you get to make the character "LookAt" wherever you want it to look. And one day, cutscene guy comes to me, "Animation doesn't switch, facial blending doesn't run, etc, etc, everything seems to be broken one I track the CR_LookAt". What? So I investigated. It seems, Unreal Engine will replace whatever you've assigned to SkeletalMeshComponent.AnimClass, to something called ControlRigLayerInstance. k..... of course you are going to lose everything!!! Talking to Epic. I brought the issue to Epic in 2023/08/09 and I don't think there's a solution yet (as of 2025/04/11), so the only viable workaround would be "baking". Remember to Bake before you start using ControlRig, kids! But sometimes, you need to bake multiple times cus you have different...

ゲームの開発者は物理法則をどのくらいゲームに持ち込みますか?

Image
Someone asked about this a while ago and this is how I look at it. 僕の場合は、できれば… make sense したいですね。 これとか… ま、DBだから、皆時間より速いでしょう。 こいつはそこまでの超人ではないでしょう。 あとこれとか… 人間のあなた、これどう対応する? これとか。足は上下動いてないから、更に分かりやすい。 FootIK なら、これは僕の実装 (けっこ前のやつ。最新のは公開してない) * 凸凹地形/崖 * 1:43 Static Keyframe Animation ← 80年代/2D 時代からのコンセプト 1:54 Traditional FootIK ← PS2ごろからのコンセプト 2:06 Predictive FootIK ← 僕の実装。Havok で active ragdoll, procedural animation を遊んだ 8 年後、関心なところがやっとピンときて、実装した。 * 坂 * 2:18 Static Keyframe Animation 2:26 Traditional FootIK 2:33 Predictive FootIK * 階段 * 2:44 Static Keyframe Animation 2:55 Traditional FootIK 3:03 Predictive FootIK 3:15 Free roam。プログラムを壊そうとしてる。 完璧さは狙てない。重視してるのは 1. スピード 2. アサシンクリードみたいな、user input を奪わない 今の時代だと… Static keyframe?なんでしょうね… Traditional FootIK?ま、古。対応できない地形もいっぱいあるし。一個一個対応したいなら、開発コスト ↑↑だね 。 Machine learning で?んんん、やりすぎって感じかな。 こう言うのも僕はけっこ気になります。 ↑RDR2 はいい反例 ↑これは… 僕は案がある。Active Ragdoll と static keyframe の間に上手く blend すれば、判定とゲーム性は変わらず、見た目だけよくなれると思う。 あと、先日リリースされたHi-Fi Rush のカットシーンのデザインはなかなか上...

202012 Predictive Foot IK v1.1.2:AnimSeq mirroring

Image
  十年前から Predictive Foot IK を研究してきました。コツを掴んだのは約二年前。v1.1.2 まで来たのでちょっとで共有。 その前に、ちょっと復習。 30年間使い続けてきた static keyframe / FK animation. 問 題ないかな? 高低差があったら、浮かんでるように見える 近代、主流な Foot IK の場合。 問題ないかな? 足元も、腰も地面に沿って昇降している じゃ、質問。主流な Foot IK + こんな地形なら? 激しく上下に揺れる。超えられない壁です。 何故なら、両足も、腰も、こんな time / z graph になります。Heavy interp を使ってもいい結果が貰えないです。 じゃ、mo-cap で対応したら?いけるよ。block 達の相対位置と歩き方向がが変わらない限り。 「斜め地形の例」に戻ります。Predictive Foot IK の場合はこんな感じ。 コツはなんでしょう? 複雑な数学と knowhow… 経験がないと説明しても… 皆さんの実装も違うはず、case by case なところもあります。 コンセプトだけ分かればいいと思う。 従来の Foot IK は "現在" の足元下の高さしか検知しないので、垂直な地形なら無理。今の frame の z は 10、次の frame の z はいきなり 200 になる可能性はなくはない。 Predictive Foot IK は 1) 未来の足元 xy を探す → 2) 過去から未来までの高さを全検索 → 3) 放物線を作る (q uickhull    でもいい) → 4) 放物線で今の足 z を計算する → 5) 両足の放物線で腰位置を計算。 実際、こんな地形を使ってるゲームはあるのですか? 高低差低いの垂直地形なら、なくはないよ。DMC5 とか, 龍が如くとか。 石でできた 30cm ぐらいの丸いバリケードとか? 普通のゲームだと… 通させないパターンです。記事を読んでる人間の皆さんはどう反応しますか?こんな低い障害物をわざと避ける必要?ない。自分は避けず、踏まず越えるか、踏んで超えるかすね。 「使ってるゲームはないじゃないか」って思った人は、その原因が分かりますか? 弱点を知...