home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2005 January / Gamestar_69_2005-01_dvd.iso / Dema / theprojectv1-0.exe / FCData / Scripts.pak / Scripts / UIScreens / MainMenu.lua < prev    next >
Encoding:
Text File  |  2004-10-28  |  3.8 KB  |  156 lines

  1.  
  2. -- get the list of videofiles
  3. szScriptFolder = "Scripts/UIScreens/";
  4.  
  5. -- Load Configuration
  6. Script:LoadScript(szScriptFolder.."UISystemCfg.lua", 1);                -- Load Configuration File
  7.  
  8. -- Load the skin
  9. Script:LoadScript(UI.szSkinPath, 1);
  10.  
  11. UI.PageMainMenu=
  12. {    
  13.     GUI=
  14.     {
  15.  
  16. -- ------------------------- Apply -------------------------
  17.  
  18.         --Benchmark =
  19.         --{
  20.         --    classname = "superbutton",
  21.         --    skin = UI.skins.SuperButton,
  22.             
  23.         --    texture     = System:LoadImage("textures/gui/Menu/Menu_unselected.dds"),
  24.         --    overtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  25.         --    texrect     = "0 0 256 64",
  26.         
  27.         --    left = 304, top = 246,
  28.         --    width = 192, height = 48,
  29.         --    text = "",
  30.             
  31.         --    color = "255 255 255 255",
  32.             
  33.         --    tabstop = 11,
  34.             
  35.         --    OnCommand = function(self)
  36.         --        TechDemo:GoToScreen( "Benchmark" );
  37.         --    end,
  38.         --},    
  39.     
  40.         SelfRunning =
  41.         {
  42.             --classname = "superbutton",
  43.             --skin = UI.skins.SuperButton,
  44.             classname = "button",
  45.             skin = UI.skins.ActionButton,
  46.             
  47.             texture     = System:LoadImage("textures/gui/Menu/Menu_unselected.dds"),
  48.             overtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  49.             downtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  50.             --texrect     = "0 0 256 64",
  51.             texrect     = "0 0 256 70",
  52.         
  53.             left = 304, top = 300,
  54.             width = 192, height = 48,
  55.             text = "",
  56.             
  57.             color = "255 255 255 255",
  58.             
  59.             tabstop = 1,
  60.             
  61.             OnCommand = function(self)
  62.                 TechDemo:GoToScreen( "SelfRunning", 1 );
  63.             end,
  64.         },
  65.         
  66.         Options =
  67.         {
  68.             --classname = "superbutton",
  69.             --skin = UI.skins.SuperButton,
  70.             classname = "button",
  71.             skin = UI.skins.ActionButton,
  72.             
  73.             texture     = System:LoadImage("textures/gui/Menu/Menu_unselected.dds"),
  74.             overtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  75.             downtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  76.             --texrect     = "0 64 256 64",
  77.             texrect     = "0 71 256 61",
  78.         
  79.             left = 304, top = 348,
  80.             width = 192, height = 48,
  81.             text = "",
  82.             
  83.             color = "255 255 255 255",
  84.             
  85.             tabstop = 2,
  86.             
  87.             OnCommand = function(self)
  88.                 TechDemo:GoToScreen( "Options" );
  89.             end,
  90.         },
  91.         Credits =
  92.         {
  93.             --classname = "superbutton",
  94.             --skin = UI.skins.SuperButton,
  95.             classname = "button",
  96.             skin = UI.skins.ActionButton,
  97.             
  98.             texture     = System:LoadImage("textures/gui/Menu/Menu_unselected.dds"),
  99.             overtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  100.             downtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  101.             --texrect     = "0 128 256 64",
  102.             texrect     = "0 133 256 61",
  103.         
  104.             left = 304, top = 396,
  105.             width = 192, height = 48,
  106.             text = "",
  107.             
  108.             color = "255 255 255 255",
  109.             
  110.             tabstop = 3,
  111.             
  112.             OnCommand = function(self)
  113.                 TechDemo:GoToScreen( ".." );
  114.                 TechDemo:GoToScreen( "Credits" );
  115.             end,
  116.         },
  117.         Quit =
  118.         {
  119.             --classname = "superbutton",
  120.             --skin = UI.skins.SuperButton,
  121.             classname = "button",
  122.             skin = UI.skins.ActionButton,
  123.             
  124.             texture     = System:LoadImage("textures/gui/Menu/Menu_unselected.dds"),
  125.             overtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  126.             downtexture = System:LoadImage("textures/gui/Menu/Menu_selected.dds"),
  127.             --texrect     = "0 192 256 64",
  128.             texrect     = "0 195 256 60",
  129.         
  130.             left = 304, top = 444,
  131.             width = 192, height = 48,
  132.             text = "",
  133.             
  134.             color = "255 255 255 255",
  135.             
  136.             tabstop = 4,
  137.             
  138.             OnCommand = function(self)
  139.                 TechDemo:Quit();
  140.             end,
  141.         },
  142.         
  143.         
  144.         OnInit = function(self)
  145.         end,    
  146.                     
  147.         OnActivate= function(self) -- this will be called everytime you activate this screen
  148.             --TechDemo:GoToScreen( "SelfRunning", 1 );
  149.         end,
  150.     },
  151. };
  152.  
  153. szScreen = "MainMenu";
  154. UI:CreateScreenFromTable(szScreen, UI.PageMainMenu.GUI);
  155. Script:LoadScript("Scripts/UIScreens/UISystem.lua", 1);
  156.