Unity5質問スレat GAMEDEVUnity5質問スレ - 暇つぶし2ch■コピペモード□スレを通常表示□オプションモード□このスレッドのURL■項目テキスト34:名前は開発中のものです。 15/08/05 21:01:23.52 CamXSh92.net >>33 Terrainの地形だけなら歯車アイコンからHeightMapのExportでできるけど他の設定はミリっぽいね 35:名前は開発中のものです。 15/08/05 23:24:16.52 Wak/H5zk.net Unity5.1.2の質問です。TPSを作ろうとしていて、弾丸を発射出来ずに困っています。 using UnityEngine; using System.Collections; public class GatlingFire : MonoBehaviour { public GameObject bulletprefab; public float interval = 0.5f; public float speed = 1000.0f; private float nextFire = 0.0f; private GameObject bullet; void Update(){ if (Input.GetKey ("t") && Time.time > nextFire) { nextFire = Time.time + interval; bullet = Instantiate (bulletprefab, GameObject.Find ("Spawn").transform.position, Quaternion.identity); bullet.GetComponent<Rigidbody>().velocity = Vector3.forward * speed; } } } というコードを書いたのですが、 Cannot implicitly convert type `UnityEngine.Object' to `UnityEngine.GameObject'. An explicit conversion exists (are you missing a cast?) というエラーが出ます。ググってみたのですが、記述に問題はなさそうなんですが、どこかおかしいでしょうか? どなたかわかる方よろしくお願いします。 次ページ最新レス表示レスジャンプ類似スレ一覧スレッドの検索話題のニュースおまかせリストオプションしおりを挟むスレッドに書込スレッドの一覧暇つぶし2ch