这是我的代码:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
// Start is called before the first frame update
void Start()
{
public Rigidbody2D Hear;
}
// Update is called once per frame
void Update()
{
if (Input.GetKeyDown(KeyCode.Space))
{
Hear.velocity = Vector2.up * 10;
}
}
怎么了?
我加了分号但是没用 这也是统一的,所以如果你有程序,你可以尝试运行我的代码