1
resposta

Código para movimentação para o personagem.

Quando eu tento colocar o meu código na hierarquia ele apresenta o seguinte erro: "can't add script behaviour CallbackExecutor. The script needs to derive from MonoBehaviour!".

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class ControlaPersonagem : MonoBehaviour
{
    // Start is called before the first frame update
    void Start()
    {

    }

    // Update is called once per frame
    void Update() => transform.Translate(Vector.forward);
}
1 resposta

Oi, Fabio, tudo bem?

Seu projeto tem algum outro script?

Quer zipar o projeto e mandar um link pra gente dar uma olhada?

Quer mergulhar em tecnologia e aprendizagem?

Receba a newsletter que o nosso CEO escreve pessoalmente, com insights do mercado de trabalho, ciência e desenvolvimento de software