Javascript Error: BCE044 and BCE043

Hey Guys!
I have a problem, I usualy just doing C# Coding and have to switch now to JS. my first experiment is to turn a “click on a mesh via raycasting and then something will happen” script into from a C# script to a JS Script. the JS code currently looks like this:

 //import UnityEngine;
//import System.Collections;

class carenter extends MonoBehaviour {

	// Use this for initialization
	function Start () : void {
	
	}
	
	// Update is called once per frame
	function Update () : void {
 	var screenRay : Ray= Camera.main.ScreenPointToRay(ScreenTouchPosition);
 	var rayhit : RaycastHit;
	if(Physics.Raycast(screenRay,  rayhit : out  )){
    if(rayhit.collider.tag == "doorTriggerLeft"){ //whatever you want to call it
        Debug.Log("Driving");
    }
}

i know that this should be the C# code:

Ray screenRay = Camera.main.ScreenPointToRay(ScreenTouchPosition);
RaycastHit rayhit;
if(Physics.Raycast(screenRay, out rayhit)){
    if(rayhit.collider.tag == "CoorTriggerLeft"){ //whatever you want to call it
        Debug.Log("Driving");
    }

but my JS Code is just giving me these errors:
Assets/car enter.js(15,47): BCE0044: expecting ), found ‘:’.
Assets/car enter.js(15,49): BCE0044: expecting ), found ‘out’.
Assets/car enter.js(15,54): BCE0043: Unexpected token: ).
Assets/car enter.js(20,1): BCE0044: expecting }, found ‘’.
Assets/car enter.js(20,1): BCE0044: expecting }, found ‘’.

Could you guys please help me out with that?

Remove “out”; you don’t specify “out” or “ref” in Unityscript (also out and ref aren’t types). Also remove the class definition, since scripts in Unityscript are automatically classes that extend MonoBehaviour anyway. (Not that it’s related to C#/Unityscript conversion, but it’s better to use the CompareTag function, instead of using string comparisons with ==.)