HowTo/Scenery/mesh-table: Difference between revisions

From TrainzOnline
Jump to navigationJump to search
Glt0145 (talk | contribs)
Glt0145 (talk | contribs)
 
(12 intermediate revisions by the same user not shown)
Line 3: Line 3:
'''This tag is compulsory'''
'''This tag is compulsory'''


The mesh-table a container tag, meaning it is followed by curly brackets. The opening bracket should be on the next line for readability purposes. The closing bracket is best on the next line after the final entry. Again for readability purposes. It can have many sub container tags. I will try and explain these
The mesh-table a container tag, meaning it is followed by curly brackets. The opening bracket should be on the next line for readability purposes. The closing bracket is best on the next line after the final entry. Again for readability purposes. It can have many sub container tags. I will try and explain these. Clicking on each tag will take you to further information on that tag


For a scenery asset a mesh table may look like this.
For a scenery asset a mesh table may look like this.
Line 21: Line 21:
mesh-table
mesh-table
{
{
   default
   [[/default /]]
   {
   {
   [[/mesh/]] industry.lm
   [[/mesh/]] industry.lm
   [[/anim/]] anim.kin
   [[/anim/]] anim.kin
   animation-loop-speed 1.0
   [[/animation-loop-speed/]] 1.0
   auto-create 1
   [[/auto-create/]]
   effects
   [[/effects/]]
     {
     {
     0   
     0   
       {
       {
       kind name
       [[/kind/]] name
       fontsize 0.15
       [[/fontsize/]] 0.15
       fontcolor 30,30,30
       [[/fontcolor/]] 30,30,30
       att a.name0
       [[/att/]] a.name0
       name name
       [[/name/]] name
       }
       }
     1
     1
       {
       {
       kind corona
       [[/kind/]] corona
       att a.coronawhite
       [[/att/]] a.coronawhite
       frequency 1
       [[/frequency/]] 1
       directional 0
       [[/directional/]] 0
       texture-kuid <KUID:-3:10111>
       [[/texture-kuid/]] <KUID:-3:10111>
      [[/object-size/]] 0.15
     }
     }
     }
     }
   }     
   }     
   default-night
   [[/default-night/]]
   {  
   {  
     [[/mesh/]] nightwindows/nightwindows.im
     [[/mesh/]] nightwindows/nightwindows.im
     night-mesh-base default
     [[/night-mesh-base/]] default
   }
   }
  attachedanimation
    {
    [[/mesh/]] subdirectoryname/meshname.im
    anim subdirectoryname/animname.kin
    auto-create 1
    att a.pointname
    att-parent default
    animation-loop-speed 1.0
  }
  }
}
}

Latest revision as of 03:11, 6 February 2022

mesh-table

This tag is compulsory

The mesh-table a container tag, meaning it is followed by curly brackets. The opening bracket should be on the next line for readability purposes. The closing bracket is best on the next line after the final entry. Again for readability purposes. It can have many sub container tags. I will try and explain these. Clicking on each tag will take you to further information on that tag

For a scenery asset a mesh table may look like this.


mesh-table {

default 
 {
  mesh    "a_mesh.trainzmesh"
  auto-create  1
 }

}

A more complex one is show below. This mesh table is for a industry both a day view (default) and a night view (default-night) container whis can be broken down even further into sub containers.

mesh-table {

 default 
 {
  mesh industry.lm
  anim anim.kin
  animation-loop-speed 1.0
  auto-create
  effects
   {
    0  
     {
      kind name
      fontsize 0.15
      fontcolor 30,30,30
      att a.name0
      name name
     }
    1
     {
      kind corona
      att a.coronawhite
      frequency 1
      directional 0
      texture-kuid <KUID:-3:10111>
      object-size 0.15
    }
   }
  }    
  default-night
  { 
   mesh nightwindows/nightwindows.im
   night-mesh-base default
  }
}

}