User Tools

Site Tools


scripting:reference:scriptedosd

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
scripting:reference:scriptedosd [2020/01/28 17:50] – external edit 127.0.0.1scripting:reference:scriptedosd [2023/05/15 03:53] (current) – [OSDText / OSDTextRight / OSDTextCenter] mit
Line 21: Line 21:
 - OSDLOWER\\ - OSDLOWER\\
 - OSDTUTORIAL\\ - OSDTUTORIAL\\
-OSDNOTIFICATION\\+OSDNOTIFICATION1 .. OSDNOTIFICATION6\\
 - OSDSPEC\\ - OSDSPEC\\
 - OSDSPECLOWER \\ - OSDSPECLOWER \\
Line 27: Line 27:
 - OSDSCRIPTEDBUILDING \\ - OSDSCRIPTEDBUILDING \\
  
-''OSDWINDOW'' is used a background window is created 400x300, in the center of the screen. With ''OSDBUILDING'', the OSD is displayed within the region of the building access window.+Each type has a different default setup and use case, e.g. ''OSDWINDOW'' creates 400x300 background window positioned in the center of the screen. For ''OSDBUILDING'', the OSD is displayed within the region of the building access window. See [OSD Types Reference] for details of each type.
  
 +==== OSDText / OSDTextRight / OSDTextCenter ====
 +^ Parameters | ''[TEXTYPE]'', X, Y, ''Text'' |
 +^ Example | ''OSDText( SMALL, 100, 100, "Hello World" )'' |
 +^ Description | Adds text to an OSD at the specified coordinate.  |
 +Note TEXTTYPE can be ommitted (text defaults to 'NORMAL') so  OSDText( 10, 10, "Hello" ) is valid. 
 +Full list of supported types below..
  
-==== OSDAddItem ====+==== OSDAdd ==== 
 +^ Parameters | ''OSD_ITEMTYPE'', X, Y, W, H, ''Name'', ''Title''
 +^ Example | ''OsdAdd( BUTTON, 100, 100, 200, 20, "Option1", "Press me" )''
 +^ Description | Adds individual elements to an OSD at a specific location. 
 + 
 +==== OSDAddAuto ====
 ^ Parameters | ''OSD_ITEMTYPE'', ''Name'', ''Text'' ^ Parameters | ''OSD_ITEMTYPE'', ''Name'', ''Text''
-^ Example | ''OsdAddItem( IMAGE, "", "http://myweb.com/image.jpg" )''+^ Example | ''OsdAddAuto( IMAGE, "", "http://myweb.com/image.jpg" )''
-^ Description | This is a basic function to add an OSD item to the screen. Each item appears below any previously added items. If you want more control of the layout of your OSD then you would use the OSDAddAt command.. |  +^ Description | This is a basic function to add an OSD item to the screen. Each item appears below any previously added items. If you want more control of the layout of your OSD then you would use the OSDAdd command. | 
-==== OSDAddAt ==== +
-Parameters :  ''OSD_ITEMTYPE'', X, Y, W, H, ''Name'', ''Title'' \\ +
-Example : ''OsdAddAt(OSDBUTTON, 100, 100, 200, 20, "Option1", "Press me" )'' \\ +
-Description :+
    
 ==== OSDSet ==== ==== OSDSet ====
Line 49: Line 56:
 osdcreate( OSDLOWER, "Help", "Help Guide" ) osdcreate( OSDLOWER, "Help", "Help Guide" )
 osdset( "BlockEscape" ) osdset( "BlockEscape" )
-osdaddat( TEXT, 100,0, 400, 100, "", "Welcome to my world, press the button to start" ) +osdadd( TEXT, 100,0, 400, 100, "", "Welcome to my world, press the button to start" ) 
-osdaddat( BUTTON, 200, 70, 200, 35, "", "Start Game" )+osdadd( BUTTON, 200, 70, 200, 35, "", "Start Game" )
 osdactivate() osdactivate()
 </code> </code>
Line 59: Line 66:
 Description : Triggers the actual transmission of the OSD layout to the client. Description : Triggers the actual transmission of the OSD layout to the client.
  
 +==== sysGetTextEntry====
 +Parameters : None
 +Example : ''$text = sysGetTextEntry()'' \\
 +Description : Related but separate from the OSD functions, this call is used in an OSDSelect event to retrieve the text the user entered in a TEXTENTRY box.\\
  
-===== ScriptedOSD Item Types ===== 
  
-==== Text Types ==== + 
-Text can be added to your OSD using various text types, that specify the size, alignment and colour of the text to be displayed. +===== ScriptedOSD Item Types =====
-Valid text types are as follows :\\ +
-  * TEXT +
-  * BIGTEXT +
-  * FADEDTEXT +
-  * SMALLTEXT +
-  * TEXTRIGHT +
-  * SMALLTEXTRIGHT +
-  * BIGTEXTRIGHT +
-  * BOLDTEXT +
-  * SMALLFADEDTEXT (or FADEDSMALLTEXT) +
-  * BIGFADEDTEXT +
-  * WARNINGTEXT +
-  * BIGWARNINGTEXT +
-  * TEXT2 +
-  * FADEDTEXT2 +
-  * TEXT2RIGHT +
-  * GIANTTEXT +
-  * GIANTTEXTRIGHT +
-  * GIANTFADEDTEXT +
-  * BLINKINGWARNINGTEXT +
-  * BULLET+
  
 ==== Button Types ==== ==== Button Types ====
Line 105: Line 94:
   * LINE   * LINE
   * BOX   * BOX
 +  * LAYERRECT 
 +  * COUNTDOWN
 ==== User Input Types ==== ==== User Input Types ====
  
Line 111: Line 101:
   * VALUE   * VALUE
   * CASHVALUE   * CASHVALUE
 +  * EXITIMAGE
 +  * SLIDER
 +  * AMOUNTPRICEVALUECONTROL
  
 ==== Display Control Types ==== ==== Display Control Types ====
Line 122: Line 115:
   * LISTBUTTON    * LISTBUTTON 
   * DATE   * DATE
 +
 +===== ScriptedOSD Text Types =====
 +
 +Text can be added to your OSD using various text types, that specify the size and colour of the text to be displayed.
 +If the text type is ommitted, standard text formatting will be used, otherwise valid text types are as follows :\\
 +
 +  * BIG
 +  * FADED
 +  * SMALL
 +  * BOLD
 +  * SMALLFADED
 +  * BIGFADED
 +  * WARNING
 +  * BIGWARNING
 +  * FONT2
 +  * FADEDFONT2
 +  * GIANT
 +  * GIANTFADED
 +  * BLINKINGWARNING
 +  * BULLET
 +  * GOLD
 +  * SILVER
 +  * BRONZE
 +  * BIGGOLD
 +  * BIGSILVER
 +  * BIGBRONZE
 +
  
scripting/reference/scriptedosd.1580255413.txt.gz · Last modified: 2020/01/28 17:50 by 127.0.0.1

Except where otherwise noted, content on this wiki is licensed under the following license: Public Domain
Public Domain Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki