The library file contains a description of one or more materials used in the sm model. One or more material library files with the extension *.sml (SpaceEngine Material Library), located in the default textures folder or in some optional inner subfolder.The model can have no textures, but it must have materials. Texture files are in the common graphics file format jpg, png, tiff, dds, tga. One or more texture files in the folder addons/2001/textures/spacecraft/Odyssey2001/Discovery/ (remember that the Discovery subfolder is optional).The configuration file describes what material each sm model mesh uses, and some other parameters. The cfg file name must match the name of the sm file, and it must be in the same folder. The configuration file with the extension *.cfg for each sm file model.It is possible to import a model from the obj format (look below). The sm file is the binary file with the model's geometry, its description is given below. One or more model files (modules) with the extension *.sm (Spacecraft Model), located in the folder addons/2001/models/spacecraft/Odyssey2001/Discovery/.So, any spaceship in SpaceEngine consists of these files: Furthermore, we assume in this manual that you have created an innermost folder Discovery. But it is important to keep in mind that they affects the paths to the files, which are written to in the scripts. In general, all such subfolders are optional, you decide whether or not to use them. But this is not necessary either, it's just for convenience you may store common textures directly in the addons/2001/textures/spacecraft/Odyssey2001/. If some models use common textures, you may create a folder for them called, for example, common. In our case, it makes sense to create a folder named Discovery, because we are importing the model of this ship:Īddons/2001/models/spacecraft/Odyssey2001/Discovery/ - we will call it a models folderĪddons/2001/textures/spacecraft/Odyssey2001/Discovery/ - we will call it a textures folder For example, a unique named folder for each of the ship types. If your addon may end up having many ship models, for convenience you can create another extra level of folders, although this is not necessary. Now the folder Odyssey2001 should be taken into account when specifying file paths in the ship's script and material files, but this is necessary to avoid ambiguities and overriding files in other addons. For example, create a folder Odyssey2001:Īddons/2001/models/spacecraft/Odyssey2001Īddons/2001/textures/spacecraft/Odyssey2001 To avoid this situation, it is necessary to create additional folders with unique names inside our standard models and textures folders. So if you put your texture or model addons directly into the default location, like this: addons/2001/texture/spacecraft/engine.jpg, it is likely to be overriden by some texture with the same name in another addon, according to the modification date priority rule (or your texture may override another texture in some addon). Important note: all folders with a path which has the form of */models/spacecraft/ (and the same for */textures/spacecraft/) are considered by SpaceEngine as one large virtual folder. So now we need to create two folders called spacecraft:Īddons/2001/models/spacecraft/ - we will call it the standard models folderĪddons/2001/textures/spacecraft/ - we will call it the standard textures folder The models are stored in the addons/2001/models/spacecraft/, and textures in the addons/2001/textures/spacecraft/ folder. The first group is related to the models, the second - to the textures. Therefore, create a new folder in the addons directory: 2001 (we will call it the worker folder), and default SE folders for models and textures inside it:Īny model of the ship, even a single-module one, consists of multiple files, split into two groups. We also assume that this is not the only ship of that franchise that you want to import. Later in this guide we will assume that you are creating a model of the ship Discovery from the "2001: A Space Odyssey" story. If your new model is complex and has repetitive elements, it makes sense to cut it into modules. But the ship may also have a single module (like a Shuttle). Identical modules use the same model (for example, engines or farm element), which saves a lot of video memory. For example, ships made in the SHW editor can have several engines, radiators, tanks, connecting farms, etc. Ships in SpaceEngine may consist of several parts, each of which is represented by a separate model file. Before continuing, it is recommended to read this manual: Introduction.Īll the examples in this tutorial do not uses the pak files, but it is advisable to ensure that your final (release) version of the addon has been packed to a pak file. This tutorial describes how to import a custom ship model into SpaceEngine.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |