Changes

Jump to navigation Jump to search
42 bytes added ,  15:04, 5 March 2020
Line 14: Line 14:  
Each furniture should be defined in separate  [[TyD|TyD]] files.
 
Each furniture should be defined in separate  [[TyD|TyD]] files.
   −
The Furniture table should have a '''Thumbnail''' record with a relative path to a 128x128 thumbnail to use in-game.
+
The root table should have a '''Thumbnail''' record with a relative path to a 128x128 thumbnail to use in-game.
   −
The Furniture table can also have a '''Base''' record to inherit from an existing furniture from the game. If you define the record '''AutoBounds True''', the game will auto generate the navigation mesh, building boundary, vertical span, x and y grid offset, width and vertical offset for wall furniture, and collision box for selection, based on the furniture meshes, otherwise these can be controlled in the Furniture component by setting the variables BuildBoundary, NavBoundary, Height1, Height2, OnXEdge, OnYEdge, WallWidth, YOffset and the BoxCollider component.
+
The root table can also have a '''Base''' record to inherit from an existing furniture from the game. If you define the record '''AutoBounds True''', the game will auto generate the navigation mesh, building boundary, vertical span, x and y grid offset, width and vertical offset for wall furniture, and collision box for selection, based on the furniture meshes, otherwise these can be controlled in the Furniture component by setting the variables BuildBoundary, NavBoundary, Height1, Height2, OnXEdge, OnYEdge, WallWidth, YOffset and the BoxCollider component.
    
You can check your build and navigation boundary, and interaction and snap points by enabling furniture debugging using the command '''FURNITURE_DEBUG True''' in the console and selecting the furniture you want to review in-game. The navigation boundary is located on the floor and goes from green to pink. The build boundary also illustrates Height1 and Height2 and goes from cyan to red. Interaction points are blue and snap points are yellow:
 
You can check your build and navigation boundary, and interaction and snap points by enabling furniture debugging using the command '''FURNITURE_DEBUG True''' in the console and selecting the furniture you want to review in-game. The navigation boundary is located on the floor and goes from green to pink. The build boundary also illustrates Height1 and Height2 and goes from cyan to red. Interaction points are blue and snap points are yellow:
Line 32: Line 32:     
=== Naming your furniture ===
 
=== Naming your furniture ===
Your furniture will take its name from the filename. As of Alpha 11.4.10, this name should be considered an ID and not what the player will see, so you should try and make it as unique as possible, to avoid clashing with vanilla furniture or furniture from other mods. To name your furniture in the UI use the '''LocalizedName''' variable in the '''Furniture''' table and use the '''GENERATE_LOCALIZATION your_mod_name''' console command to generate the localization files for your mod. To find your furniture's name in the UI, the game will lookup your mods ID/filename and return the LocalizedName that has been exported with the GENERATE_LOCALIZATION command. This has the added benefit of allowing people to translate your mod to other languages.
+
Your furniture will take its name from the filename. As of Alpha 11.4.10, this name should be considered an ID and not what the player will see, so you should try and make it as unique as possible, to avoid clashing with vanilla furniture or furniture from other mods. To name your furniture in the UI use the '''LocalizedName''' variable in the '''Furniture''' component table([[Furniture_Modding#Furniture|See here]]) and use the '''GENERATE_LOCALIZATION your_mod_name''' console command to generate the localization files for your mod. To find your furniture's name in the UI, the game will lookup your mods ID/filename and return the LocalizedName that has been exported with the GENERATE_LOCALIZATION command. This has the added benefit of allowing people to translate your mod to other languages.
    
=== Meshes and materials ===
 
=== Meshes and materials ===

Navigation menu