简体   繁体   中英

How to fix “Win32Exception: The system cannot find the file specified.” error in unity

Literally started to learn to code a few days ago just been watching videos but when i try and add a script for player movement on my object there in an error

This is on unity engine and i haven't tried much yet because i don't know where to start

Win32Exception: The system cannot find the file specified.

System.Diagnostics.Process.StartWithShellExecuteEx (System.Diagnostics.ProcessStartInfo startInfo) (at <735c83e43c004ee998f77c68cf8035da>:0) System.Diagnostics.Process.Start () (at <735c83e43c004ee998f77c68cf8035da>:0) (wrapper remoting-invoke-with-check) System.Diagnostics.Process.Start() UnityEditor.DefaultExternalCodeEditor.OpenProject (System.String path, System.Int32 line, System.Int32 column) (at C:/buildslave/unity/build/Editor/Mono/CodeEditor/DefaultExternalCodeEditor.cs:136) Unity.CodeEditor.CodeEditor.OpenProject (System.String path, System.Int32 line, System.Int32 column) (at C:/buildslave/unity/build/Editor/Mono/CodeEditor/CodeEditor.cs:31)

The code i put into visual studio is

    using UnityEngine;

    public class Playermovement : MonoBehaviour
    {
    // Start is called before the first frame update
    void Start()
    {
        Debug.Log("Hello. world");
    }

    // Update is called once per frame
    void Update()
    {

    }
    }

i was just expecting on the console to write "Hello. world"

There is no any method available like Log in Debug class. You just use Write and WriteLine, Print etc.

Debug.Write("Hello. world");

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM