vci:sample:onuse:hapticitem

差分

この文書の現在のバージョンと選択したバージョンの差分を表示します。

この比較画面にリンクする

両方とも前のリビジョン 前のリビジョン
最新リビジョン 両方とも次のリビジョン
vci:sample:onuse:hapticitem [2023/05/09 12:43]
pastatto 統合リンク修正
vci:sample:onuse:hapticitem [2023/09/29 15:30]
pastatto サンプルのデータ追加
ライン 1: ライン 1:
 ====== アイテムを使ったときにコントローラーを振動させる ====== ====== アイテムを使ったときにコントローラーを振動させる ======
  
-アイテムを使ったときに振動するVCIのサンプルです。+[[https://​developer.virtualcast.jp/​vci-docs/​api/​events/​onUse.html | onUse]]を使用した、アイテムを使ったときに振動するVCIのサンプルです。
  
 === サンプルデータ === === サンプルデータ ===
 https://​virtualcast.jp/​products/​5dfddae440784a11754b606a5b5246e00c33b6f59db737ff5ebd2c256f39f574 https://​virtualcast.jp/​products/​5dfddae440784a11754b606a5b5246e00c33b6f59db737ff5ebd2c256f39f574
 +
 +{{ :​vci:​sample:​onuse:​vibration_vci.zip |}}
  
 ===== 素材データ ===== ===== 素材データ =====
ライン 33: ライン 35:
  
 function onUse(use) function onUse(use)
-    ​-- useにはつかんだSubItemの名前が格納される +    ​if use == "​Cube"​ then 
-    vci.assets.HapticPulseOnGrabbingController(use,​ 3000, 1) +        vci.assets.HapticPulseOnGrabbingController(use,​ 3000, 0.1)    ​--コントローラーを振動させる 
-    print(use.."​をUseしたコントローラーを振動させます"​)+    end
 end end
  
 </​file>​ </​file>​
  
vci/sample/onuse/hapticitem.txt · 最終更新: 2023/10/04 18:20 by pastatto

ページ用ツール