Lexical structure

From Unify Community Wiki
(Difference between revisions)
Jump to: navigation, search
(New page: == Scripts == Javascript for Unity is written inside of one or more script files. Each of these script files contains at least one class definition which must have the same name as the fi...)

Revision as of 00:31, 3 June 2009

Scripts

Javascript for Unity is written inside of one or more script files. Each of these script files contains at least one class definition which must have the same name as the file, e.g. MyJavascript.js will contain the definition for the MyJavascript class. If no class is explicitly created, then Unity will automatically create a class with the correct name, and anything found inside of that file will be made a member of that class.

Tokens

Keywords

Keyword is an identifier-like sequence of characters that is reserved.

Keyword : one of

  • as
  • boolean
  • break
  • byte
  • case
  • char
  • class
  • continue
  • default
  • double
  • else
  • enum
  • false
  • float
  • for
  • if
  • in
  • int
  • long
  • new
  • null
  • private
  • protected
  • public
  • return
  • sbyte
  • static
  • string
  • super
  • switch
  • this
  • true
  • typeof
  • uint
  • ulong
  • ushort
  • virtual
  • void
  • while
Personal tools
Namespaces

Variants
Actions
Navigation
Extras
Toolbox