Problem with Unity 3D Development

Asked

Viewed 675 times

3

I’m creating a game project in Unity 5-64bits, I’m in the creation part of the camera drive. When I was typing the Javascript code, trying to use parentheses always gave the following error:

An error has occurred - error in text editor Extension Chair


Erro da utilização de parênteses


I noticed the error and continued to finish the code, I reached a point that could already be executed, but by dragging the code to the location of the following message:

Please Fix Compile errors before Creating new script Components

My code:

#pragma strict

var Velocidade: Vector3;

function Start () {
}

function Update () {

   Velocidade.x =0;
   Velocidade.y =0;
   Velocidade.z =0;

   if (Input.mousePosition.x<=5 || Input.mousePosition.x>=screen.width-5)
   {
      Velocidade.x = Input.GetAxis ("Mouse X")*10*Time.deltaTime;
   }

   if (Input.mousePosition.y<=5 || input.mousePosition.y>=screen.height-5)
   {
      Velocidade.z = Input.GetAxis("Mouse X")*10*Time.deltaTime;
   }

   transform.Translate(Velocidade);
}

And when clicking Play the following message appears:

All Compiler errors have to be Fixed before you can enter playmode!

I think she’s on account of the problems...

  • Can show the Details of that Monodevelop error screen?

  • You’re here. http://pastebin.com/TwrV6CAd

  • That there must be a Monodevelop error unique to version 64. I saw that some people decided updating Unity, others disabling the language BOO unity.

2 answers

3

I found the mistake! I believe because it is some Unity update, which does not execute the unfinished code, or because I wrote the wrong code. when I conclude executed perfectly.

Code finalized.

#pragma strict

var Velocidade: Vector3;

var ConstanteZ: float;

var ConstanteX: float;

function Start () {

}

function Update () {



if (Input.mousePosition.x<=5 || Input.mousePosition.x>=Screen.width-5)
 {
   if (Input.GetAxis("Mouse X")!=0)
   {
   if (Input.GetAxis("Mouse X")>0 && Input.mousePosition.x>=Screen.width-5)
   {
    ConstanteX=2;
   } 
   else
   {
    if (Input.mousePosition.x<=5)
    {
      ConstanteX=-2;
     }
   }
  
    
    
    Velocidade.x = ConstanteX*30*Time.deltaTime;
   }
 }
 else
 {
 Velocidade.x=0;
 }

if (Input.mousePosition.y<=5 || Input.mousePosition.y>=Screen.height-5)
 {
  if (Input.GetAxis("Mouse Y")!=0)
   {
    if (Input.GetAxis("Mouse Y")>0 && Input.mousePosition.y>=Screen.height-5)
   {
    ConstanteZ=2;
   } 
   else
   {
    if (Input.mousePosition.y<=5)
    {
      ConstanteZ=-2;
     }
   }
  }
    Velocidade.z = ConstanteZ*30*Time.deltaTime;
   
 }
 else
 {
 Velocidade.z=0;
 }
 Velocidade.y = -Input.GetAxis("Mouse ScrollWheel")*200*Time.deltaTime ;
transform.Translate(Velocidade);
}

1

Looks like you got this problem: "Error in text editor Extension chain." when trying to Edit new Unityscript file

In short, the Boo extension setting (add-in) is damaged.

I can not confirm at the moment, the suggested steps on the link. So I can’t say exactly what you should delete.

Possibly, disabling the Boo in the Add-in Manager, in the Language Bindings section. Closing Unity and Monodevelop, and opening Unity again, is enough.

  • Can you be more specific about what I should do!? because I didn’t understand anything.

  • Disable the Boo plug-in. Something like: link1 or Link2

Browser other questions tagged

You are not signed in. Login or sign up in order to post.