Recently Browsing 0 members
No registered users viewing this page.
By Guest Mauler
Level Of Detail Model tutorial
Here is an example of the HLOD model of the GDI Hummvee, The image shows us the amount of polys and what distance the model will render at... The HLOD system is also used when the settings are set lower to provide better performance.. the engine will choose an appropriate level of detail depending on what the slider is set to in the configuration menu...
To create a new HLOD model, we will need 4 models.. You can add addition models but 4 is a good number to start with
For this tutorial I will be using a tiberium crystal model that was orginally created for TCW and is in use across different maps on UltraAOW, You can get the example file used here
First thing you notice I have 4 different models spread across the y-axis... and for mesh models "mcryXX" etc.. at the end of each mesh name is followed by a .00 .01 .02 etc.. The highest poly model you wish to display must be centered at 0,0,0, on the XYZ axis.. the remainder can be spread across the y-axis like mine is... the only one that matters is that .00 model.. It must be centered in the world axis.. the other files will be originated at the highest poly model on export anyway..
When done creating your model you will need to create " Origin " bones for level. As you can see above the small box centered to each level is a Origin box, and then each of the different level Origin box is linked to the proper 00, 01, 02, 03 level meshes
When I create LOD models, I tend to create the highest poly mesh and simply clone it and move it aside to create and edit lower poly meshes... you can edit the material, vertexs, faces, or anything to create a lower polygon model of the highest mesh
Here are the settings I used for the Origin bones and the actual mesh of the crystals, you can also take a look at the file provided for reference, I did not apply collisions to the actual crystal as I did not want the model to interfere with bullets,characters,vehicles... You can however change it to your preferences..
Once all the Origins, Meshes are completed, you can now export the model to W3D..
once exported the W3D is not complete.. we still need to configure the render distances and export the HLOD info..
Ok so open up the model in W3DViewer
As you can see the model is loaded, and rendering the highest polygon model ( .00 ) Currently the HLOD is not setup to switch to lower poly models...
and we will set them up and export to a model that will automatically switch depending on the player camera distance.
Since we have 4 models we will need 4 spots to where each level will render ingame...
Keyboard Keys to switch between levels of detail are [ key and ] key and spacebar to set the render distance
First I want to get the viewer camera set to about 25 units away.. you can see this at the bottom of the viewer under Camera
Now at about 30 units is want the model to switch the the .01 model, set the camera to 30 and press [ to render the next level ( .01 ) press spacebar to set the distance..
Now move back to about 40 to render the next level ( .02 ) press [ again and spacebar to set distance
Now move again back to about 50 to render the last model ( .03 ) press [ and spacebar
Now that we have set the distances we can check our results of the switching, go to LOD>Auto Switching then move you camera back and forth and you should see the model switch from the high poly model to the lower poly models...and after 50 units the crystals won't render at all
We've completed another step in the process but we need to export this new LOD model.. Go to file>export>LOD and make sure to save the file in a different directory as the other model we exported from max.. so you'll end up with 2 W3D files that share the same name...
Now w3dviewer doesn't export the LOD information.. so you will need to use TT 4.0 tools to get it working, we will need to use mergelod.exe to export a correct W3D model with the proper distance settings, so we can use it ingame
Now drag and drop both files into mergelod.exe
once dropped the file is now ready to use.. notice the 1kb file... that is the information file, the larger 2,023kb file is now the proper file to use... open your larger W3D file and check Autoswitch option.. it will now properly switch the models when you import into Renegade..
You can delete the 1kb model and simply rename the 2,023kb model back to the original file name without the (2)
Thanks for reading and goodluck!
You can get the TT 4.0 Editor/Game tools here
By Guest Mauler
If you wish to host this tutorial elsewhere please let us know below..
I have finally gotten around to creating a simple tutorial on how to get lighting effects from 3DSMax 8 into Renegade, Some would call this "lightmapping"
when using this and some other tools TT have developed you too can get professional looking shadows, lighting effects... just one thing i should mention, this method is not dynamic lighting, but rather static baked in lighting
Open your completed level, textures are optional, but recommended that the level be completely textured before starting the process. Just easier to render and see the effect the lighting will have on the level
Here I have placed some lights and other atmosphere effects to the scene.
Let's render [F9] the scene and check out how the lighting looks, Everything looks fine, When you happy with the final product move on to the next step. **Remember to render often to check for lighting errors or glitches be sure to look at all surfaces etc..
Now that our lights are done, lets hide them and just keep the terrain I want to lightmap visible, First thing you want to do is clone all the terrain pieces you wish to apply the lighting to... In my case, it is the concrete boxes and ground. [Right Click > Clone]
Now both pieces are cloned simply move them to the side, Leave it there for now, we will work on that in a bit.. As you can see I've moved mine a bit off from center.
Now select the original two pieces and remove the materials from them [utilities Tab> UVW Remove>Materials Make sure "Set Gray" is checked]
With the materials off the original meshes, we need to combine them for the lightmap. [utilities>Collapse>Collapse Selected] This will make the pieces into one mesh.
Now that it is one mesh, we need to apply a UVW unwrap, Select the mesh [Modifiers>UV Coordinates>Unwrap UVW]
Now that it has applied a UV unwrap we need to flatten all faces for the lighting information. ** Before moving on set the "Map Channel" to 2, we will need to remember this for later
Under "Selection Modes" click on the third button to the left "Face Sub-object Mode" then select all faces in the scene [Ctrl+A] to select all, then we need to flatten, [Mapping>Flatten Mapping].
Once that is done just use the defaults that are displayed on my screenshot. Click "Ok" when done.
The modifier should auto-flatten to something similiar to what i got pictured above. Once that is done, move on to the next step.
Now we need to render the lighting information to a texture, [Rendering>Render to Texture]
This will provide a pop-up of the settings of the texture we will render, Set the Padding to 64, Object should "Use existing Channel" then set the channel to 2, we set this channel from earlier...
Continue down to "Add" button, Click on it and select "Lightingmap" after it will provide you with the ability to change the file name and type of the texture output [To change output location click on the " ... " ] **For lightmaps I tend to make them DDS with DXT-1 settings, and Use a 256x256 size
Once you are happy with file name and output location press "Render", You should see a pop up with the lightmap texture, something like my lightmap pictured above. Once rendered close the pop up windows
Now the lightmap texture is applied to the original mesh, At this point we need to detach the single mesh back into the orginal two pieces we started with.. [Right-Click on the mesh>Detach with the element tool] Once complete move on to the next step.
Now this is where the cloned copy of the original comes into play, We need to attach the cloned pieces to the lightmapped pieces. Ground>Ground, Concrete Boxes>Concrete Boxes... Once you attach the cloned copy to the lightmap meshes a pop up will appear [Pictured above] leave those default settings and press Ok.
Now that the pieces are attached together we need to re-apply the materials over the meshes, Once complete move to next step
Now the two pieces are retextured we need to get rid of the cloned mesh we made earlier [Mine was the top one] just make the mesh editable and select and delete the cloned mesh [Pictured above]
We are left with the one piece, Now we need to apply the lightmap texture we made earlier to the materials of the Ground and Concrete Boxes.. Go into the material editor [ M ] and apply the next step settings to the materials.
Vertex Tab, Stage 1 Mapping should be set to 2 Shader Tab, Pri-Gradient set to "Disable", Detail Color to "Scale" Textures Tab, Check Stage 1 Texture, And place the Lightmap texture you output earlier here, Click on "Clamp U" and "Clamp V" Once completed close material editor and Export your scene into a W3D Once all is complete and lightmap textures are applied to the mesh/meshes.. You will need to add a user defined parameter.. Right click, goto properties and goto User Defined tab... There you will see a text box add the line [ Prelit=true ] - everything in between the brackets.. And apply this line to all lightmapped mesh.. This is so that the Renegade vertex lighting system ignores these pre-baked light meshes
Here is my completed level with Lightmap applied in W3D Viewer... Enjoy! and experiment!!
This is what the model looks like without a lightmap texture and using default vertex lighting instead
Hope you guys learned a bit from this... you can now go and create some cool looking levels with this method of lightmapping I've provided for you...It can get very complex for larger, more detailed levels, so you will need to dedicate quite sometime to do it right!
I've only covered the basics on this tutorial, but I'm sure you guys can experiment and achieve more... Good luck and please feel free to post any questions you might have about Lightmapping in this tutorial thread...
By Pwn Call
By Pwn Call
First I recommend that you read through this whole tutorial before you start it as well as the comments on the following pages. That way you can see why you need to do things a certain way and it may be different for your type of map. This way you can fix the issue early before you are too far into to it.
VIS is a system that Westwood created that allows for better FPS when playing Renegade. The basic principle behind VIS is that it allows your computer to only load what is visible in that specific map from where you are located. So for example if you are inside one of your buildings it won't bother to load the interiors (and most likely the exteriors) of the enemy base because they aren't in your line of view.
I learned how to do VIS from YSL Muffins original VIS tutorial which can be found here. This tutorial is quite in depth but can be quite confusing as well so hopefully mine is a little less confusing while still explaining it well. Also I use one of his pictures in my tutorial so credit goes to him.
Step 1 - Create your level
Usually I like to make my level first then add my VIS sectors at the end, you can add them as you go if you want but I think it gets more confusing that way. Also you should only set up the sectors in Level Edit once you are done with everything else, otherwise things can get messed up easily.
Step 2 - Determine which type of sectors will work best with your map type
If your map is:
Flat - Use the plain sectors as shown in this tutorial for the entire thing, also make sure you add them for lower or higher levels of terrain, for example the tops of high rise structures or other high or low places you can get to.
Very Hilly terrain - Use the method to create sectors where you clone your terrain, and detach several vertices at a time. This will take much moretime but works much better with hilly terrain, allowing for much fewer VIS glitches later on. Also make sure to look closely for VIS glitches around the really steep parts of your map.
Mostly flat with some steep hills - Use the flat plain method for the flat parts of the map and use the clone terrain part for the hills.
Step 3 - Create your VIS Sectors
Alright here we go! So VIS sectors are basically meshes that lie below the surface of your map and you must create a VIS sector anywhere the player's camera can reach. For example when you are in first person mode the camera is exactly where the players head is, however in 3rd person mode, or more importantly when you are in a vehicle, the camera is somewhere above and behind the player. So with that being said you don't only have to put the sectors anywhere your player can go, but also off the edges of the map where they camera may be.
So look in this next example of me making my sectors for my map, they might not need to be that far off the sides but it is better to make them further off rather than not far enough off because it will give you hassles later on. Also I use a standard plane with 1 segment to keep poly's low and I believe the size I used was 25x25 meters. I wouldn't go much bigger than this with your sectors or a whole lot lower, it also depends on the size of your map.
Another important thing to do is to name your sector, I usually call the first one I make VIS and then when you clone it it will name the next one VIS01 and so on. This way you can select them all easily later because they will go under all of your terrain.
Now before you start cloning them all over your map make sure you lower them on the between about 1 and 1.5 meters.
Then clone it.
And repeat until you have the VIS sectors cover all of your terrain like so. It is extremely useful to use the Grid tool for this so it is easy to line them up, if you don't know how to use the Grid there is a tutorial I made here.
Also remember this map I am doing is all flat so planes work well for this. For most maps which are not flat you will have to create your VIS sectors a little differently. The best way to do it is to clone your floor terrain and lower it. Once you lower it you will have to select several vertices at a time and detach them until you have all of the sectors separated. Don't forget to lower it! It also helps if you do this before you texture it but it isn't necessary.
Now not only do you have to do this for your terrain it has to be done anywhere where your character can get to. For example you can see White Nyte's here which is walk onable so I have to make a sector for this like so.
And don't forget to lower it!
Now you don't have to put VIS sectors on everything, just things that are much higher or lower than the existing sectors. For example the top of White Nyte's is most likely too high for the sector and the ground to be effective, that is why I am adding on for the roof of the building. But smaller things like curbs or rocks that you can go on are low enough that you don't need to make a different sector for. I believe a sector works 10 meters above it but remember it is 1 meter below the ground and the camera can go up higher than your character or even higher in vehicles. Test it out and see what works best for your terrain.
Also the renegade buildings come with their own VIS sectors built in so you don't need to add them to the buildings.
Step 4 - Exporting
Before you export there is one more thing you have to do. First select all of your VIS sectors. Do this by selecting them by name which is really easy (if you named them VIS like I told you to earlier)
Now we have to set the W3D options of the VIS sectors. With them selected click on the Hammer icon on the upper right of your screen, then W3D Options. Then check off both hide and VIS under the collision settings. This allows your VIS sectors to be invisible but still work. They won't disappear in Gmax but they will be gone in LE.
Alright now you are good to export your map to Level Edit.
Step 5 - Level Edit Set Up
So now you should have exported your map with all of your sectors into Level Edit. First I would make sure you set everything else up in Level edit like buildings, waypaths, presets, etc. Also you have to have a Pathfind Generator somewhere on your map to set up the VIS or else Level Edit will crash when you set it up.
Now to start setting up you must do these 4 things in this order. The last 2 will take a while because it is creating all of the VIS points, and make sure you set the granularity to about 5, if you go any lower it takes a TON of time. If you have a crappy PC I recommend 8, you will just have to add more manual VIS points later.
Alright that took a while! Now you are almost done. Now what you have to do is walk around and look for VIS glitches. A VIS glitch is where the system thinks you cannot see an object so it won't load that object when in reality you should be able to see it. It looks something like this...
That is the inside of the refinery and there is a mesh there covering up that hole but it doesn't think you are supposed to be able to see that mesh. So what you must do is create a manual VIS point. To do this just hold down the control key and hit the accent button which has these symbols on it ` and ~ (left of the 1) so Ctrl+`. Once you do that it should fix the VIS glitch and make that mesh or object reappear. If it doesn't reappear try moving around or moving the camera around slightly and try it again, some VIS glitches are stubborn! Some cases if it can't be fixed it may be because there isn't a VIS sector in that location and in that case you need to go back to RenX and fix it.
Common places to look for these VIS glitches are as follows: Most of the Renegade buildings have them especially in and around the doorways, the hand of nod by the ped area windows has a ton of them so look there very thoroughly or add your own sectors to that spot, entrances and exits to tunnels, areas that have really steep slopes, corners, etc.
Also for finding ones around doors you can hit Ctrl+Shift+T which will hide the doors. Note that this also hides all tiles like trees or other objects you have made in your level, so once you are done around the doors hit Ctrl+Shift+T to make them reappear.
Once you make a manual VIS point it will appear in LE like a little camera to show where you have them.
Now walk all over your level and look for them, it is easier to find them in 3rd person mode because the camera swings wider so you will have more luck finding them.
After you walk around the whole level and find them all you can do it one more time only with tanks viewpoint. Do this by going to the Camera tab then choose the Mammoth Tank.
This should make your view look somewhat like this
Now when you are going around in this view you don't have to go anywhere a tank couldn't go. Also use the Mammoth tank because it has the widest turn radius for the camera. Really check the edges of your map and around buildings well cause these are places that are prone to VIS glitches.
For flying maps you have to have more than just the VIS layer under the ground, every 9 meters or so in height you need to add another layer until you reach the flight roof. That is really the only difference for flying maps.
This is a very confusing tutorial for those of you who are new to VIS, so ask any questions you have below and I will help to answer them. Also if you know more about VIS than me let me know if I did something wrong or if there is a better way to do something!!!
By Guest Mauler
RenX / Leveledit
First of all, some things you should keep in mind about elevators:
an elevator might cause problems if there are alot elevators, or if people try to use the same elevator at the same time with a slow connection (56k for example) people might fall "through" your elevator and popup at the top after some seconds elevators can NOT transport vehicles! You should always take care that the Transition Zones (explained in the tutorial later) are not reachable for vehicles because the wil get STUCK in them! elevators often cause problems with beacons, if you try to deplay them ON the eevatro plattformFisrt Step is ofcourse, create your elevator. This is myone. Ok its not very nice but thats a 2 min one
Basicly an elevator has a platform (in this image the red parts), and a door (the blue parts). Of course an elevator can also have other parts in the deep of complexy you want but for this tutorial this is the best choice.
Always create your elevator in the center of RenX/Gmax.To get an ide of the size of an elevator, the Single Player ones have an aprocxiamte size of L: 6m, W: 6m, H: 12m
You can create a box with these settings to get an idea if your elevator has the right size:
(my elevator is a bit too big as you can see, but the size is your choice, you just get a general idea about the size with this method) Because the Rengade-Engine don`t like textured objects that are moving we now create some "cages" that later will be invisible, but responsible for the collision parts.
These are basicly just meshes without a texture that covers that elements, that later collide with players.
Activate the W3D hide and collision Settings: Vehicle, Camera, Projektile, for the textured Meshes don`t activate any Collision Settings. Now it is time for the animation, an elevator has 3 Animation stages:
Stage 1: (Baseframe)
Move all your parts of the elevator so it is on the Top-Part, with the door open for enter at the Top:
As you can see I just moved the whoe plattform up, and lowered the ring so if the player can enter the elevator at the top.
Stage 2: (On the move)
Now klick the animate Button,
Goto Frame 1 and move your door so it is closed (you can use more than one frame if needed, just note this framae somewhere)
Now on the trackbar goto frame 10, and move the elevator down, so it is on the botom with an closed door (same comment as before for the cloe door thing):
The best is you note this frame on a paper or something, because you`ll need this later.
Stage 3: (Final Animation)
Now just make an animation when the door moves down, so you can leave the elevator. My one ends on frame 11, because only one frame is used for open the door in my example, of course you can use as many as you need:
Now you`r finihed with this, deactivate the anim Button and feel good that the work is nearly done. Export the elevator to your Modpacket:
Export it as HirachyAnimated Model and from Frame 0 to the last frame (in my example frame 11):
Open the Commando (Leveleditor), browse to Tiles and press the Add Button
Now enter a name, e.g. my_elevator, and switch to the Settings Tab Change the type to ElevatorPhys, Select your W3D and change Collision Mode to STOP, Animation Mode to Manual.
Scroll a bit down and set
DoorClosedTop to the frame when the door at the top is closed (that is frame 1 in my example),
DoorOpeningBottom to the frame where the elevator is at the bottom with open door (Thats frame 11 in my case)
ElevatorStartTop that is in nearly all cases frame 0
ElevatorStoppedBottom this is the frame where the elevator is at the bottom with closed door (Frame 10 in my case)
Now cahnge the CloseDelay to the Time the elvator should need to go up/down and press OK and your nearly ready for test your elevator. Ok, now its time to tell the elevator where people will wait to enter:
Select your elevator again and press Mod, goto the Zones Tab.
You see 4 Zones:
LowerCallZone: Defines the zone where the Character has to stay in to call the elevator to come to the bottom
LowerInsideZone: When you are inside this zone the elvator starts to move Up
UpperCallZone: Same as LowerCallZone but for the top
UpperInsideZone: Same as LowerInsideZone but for the top
When you doubleclick you can adjust the zones t the size / position you need.
First / Lastframe switsche between the start and end frame so you easy can adjust the zones.
Adjust now all zones like it is explained above.
Here are mine:
LowerCallZone LowerInsideZone UpperCallZone UpperInsideZone Now press OK and your done with the setup.
Load your Level and select your elevatzro then press Add and it will apear on the map:
Export your Map and test the elevator Congratulation! You can now go up and down with your elevator as long as you want.
By Guest Mauler
RenX (Gmax) / Leveledit
How to make a door for Renegade:
1. Create your door in GMAX (It may looks a bit like this
Activate the W3D Collisions Settings:
2. Click at the Aniamte Button in the lower right corner:
Scroll with the Frameslider at the right position(100) and move your door to the `open` position:
Click at the Animate button once again. Have fun with your ready animation (viewable with the play button)
3. Export your file now into your Modfolder, the GMAX part is done now.
4. Open up the Commandoeditor and add a new Preset in the group Tiles:
name your door:
Change into the Physic Model Tab, and setup the following:
(at the model name of course your W3D file)
If you want that the door opens even for `empty` vehicles, like the one of the GDI weponsfactory activate the option, [x] DoorOpensForVehicles
Now click at OK, that is needed for the following steps.
5. Select your door and click Mod:
Now there is a new Tab Zones, there are two Zones. Double click at the TriggerZone1:
The folowing window should popup:
The green box is the Triggerzone, change the size and the position over `Size Zone` and `Move Zone` so that it is positioned in front of the door, do the same for the TriggerZone2, but position it at the back of the door.
Click OK, and your door is now ready for use. Just click on Make and voliá!
In the Physic Models Tab you can define some open/close sounds and times, or make the door a security door: