将C#脚本带入作为本机代码的Unity。 / 总览 var src = @" class PlayerMovement : MonoBehaviour { public void MoveForward() { transform.position += new Vector3(0, 0, 1); } } " ; var script = CScript . CreateRunner ( src ); dynamic move = script . Override ( " PlayerMovement " , this ) . AsDynami