using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class Move : MonoBehaviour
{
public float speed = 10;
private Rigidbody2D rb;
private float moveInput;
// Start is called before the first frame update
void Start()
{
rb = GetComponent<Rigidbody2D>();
}
// Update is called once per frame
void FixedUpdate()
{
moveInput = Input.GetAxis("Horizontal");
rb.velocity = new Vector2(speed * moveInput, ???);
}
}
Подскажите что указать в месте, которое обозначено знаками "???". При указании 0f квадрат падает вниз.