Quantcast
Channel: Answers by "BetaWar"
Viewing all articles
Browse latest Browse all 4

Answer by BetaWar

$
0
0
1. I am not 100% sure here, I haven't really dived into the UnityScript engine as of yet, but in Javascript and Actionscript 3 (both of which are based off of the ECMA Script standard), objects which have no references to them (orphaned variabled) are removed (or queued for removal) by the garbage collector; so I assume that it is the same here with UnityScript. 2. As syclamoth stated, UnityScript is a unique version of Javascript (though it is closest to using the ECMA Script 4 standard -- the same on that Actionscript 3.0 uses). You can create interfaces though, and it is pretty much exactly the same as in Java. Here is a quick interface example for UnityScript: public interface MyInterface{
   function GetMyName():String;
}
To implement the interface you also do it like in Java: class MyClass inplements MyInterface{
   public function GetMyName():String{
     return "BetaWar";
   }
}
Hopefully that helps.

Viewing all articles
Browse latest Browse all 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>