Brightsign BrightScript 3.0 Reference Manual Manual de usuario Pagina 65

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 75
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 64
60
REM *******************************************************
REM *************** *********************
REM *************** GAME BOARD OBJECT *********************
REM *************** *********************
REM *******************************************************
REM *******************************************************
REM
REM An example BrightScript constructor. "newGameBoard()" is regular Function of module scope
REM BrightScript Objects are "dynamic" and created at runtime. They have no "class".
REM The object container is a BrightScript Component of type roAssocitiveArray (AA).
REM The AA is used to hold member data and member functions.
REM
Function newGameBoard() As Object
game_board=CreateObject("roAssociativeArray") ' Create a BrightScript Component of type/class roAssociativeArray
game_board.Init=gbInit ' Add an entry to the AA of type roFunction with value gbDraw (a sub defined in this
module)
game_board.Draw=gbDraw
game_board.SetSnake=gbSetSnake
game_board.EventLoop=gbEventLoop
game_board.GameOver=gbGameOver
game_board.StartX=gbStartX
game_board.StartY=gbStartY
game_board.Init() ' Call the Init member function (which is gbInit)
return game_board
Vista de pagina 64
1 2 ... 60 61 62 63 64 65 66 67 68 69 70 ... 74 75

Comentarios a estos manuales

Sin comentarios