You can mount a 3-D object onto another object by specifying the target model in the 7th argument of MODEL_ADD.  In the example below, the spinning menu is attached to a model with alias name “mei”. This command is used in the “Sample Script” of MMDAgent.

  0 1 <eps> MODEL_ADD|menu|Accessory\menu\menu.pmd|0.0,-4.5,0.0|0.0,0.0,0.0|ON|mei

You can also specify a target bone where the model should be mounted. The following example mounts the menu on the right wrist of the model. (“右手首” means “right wrist” in Japanese)

  0 1 <eps> MODEL_ADD|menu|Accessory\menu\menu.pmd|7,-1.5,0|0,90,90|ON|mei|右手首

manu_on_wrist

=== Japanese ========================================

ある3Dモデルを別のモデルに載せて表示するには,載せる対象のモデルをMODEL_ADDコマンドの7番目のオプションで指定します.たとえば,モデルエイリアス名meiのモデルに回転メニューを追従して表示させる場合は,以下のように記述します.これは,MMDAgent本体と同時に配布されている「Sample Script」でも使われています.

  0 1 <eps> MODEL_ADD|menu|Accessory\menu\menu.pmd|0.0,-4.5,0.0|0.0,0.0,0.0|ON|mei

また,ボーン名を追加で記述することで特定のボーン上に載せることもできます.以下の例では,meiの右手に回転メニューを載せています.

  0 1 <eps> MODEL_ADD|menu|Accessory\menu\menu.pmd|7,-1.5,0|0,90,90|ON|mei|右手首

manu_on_wrist

CC-BY-NC Copyright 2009-2013 Nagoya Institute of Technology (MMDAgent Model “Mei”)
CC-BY Copyright 2009-2013 Nagoya Institute of Technology (MMDAgent Accessory “NIT Menu”)

Advertisements