我想更改/更新工厂速度,但是此代码仅更新新生成的工厂速度 我该怎么办?
IEnumerator Fade()
{
while (true) {
gelencizgi = Instantiate(gelencizgi, new Vector3(1298, 1.2f, 126.1f), Quaternion.identity);
gelencizgi.GetComponent<Animator>().Play("gelencizgi");
gelencizgi.GetComponent<Animator>().SetFloat("myspeed", .2f * hizkatsayisi);
yield return new WaitForSeconds(1f/hizkatsayisi);
Destroy(gelencizgi, 2/hizkatsayisi);
}