Tutorial - Importing Custom objects
Posted: Fri Jun 20, 2008 11:02 pm
(please sticky)
Ok, this is the second installment that goes along with "Creating Custom Objects". If you followed the first tutorial then you should already have a banner.jm, or whatever you called it, and a wireframe. (a .tga file)
If you haven't opened this file in photoshop, or an equivalent editing program, do so and skin it however you would like. You also need a collision file for the object. This is coming in the next tutorial. The collision file is not the most important right now though because if you hit a banner in real life, you don't bounce off of it, you would go through it.
If you already have your intended object, say wakestyle's ama stake, then follow along, making minor adjustments when needed.
The first thing that I like to do when putting custom objects into a track is to make three seperate folders within my track folder which is located at c:users/"name"/AppData/Local/MX Simulator/"Track". These three folders being "models", "skins", and "collision". The reason for creating these folders is to keep everything for that track nice and organized. When you find that you have to edit something it makes it much easier to do so. This also requires hardly any effort on the coding side to do it.
Some things to remember:
1. Your track name folder located at c:users/"name"/AppData/Local/MX Simulator/"Track" should not contain any capital letters or spaces. This tends to throw off the game when reading objects.
2. To be safe, you shouldn't name your objects or skins with any capital letters or spaces also
3. Your skin has to be a .png and make sure it is .png not .PNG
4. Your model has to be a .JM file
5. Your collision file has to be just a regular file file
Let's do it!
1. Place your "object name".jm into the models folder within the track folder
2. Place your "skin name".png into the skins folder within the track folder
3. If you have a collision file place it into your collision folder. If you don't have a collision file don't worry about it.
4. Right click the statues folder with your track folder, open it with notepad or notepad++ (preferred)
5. At the very end of the text, add another line. This is where you input the values for your object.
They are
[1000.000000 0.000000 1000.000000] - These are the coordinates for your object. X Y Z. the X and Z coordinates are where the object is placed on the map. The Y coordinate is the distance of the objects center from the ground. 0,000000 is placed on the ground. The reason I place it a 1000 0 1000 is because that just gets it into the game. Once it's in the game it is very easy to move and rotate by just clicking on the statues tab on the left side of the screen, and then clicking and dragging or rotating the little black icon in the center of the object.
0.000000 - This is the rotation of the object in radians. You can change this in the game much easier.
@"trackname"/models/banner.jm - this is the path for the object file
@"trackname"/skins/banner.png - this is the path for the skin file
@"trackname"/collision/banner.shp - this is the path for the collision file
The actual setup is this:
[1000.000000 0.000000 1000.000000] 0.000000 @redbud10/models/banner.jm
@redbud10/skins/banner.png @"trackname"/collision/banner.shp
*If you have subfolders for your models, skins, collision, etc, you cannot saf the track. It must be left open.
If you do not have a collision file it can be written:
[1000.000000 0.000000 1000.000000] 0.000000 @"trackname"/models/banner.jm
@"trackname"/skins/banner.png null
At the bottom of the file make sure you have at least one space. I don't know why this is but it is just finicky.
Hope this helps, now that you can make your own objects, and get them into the game, you can start placing it and making your tracks look sweet!
Ok, this is the second installment that goes along with "Creating Custom Objects". If you followed the first tutorial then you should already have a banner.jm, or whatever you called it, and a wireframe. (a .tga file)
If you haven't opened this file in photoshop, or an equivalent editing program, do so and skin it however you would like. You also need a collision file for the object. This is coming in the next tutorial. The collision file is not the most important right now though because if you hit a banner in real life, you don't bounce off of it, you would go through it.
If you already have your intended object, say wakestyle's ama stake, then follow along, making minor adjustments when needed.
The first thing that I like to do when putting custom objects into a track is to make three seperate folders within my track folder which is located at c:users/"name"/AppData/Local/MX Simulator/"Track". These three folders being "models", "skins", and "collision". The reason for creating these folders is to keep everything for that track nice and organized. When you find that you have to edit something it makes it much easier to do so. This also requires hardly any effort on the coding side to do it.
Some things to remember:
1. Your track name folder located at c:users/"name"/AppData/Local/MX Simulator/"Track" should not contain any capital letters or spaces. This tends to throw off the game when reading objects.
2. To be safe, you shouldn't name your objects or skins with any capital letters or spaces also
3. Your skin has to be a .png and make sure it is .png not .PNG
4. Your model has to be a .JM file
5. Your collision file has to be just a regular file file
Let's do it!
1. Place your "object name".jm into the models folder within the track folder
2. Place your "skin name".png into the skins folder within the track folder
3. If you have a collision file place it into your collision folder. If you don't have a collision file don't worry about it.
4. Right click the statues folder with your track folder, open it with notepad or notepad++ (preferred)
5. At the very end of the text, add another line. This is where you input the values for your object.
They are
[1000.000000 0.000000 1000.000000] - These are the coordinates for your object. X Y Z. the X and Z coordinates are where the object is placed on the map. The Y coordinate is the distance of the objects center from the ground. 0,000000 is placed on the ground. The reason I place it a 1000 0 1000 is because that just gets it into the game. Once it's in the game it is very easy to move and rotate by just clicking on the statues tab on the left side of the screen, and then clicking and dragging or rotating the little black icon in the center of the object.
0.000000 - This is the rotation of the object in radians. You can change this in the game much easier.
@"trackname"/models/banner.jm - this is the path for the object file
@"trackname"/skins/banner.png - this is the path for the skin file
@"trackname"/collision/banner.shp - this is the path for the collision file
The actual setup is this:
[1000.000000 0.000000 1000.000000] 0.000000 @redbud10/models/banner.jm
@redbud10/skins/banner.png @"trackname"/collision/banner.shp
*If you have subfolders for your models, skins, collision, etc, you cannot saf the track. It must be left open.
If you do not have a collision file it can be written:
[1000.000000 0.000000 1000.000000] 0.000000 @"trackname"/models/banner.jm
@"trackname"/skins/banner.png null
At the bottom of the file make sure you have at least one space. I don't know why this is but it is just finicky.
Hope this helps, now that you can make your own objects, and get them into the game, you can start placing it and making your tracks look sweet!