User Tools

Site Tools


mtr_addon:nte:objschem

Differences

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

Link to this comparison view

Both sides previous revisionPrevious revision
mtr_addon:nte:objschem [2023/06/28 12:59] – Fixed the mistakes between 'texture' and 'material', optimized more contents. jonathanqwqmtr_addon:nte:objschem [2024/02/05 02:43] (current) jonathanqwq
Line 1: Line 1:
 <markdown> <markdown>
-# OBJ model related adaptation+ 
 + 
 + 
 + 
 +# OBJ Importation Guide
  
 NTE makes adding trains based on OBJ models through resource packs come true. NTE makes adding trains based on OBJ models through resource packs come true.
Line 6: Line 10:
 # # Basic Format # # Basic Format
  
-When importing the OBJ train model via NTE, it is written in the mtr_custom_resources.json file and has no difference with using BBMODEL files.+When importing the OBJ train model via NTE, the writing in ```mtr_custom_resources.json``` has no different in using BBMODEL train model.
  
 ```json ```json
Line 23: Line 27:
  
 - `model`: Fill in the location of the OBJ file. Remember to use `mtrsteamloco:......` instead of `D:/......`.  - `model`: Fill in the location of the OBJ file. Remember to use `mtrsteamloco:......` instead of `D:/......`. 
-- `model_properties`: Fill in the resource location of the model property file.  +- `model_properties`: Fill in the location of the model property file.  
-- `texture_id`: Replace the resource position of the map.+- `texture_id`: Fill in the location of the texture file.
  
-The OBJ file you use should meet the following requirements: the positive direction of the X axis is to the right, the positive direction of the Y axis is to the top, and the forward direction of Z axis is backward. Each unit is 1 meter in length+The OBJ file you use should meet the following requirements: the positive direction of the X axis is to the right, the positive direction of the Y axis is to the top, and the forward direction of Z axis is to the back. Each unit'length is 1m.
  
-</markdown> 
-<WRAP center round tip 60%> 
  
-Tip: All file names need to be all lowercase. File names can only be a-z, 0-9, `-`, `_`.+Tip: All file names need to be all lowercase. File names can only include a-z, 0-9, `-`, `_`.
  
-</WRAP> 
  
-<markdown> +# # Sample File
-## Sample File+
  
-A sample resource bundle can be downloaded [here](https://www.zbx1425.cn/nautilus/mtr-nte/assets/mtrnte-example.zip).+A sample resource pack can be downloaded [here](https://www.zbx1425.cn/nautilus/mtr-nte/assets/mtrnte-example.zip).
  
-## Components+# # Components
  
-There can be ** group ** information in OBJ files. For example,the train door and body are in different groups, so that the door can move independently of the body when opening the door by selecting the part to move. OBJ files can be opened by using any text editing software such as Notepad, Notepad3, VSCode, etc. The `mtllib` command sets the MTL file used by this OBJ file, the `g` command sets the grouping, and the `usemtl` command sets correspondence between each face and material. Most modeling software can choose to export grouping information together when exporting OBJ.+There'** group(part) ** information in OBJ files. For example,if the train door and body are in different groups(parts), the door can move independently of the body by selecting the part to move. OBJ files can be opened by using any text editing software (such as Notepad, Notepad3, VSCode, etc). The `mtllib` command sets the MTL file used by this OBJ file, the `g` command sets the grouping, and the `usemtl` command sets correspondence between each  and material. Most modeling software can choose to export grouping information together when exporting OBJ.
  
-Groups in the OBJ model will be automatically parsed and can then be used in the model properties file. This is the same as the use of components in BBMODEL. +Groups in the OBJ model will be automatically parsed and can then be used in the model properties file. This is the same as the use of groups in BBMODEL. 
-</markdown>+ 
 +Tip: Only OBJ grouping (`g`) instructions are supported, object (`o`) instructions are not supported. If the model exported by your modeling software has a line beginning with "o " (with a space after o), please replace it with "g " (with a space after g).
  
-<WRAP center round tip 60%> 
  
-Tip: Only OBJ grouping (`g`) instructions are supported, not object (`o`) instructions. If the model exported by your modeling software has a line beginning with "o " (with a space after o), please replace it with "g " (with a space after g). 
  
-</WRAP> 
  
  
-<markdown> 
 # # Model Properties # # Model Properties
  
-MTR has a ** model attribute ** JSON file, in which you can specify which parts are to be moved when the door is opened, which parts are only displayed in some number of cars, and which parts are only displayed when the door is opened, so as to realize the functions like door opening/closing animation, door lights, head and tail cars displaying head parts, middle cars not displaying head parts, and so on.+MTR has a ** model properties ** JSON file, in which you can specify which parts are to be moved when the door is opened, which parts are only displayed in some number of cars, and which parts are only displayed when the door is opened, so as to realize the functions like door opening/closing animation, door lights, head and tail cars displaying head parts, middle cars not displaying head parts, and so on.
  
-You can edit the model properties file using the ** Resource Bundle Creator ** in MTR mod. In the options of the resource bundle creator, click "Upload" on the right side of "Blockbench File", and then drag in the OBJ file you want to use. If you want to further edit an existing property file, select the property file, otherwise leave it blank.+You can edit the model properties file using the ** Resource Pack Creator ** in MTR mod. In the options of the resource bundle creator, click "Upload" on the right side of "Blockbench File", and then drag in the OBJ file you want to use. If you want to further edit an existing property file, select the property file, otherwise leave it blank.
  
-You can see the OBJ model you uploaded and the parts it contains. You can select any part to create animated doors, and so on. You may find that your OBJ model is white without any maps. This is normal. NTE does not load maps in the Resource Bundle Creator.+You can see the OBJ model you uploaded and the parts it contains. You can select any part to create animated doors, and so on. You may find that your OBJ model is white without any maps. This is normal. NTE does not load texture in the Resource Pac Creator.
  
 ** Please merge the parts in advance, such as merging all the immovable parts into one. The more parts, the worse the performance. ** ** Please merge the parts in advance, such as merging all the immovable parts into one. The more parts, the worse the performance. **
  
 After editing, please select any image as the texture file in the options, and then click "Export Resource Package". You can find the model properties file in the exported archive. It is a JSON file at the same level as a BBMODEL file in an internal folder. After editing, please select any image as the texture file in the options, and then click "Export Resource Package". You can find the model properties file in the exported archive. It is a JSON file at the same level as a BBMODEL file in an internal folder.
 +
 +Tip: The resource bundle exported here can only be used to obtain the model properties file. It is incomplete and cannot be used in Minecraft.
  
 </markdown> </markdown>
-<WRAP center round tip 60%> 
  
-Tip: The resource bundle exported here can only be used to obtain the model properties file. It is incomplete and cannot be used in Minecraft.+<WRAP center round important 60%> 
 + 
 +The following texts are translated by google. Wait to be optimized.
  
 </WRAP> </WRAP>
 +
 <markdown> <markdown>
 +
 +
 +
  
 # # Maps # # Maps
Line 90: Line 94:
  
 </markdown> </markdown>
-<WRAP center round important 60%> 
  
-The following texts are translated by google. Wait to be optimized. 
- 
-</WRAP> 
 <markdown> <markdown>
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
 +
 - If there ** is ** an "mtllib" instruction in the OBJ model, the mapping will be set according to the "map _ Kd" of the corresponding material in the MTL (it is usually set accordingly when MTL is exported using modeling software). If there is a material of'mat1 'in OBJ and'mat1' has a map _ Kd of 1995default.png 'in MTL, the'1995 default. PNG' will be used as a map. At the same time, the'Kd 'and'd' settings in MTL will also be used. - If there ** is ** an "mtllib" instruction in the OBJ model, the mapping will be set according to the "map _ Kd" of the corresponding material in the MTL (it is usually set accordingly when MTL is exported using modeling software). If there is a material of'mat1 'in OBJ and'mat1' has a map _ Kd of 1995default.png 'in MTL, the'1995 default. PNG' will be used as a map. At the same time, the'Kd 'and'd' settings in MTL will also be used.
  
mtr_addon/nte/objschem.1687957175.txt.gz · Last modified: 2023/06/28 12:59 by jonathanqwq