[過去ログ]
【ゲームエンジン】Unity初心者質問スレBuild1 (1002レス)
【ゲームエンジン】Unity初心者質問スレBuild1 http://mevius.5ch.net/test/read.cgi/gamedev/1528249519/
上
下
前次
1-
新
通常表示
512バイト分割
レス栞
抽出解除
レス栞
このスレッドは過去ログ倉庫に格納されています。
次スレ検索
歴削→次スレ
栞削→次スレ
過去ログメニュー
981: 名前は開発中のものです。 [sage] 2019/03/05(火) 15:47:15.85 ID:CxDtBk+6 >>979 そりゃあTime.deltaTimeのところをどう書いたらいいかって質問への回答だから、もちろんこのまま貼り付けても期待通りには動かんよ。 Vector3 current = new Vector3( 1, 0, 0 ); Vector3 target = new Vector3( 10, 10, 10 ); float duration = 3.0f; float speed; void Start() { this.speed = (this.target - this.current).magnitude / this.duration; } void Update() { this.current = Vector3.MoveTowards( this.current, this.target, this.speed * Time.deltaTime ); this.transform.position = this.current; } Vector3.MoveTowardsのリファレンスちゃんと読んでる? http://mevius.5ch.net/test/read.cgi/gamedev/1528249519/981
983: 名前は開発中のものです。 [] 2019/03/05(火) 19:17:44.97 ID:N7ZC2ho/ >>981 ありがとうございます ボタンを押したらオブジェクトが動くようにしたいのですが、 エラーがいくつも出てる状態なので、 リファレンスなども参考にして直していこうと思います http://mevius.5ch.net/test/read.cgi/gamedev/1528249519/983
メモ帳
(0/65535文字)
上
下
前次
1-
新
書
関
写
板
覧
索
設
栞
歴
スレ情報
赤レス抽出
画像レス抽出
歴の未読スレ
AAサムネイル
Google検索
Wikipedia
ぬこの手
ぬこTOP
1.450s*