public void Update() { if (!usePhysic) { --flames; if (flames <= 0 && start == true) { flames = Random.Range(60 - round * 3, 60 - round * 1); ++trial; Disk disk = diskFactory.GetDisk(round); actionManager.MoveDisk(disk); if (trial >= 10) { trial = 0; ++round; } } if (Input.GetButtonDown("Fire1")) { Hit(Input.mousePosition); } } }
void Update() { if (start == true) { count++; if (count >= 120) // 120s over { count = 0; trail++; Disk d = DF.GetDisk(round); Manager.MoveDisk(d); if (trail == 10) { round++; trail = 0; } } } }
void Update() { //val帧产生一个飞碟 int val; switch (round) { case 1: val = Random.Range(60, 80); break; case 2: val = Random.Range(45, 60); break; default: val = 40; break; } if (start) { count++; if (count >= val) //val帧一个飞碟 { count = 0; if (DF == null) { Debug.LogWarning("DF is NUll!"); return; } producedDiskNum++; Disk d = DF.GetDisk(round); Manager.MoveDisk(d); if (producedDiskNum == 20) //20个飞碟进入下一个回合 { round++; producedDiskNum = 0; } } } }