Differences

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

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
software:vrgrid:vrffiles [2019/05/12 14:30]
ptsource
software:vrgrid:vrffiles [2019/08/20 12:35] (current)
Line 24: Line 24:
  
   * <​vrf> ​   * <​vrf> ​
-  * <head>  +  * <globals>  
-  * <body+  * <design
   * <​create> ​   * <​create> ​
   * <​action> ​   * <​action> ​
Line 41: Line 41:
  
 Any information bounded in this way will be ignored. Avoid using multiple, consecutive dashes in comments for XML compliance. Any information bounded in this way will be ignored. Avoid using multiple, consecutive dashes in comments for XML compliance.
-The <lib> tag. Specifies which set of libraries (i.e., VRI'S, textures, sounds, 3D models and behaviors) are use to display the VRF. 
 <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​ <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​
 ** Structure **  ** Structure ** 
Line 52: Line 51:
 </​sxh>​ </​sxh>​
  
-The <head> tag. These tags define ​a block of information which appears before the body section. The header acts as it does in HTML, containing ​information that applies to the entire XML code.+The <globals> tag. These tags define information which appears before the design ​section. The globals contains ​information that applies to the entire XML code.
 <sxh xml;> <sxh xml;>
-<head> ... </head>+<globals> ... </globals>
 </​sxh>​ </​sxh>​
  
-The <body> tag. These tags surround the body content of the VRF, including the map itself.+The <design> tag. These tags surround the design ​content of the VRF, including the map itself.
 <sxh xml;> <sxh xml;>
-<body> ... </body>+<design> ... </design>
 </​sxh>​ </​sxh>​
  
 <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​ <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​
-** Head Tags ** +** Globals ​Tags **
 </​alert>​ </​alert>​
-  Tags that can appear in the head of a VRF file+  Tags that can appear in the globals ​of a VRF file
  
-The <debug> tag. Used when building a VRF file. If the <debug> tag is present, error messages are displayed, that will help the author find and correct errors in their VRF file also if the <debug> tag is present the code will be shown using the V key.+The <devel> tag. Used when building a VRF file. If the <devel> tag is present, error messages are displayed, that will help the author find and correct errors in their VRF filealso if the <devel> tag is present the code will be shown using the V key.
 <sxh xml;> <sxh xml;>
-<debug />+<devel />
 </​sxh>​ </​sxh>​
 The <​title>​ tag. The text in the <​title>​ tag is the name of the vrf, and will be displayed in at the bottom of VRGrid. The <​title>​ tag. The text in the <​title>​ tag is the name of the vrf, and will be displayed in at the bottom of VRGrid.
Line 84: Line 83:
 The <map> tag. Dimensions specifies the size of the layers described in the VRF file in units (every unit is the same size, imagine them as wooden cubes placed side-by-side and also stacked to create layers). The <map> tag. Dimensions specifies the size of the layers described in the VRF file in units (every unit is the same size, imagine them as wooden cubes placed side-by-side and also stacked to create layers).
 <sxh xml;> <sxh xml;>
-<map dimensions="​(columns,​rows,​levels)" />+<map dimensions="​(columns,​rows,​layers)" />
 </​sxh>​ </​sxh>​
 The <sky> tag. Uses the given texture file (GIF, JPEG or VRI) as the tiled texture for the sky or enclosure. Alternately,​ a color can be specified to appear in the sky or enclosure, instead of a texture. The brightness parameter sets the light on the sky or enclosure image between 0 and 100 percent (default is 100%). The <sky> tag. Uses the given texture file (GIF, JPEG or VRI) as the tiled texture for the sky or enclosure. Alternately,​ a color can be specified to appear in the sky or enclosure, instead of a texture. The brightness parameter sets the light on the sky or enclosure image between 0 and 100 percent (default is 100%).
Line 101: Line 100:
 <ground texture="​folder/​image.vri -or- URL" color="​(red,​green,​blue)"​ /> <ground texture="​folder/​image.vri -or- URL" color="​(red,​green,​blue)"​ />
 </​sxh>​ </​sxh>​
-The <ambient_light> tag. Sets the ambient ​light level and color for the entire VRF. Default is 100% brightness, and white light.+The <atmosphere> tag. Sets the atmosphere ​light level and color for the entire VRF. Default is 100% brightness, and white light.
 <sxh xml;> <sxh xml;>
-<ambient_light ​brightness="​brightness%"​ color="​(red,​green,​blue)"​ />+<atmosphere ​brightness="​brightness%"​ color="​(red,​green,​blue)"​ />
 </​sxh>​ </​sxh>​
 The <orb> tag. Sets an image to be displayed in the sky such as a sun or moon. Also defines a source position for a directional light that shines from the orb over the entire VRF, and the brightness and color of that light. Href defines a link to a URL and text defines what text will be displayed on mouse roll-over. The <orb> tag. Sets an image to be displayed in the sky such as a sun or moon. Also defines a source position for a directional light that shines from the orb over the entire VRF, and the brightness and color of that light. Href defines a link to a URL and text defines what text will be displayed on mouse roll-over.
Line 111: Line 110:
 href="​url"​ target="​target frame" text="​text"​ /> href="​url"​ target="​target frame" text="​text"​ />
 </​sxh>​ </​sxh>​
-The <ambient_sound> tag. Uses the given WAV file as the ambient ​sound of the entire VRF. The volume of the sound can be between 0 and 100 percent (default is 100%). The sound can either be played once, looped, or played at random intervals. If playback="​random",​ you can specify a range of times in between playbacks. Delay times are measured in seconds, and from the beginning of the sound, rather than+The <ambience> tag. Uses the given WAV file as the ambience ​sound of the entire VRF. The volume of the sound can be between 0 and 100 percent (default is 100%). The sound can either be played once, looped, or played at random intervals. If playback="​random",​ you can specify a range of times in between playbacks. Delay times are measured in seconds, and from the beginning of the sound, rather than
 the end. the end.
 <sxh xml;> <sxh xml;>
-<ambient_sound ​file="​folder/​sound.wav -or- URL" volume="​volume%" ​+<ambience ​file="​folder/​sound.wav -or- URL" volume="​volume%" ​
 playback="​looped|random|once"​ delay="​minimum..maximum"​ /> playback="​looped|random|once"​ delay="​minimum..maximum"​ />
 </​sxh>​ </​sxh>​
Line 132: Line 131:
 <sxh xml;> <sxh xml;>
 <font name="​name-of-font"/>​ <font name="​name-of-font"/>​
 +</​sxh>​
 +The <​scope>​ tag. The scope tag changes the cursors in all the VRF to a scope. This can be usefull for some designs.
 +<sxh xml;>
 +<​scope/>​
 </​sxh>​ </​sxh>​
  
 <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​ <alert type="​information"​ icon="​glyphicon glyphicon-info-sign"​ dismiss="​false">​
-** Body Tags ** +** Design ​Tags **
 </​alert>​ </​alert>​
-  Tags that can appear in the body of a VRF file+  Tags that can appear in the design ​of a VRF file
   ​   ​
-The <​create>​ tag. Every 3D object is assigned a double ASCII character as a symbol. For instance, let´s say a full 3D object is assigned to the "##"​ character. So when you make a wall on the map you might type ## ## ## ## ##  which is a wall that is five units wide. The <​create>​ tag allows you to change the textures applied to a 3D object and change some other features of the 3D object, such as the orientation,​ the lighting (brightness,​ radius, and color) or the sound (WAV file, volume, radius and playback mode).+The <​create>​ tag. Every 3D object is assigned a double ASCII character as a unit. For instance, let´s say a full 3D object is assigned to the "##"​ character. So when you make a wall on the map you might type ## ## ## ## ##  which is a wall that is five units wide. The <​create>​ tag allows you to change the textures applied to a 3D object and change some other features of the 3D object, such as the orientation,​ the lighting (brightness,​ radius, and color) or the sound (WAV file, volume, radius and playback mode).
 <sxh xml;> <sxh xml;>
-<​create ​symbol="symbol" ​block="symbol-or-3dobject-name">+<​create ​unit="unit" ​vrobj="libraryused:​3dobjectname">
 ... ...
 </​create>​ </​create>​
Line 147: Line 150:
 Below is an example of a <​create>​ tag with all of the possible attributes: Below is an example of a <​create>​ tag with all of the possible attributes:
 <sxh xml;> <sxh xml;>
-<​create ​symbol="symbol" ​block="symbol-or-block-name">+<​create ​unit="unit" ​vrobj="libraryused:​3dobjectname">
 <param orient="​up|down|north|south|east|west,​0|90|180|270"​ <param orient="​up|down|north|south|east|west,​0|90|180|270"​
 solid="​yes|no"​ walkable="​yes|no"​ origin="​(x,​y,​z)"​ /> solid="​yes|no"​ walkable="​yes|no"​ origin="​(x,​y,​z)"​ />
-<part name="​name"​ texture="​folder/​image.vri -or- URL"+<side name="​name"​ texture="​folder/​image.vri -or- URL"
 angle="​0-359"​ color="​(red,​green,​blue)"​ angle="​0-359"​ color="​(red,​green,​blue)"​
-translucency="translucency%"+clarity="clarity%"
 style="​tiled|scaled|stretched"​ style="​tiled|scaled|stretched"​
 projection="​top|bottom|north|south|east|west"​ projection="​top|bottom|north|south|east|west"​
Line 159: Line 162:
 </​create>​ </​create>​
 </​sxh>​ </​sxh>​
-The <​create>​ tag can also include any or all of the the following tags: <entrance>, <​exit>,<​popup>,​ <​point_light>,​ <​vrf_light>,​ <​sound>,​ <​action>,​ <​define>,​ and <​script>​. When used inside the <​create>​ tag, these tags use the same syntax that they use on their own, except that they don't take a location attribute. Avoid using < or & in your block symbols for XML compliance.+The <​create>​ tag can also include any or all of the the following tags: <enter>, <​exit>,<​popup>,​ <​point_light>,​ <​vrf_light>,​ <​sound>,​ <​action>,​ <​define>,​ and <​script>​. When used inside the <​create>​ tag, these tags use the same syntax that they use on their own, except that they don't take a location attribute. Avoid using < or & in your vrobj symbols for XML compliance.
  
 The <​define>​ tag. The <​define>​ tag is used to define script variables and functions in your VRF. See Scripting for more details. The <​define>​ tag. The <​define>​ tag is used to define script variables and functions in your VRF. See Scripting for more details.
Line 167: Line 170:
 </​define>​ </​define>​
 </​sxh>​ </​sxh>​
- The <​import>​ tag. The <​import>​ tag makes VRGrid insert the contents of the specified file into the VRF file. This can be useful for sharing common elements between VRF´S. The <​import>​ tag can be used anywhere in the body of a VRF, except inside of <​layer>,​ <​define>,​ <​action>,​ or <​script>​ tags. The imported VRF file must start with <​import>​ and end with </​import>​.+ The <​import>​ tag. The <​import>​ tag makes VRGrid insert the contents of the specified file into the VRF file. This can be useful for sharing common elements between VRF´S. The <​import>​ tag can be used anywhere in the design ​of a VRF, except inside of <​layer>,​ <​define>,​ <​action>,​ or <​script>​ tags. The imported VRF file must start with <​import>​ and end with </​import>​.
 <sxh xml;> <sxh xml;>
 <import href="​folder/​file.vrf"​ /> <import href="​folder/​file.vrf"​ />
 </​sxh>​ </​sxh>​
 The <​layer>​ tag. Defines the two dimensional map for one floor layer of a VRF. Between the tags, all letters are interpreted as building units for rendering the VRF. The map must be written as a rectangle of characters with all rows equal in length. There is a one-to-one correspondence between the symbol positions in the map and the placement of the 3D objects in the resulting VRF. The number attribute The <​layer>​ tag. Defines the two dimensional map for one floor layer of a VRF. Between the tags, all letters are interpreted as building units for rendering the VRF. The map must be written as a rectangle of characters with all rows equal in length. There is a one-to-one correspondence between the symbol positions in the map and the placement of the 3D objects in the resulting VRF. The number attribute
-is optional. It is expected in general that each consecutive level defines a higher floor layer of the VRF.+is required the name attribute ​is optional. It is expected in general that each consecutive level defines a higher floor layer of the VRF.
 <sxh xml;> <sxh xml;>
-<layer number="​number">​ +<layer number="​number" name="​name">​ 
-...rows of unit symbols...+...rows of units...
 </​layer>​ </​layer>​
 </​sxh>​ </​sxh>​
-The <entrance> tag. Defines a location where viewers can hyperlink into the VRF from another VRF or webpage. More than one may be defined in a single VRF. There must be at least one entrance ​named "​default"​ in every VRF file. Angle defines what direction the viewer will be facing when entering through this entrance ​(0 to 359 degrees with 0 equal to north, and -90 to 90 degrees to determine whether is looking up or down.) The <entrance> tag can be placed anywhere within the body. It is usually placed at the end of the body, after all of the layers have been defined. An entrance ​can also be assigned to a +The <enter> tag. Defines a location where viewers can hyperlink into the VRF from another VRF or webpage. More than one may be defined in a single VRF. There must be at least one enter named "​default"​ in every VRF file. Angle defines what direction the viewer will be facing when entering through this enter (0 to 359 degrees with 0 equal to north, and -90 to 90 degrees to determine whether is looking up or down.) The <enter> tag can be placed anywhere within the design. It is usually placed at the end of the design, after all of the layers have been defined. An enter can also be assigned to a 3D object by placing it inside the <​create>​ tag. It does not take a location attribute if it is placed in the <​create>​ tag.
-3D object by placing it inside the <​create>​ tag. It does not take a location attribute if it is placed in the <​create>​ tag.+
 <sxh xml;> <sxh xml;>
-<entrance ​location="​(column,​row,​level)" name="​name"​ angle="​0-359,​-90-90"​ />+<enter location="​(column,​row,​layer)" name="​name"​ angle="​0-359,​-90-90"​ />
 </​sxh>​ </​sxh>​
  
-The <​exit>​ tag. A hyperlink to another VRF file. Location defines where in the VRF the link will be placed. The href gives the filename or URL of the destination VRF or other file, with an optional ​entrance ​name (if omitted the "​default" ​entrance ​will be used). The trigger attribute defines how the link can be activated, either by clicking on it, stepping on it, or both. The text attribute defines the text that will be displayed when the mouse rolls over the link. Like the <entrance> tag, the <​exit>​ tag can also be assigned to a 3D object by including it in the <​create>​ tag, or it can be placed in the body on its own, usually at the end of the body or immediately following the layer in which it occurs.+The <​exit>​ tag. A hyperlink to another VRF file. Location defines where in the VRF the link will be placed. The href gives the filename or URL of the destination VRF or other file, with an optional ​enter name (if omitted the "​default" ​enter will be used). The trigger attribute defines how the link can be activated, either by clicking on it, stepping on it, or both. The text attribute defines the text that will be displayed when the mouse rolls over the link. Like the <enter> tag, the <​exit>​ tag can also be assigned to a 3D object by including it in the <​create>​ tag, or it can be placed in the design ​on its own, usually at the end of the design ​or immediately following the layer in which it occurs.
 <sxh xml;> <sxh xml;>
-<exit location="​(column,​row,​level)" +<exit location="​(column,​row,​layer)" 
-href="​folder/​desitination.vrf#​entrance-name"+href="​folder/​desitination.vrf#​enter-name"
 trigger="​click on|step on" text="​text"/>​ trigger="​click on|step on" text="​text"/>​
 </​sxh>​ </​sxh>​
  
-The <​action>​ tag. Defines an action which takes place as a response to a particular trigger. Radius used only for trigger="​step in" or "step out". Delay is only used for trigger="​timer"​. Delay is measured in seconds. If only one delay value is specified, the delay time will remain consistent. If delay is expressed as a range from minimum to maximum times, the delay will be random within those parameters. ​ Action tags can stand alone in the body of the VRF file, or they can be attached to 3D objects inside the <​create>​ tag. Action can also be used in an imagemap with the additional attributes of shape="​rect|circle"​ and coords="​x1,​y1,​x2,​y2|x,​y,​radius"​.+The <​action>​ tag. Defines an action which takes place as a response to a particular trigger. Radius used only for trigger="​step in" or "step out". Delay is only used for trigger="​timer"​. Delay is measured in seconds. If only one delay value is specified, the delay time will remain consistent. If delay is expressed as a range from minimum to maximum times, the delay will be random within those parameters. ​ Action tags can stand alone in the design ​of the VRF file, or they can be attached to 3D objects inside the <​create>​ tag. Action can also be used in an imagemap with the additional attributes of shape="​rect|circle"​ and coords="​x1,​y1,​x2,​y2|x,​y,​radius"​.
 <sxh xml;> <sxh xml;>
-<action location="​(column,​row,​level)"+<action location="​(column,​row,​layer)"
 trigger="​roll on|roll off|click on|step in| trigger="​roll on|roll off|click on|step in|
 step out|proximity|timer|location|key down| step out|proximity|timer|location|key down|
Line 202: Line 204:
 </​sxh>​ </​sxh>​
  
-The <​popup>​ tag . Popups are 2D images that get displayed on the screen when the user travels within the radius of the location defined. This 2D image can be a texture (animated or still) or a color. The position and size of the popup image on the screen can be specified. Text can also appear on a popup, with a given alignment color and custom font specified with the head font tag. When text is placed over a texture, the color attribute will define the color of a drop-shadow to make the text more legible. Finally, the brightness of the entire popup can be specified. Popups can be assigned to a location in the map in the body section, or they can be assigned to a specific 3D object in the <​create>​ tag. If used in the <​create>​ tag, the location attribute is not needed. If used in the body, and no location attribute is defined, then the popup will display throughout the entire VRF.+The <​popup>​ tag . Popups are 2D images that get displayed on the screen when the user travels within the radius of the location defined. This 2D image can be a texture (animated or still) or a color. The position and size of the popup image on the screen can be specified. Text can also appear on a popup, with a given alignment color and custom font specified with the globals ​font tag. When text is placed over a texture, the color attribute will define the color of a drop-shadow to make the text more legible. Finally, the brightness of the entire popup can be specified. Popups can be assigned to a location in the map in the design ​section, or they can be assigned to a specific 3D object in the <​create>​ tag. If used in the <​create>​ tag, the location attribute is not needed. If used in the design, and no location attribute is defined, then the popup will display throughout the entire VRF.
 <sxh xml;> <sxh xml;>
-<popup location="​(column,​row,​level)"+<popup location="​(column,​row,​layer)"
 trigger="​rollover|proximity|everywhere"​ trigger="​rollover|proximity|everywhere"​
 radius="​number-of-units"​ radius="​number-of-units"​
Line 241: Line 243:
 <sxh xml;> <sxh xml;>
 <sound file="​folder/​sound.wav-or-url"​ name="​sound name" <sound file="​folder/​sound.wav-or-url"​ name="​sound name"
-location="​(column,​row,​level)"+location="​(column,​row,​layer)"
 volume="​volume%"​ playback="​looped|random|once|single"​ volume="​volume%"​ playback="​looped|random|once|single"​
 delay="​minimum..maximum"​ radius="​number_of_units"​ delay="​minimum..maximum"​ radius="​number_of_units"​
Line 247: Line 249:
 </​sxh>​ </​sxh>​
  
-The <​point_light>​ tag. Defines a light at a specific location in the map that shines in all directions. Location refers to the placement of the light in the map or layer. Position refers to the position of the light within the 256-pixel unitspace. Flood="​yes"​ will cause the light to fill the radius at the specified brightness. Flood="​no"​ will create a light that is the specified brightness at the center, and gradually drops off to the ambient_light ​level at the far end of the radius. The default value is flood="​no"​. Lights can also be assigned to specific 3D objects within the <​create>​ tag. If used in the <​create>​ tag, the location attribute is not necessary.+The <​point_light>​ tag. Defines a light at a specific location in the map that shines in all directions. Location refers to the placement of the light in the map or layer. Position refers to the position of the light within the 256-pixel unitspace. Flood="​yes"​ will cause the light to fill the radius at the specified brightness. Flood="​no"​ will create a light that is the specified brightness at the center, and gradually drops off to the atmosphere light level at the far end of the radius. The default value is flood="​no"​. Lights can also be assigned to specific 3D objects within the <​create>​ tag. If used in the <​create>​ tag, the location attribute is not necessary.
 <sxh xml;> <sxh xml;>
-<​point_light style="​static|pulsate"​ location="​(column,​row,​level)"+<​point_light style="​static|pulsate"​ location="​(column,​row,​layer)"
 position="​(x,​y,​z)"​ brightness="​n%"​ radius="​number_of_units"​ position="​(x,​y,​z)"​ brightness="​n%"​ radius="​number_of_units"​
 flood="​yes|no"​ color="​(red,​green,​blue)"​ name="​light name" ​ flood="​yes|no"​ color="​(red,​green,​blue)"​ name="​light name" ​
Line 257: Line 259:
 The <​vrf_light>​ tag .Defines a vrf_light at a specified location that shines in a specified direction. Direction is expressed as a pair of angles. The turn angle describes a direction in the horizontal plane, from 0 to 359 degrees, with 0 being north. The tilt angle describes a direction in the vertical plane, from -90 to 90 degrees, with 90 pointing straight up, 0 pointing at the horizon, and -90 pointing straight down. The cone describes how wide the light is in degrees. The <​vrf_light>​ tag .Defines a vrf_light at a specified location that shines in a specified direction. Direction is expressed as a pair of angles. The turn angle describes a direction in the horizontal plane, from 0 to 359 degrees, with 0 being north. The tilt angle describes a direction in the vertical plane, from -90 to 90 degrees, with 90 pointing straight up, 0 pointing at the horizon, and -90 pointing straight down. The cone describes how wide the light is in degrees.
 <sxh xml;> <sxh xml;>
-<​vrf_light style="​static|search|revolve"​ location="​(column,​row,​level)"+<​vrf_light style="​static|search|revolve"​ location="​(column,​row,​layer)"
 position="​(x,​y,​z)"​ brightness="​n%"​ radius="​number_of_units"​ position="​(x,​y,​z)"​ brightness="​n%"​ radius="​number_of_units"​
 flood="​yes|no"​ color="​(red,​green,​blue)"​ flood="​yes|no"​ color="​(red,​green,​blue)"​
Line 278: Line 280:
 fast_mode="​[ctrl]",​ go_faster="​[pad +]", and go_slower="​[pad -]". fast_mode="​[ctrl]",​ go_faster="​[pad +]", and go_slower="​[pad -]".
 <sxh xml;> <sxh xml;>
-<player size="​(x,​y,​z)"​ camera="​(x,​y,​z)" ​block="3D object name"+<player size="​(x,​y,​z)"​ camera="​(x,​y,​z)" ​vrobj="unit"
 move_forward="​key"​ move_back="​key"​ move_forward="​key"​ move_back="​key"​
 move_left="​key"​ move_right="​key"​ move_left="​key"​ move_right="​key"​