Those look like a lot of fun BrUnO! A lot more fun than my simple setup.
Lovely collection! Definitely some gems here for my side projects
**Other How-To 2: Creating (Mostly) and Importing a APEX Cloth asset created with 3Ds Max and PhysX DCC Plugin
**
Requirements using this method: 3Ds Max/Maya and PhysX DCC Plugin
If you need the PhysX DCC plugin you can sign up at Nvidia.com. This page will help get you started: PhysX DCC Plug-Ins|NVIDIA
Overview:
This will be a short tutorial to quickly cover creating a simple cloth asset and importing it into the Unreal Engine 4. There have been similar tutorials already, but mostly wanted to cover a written tutorial for this. The video is just an added bonus as I had made it while troubleshooting the process for an AnswerHub post.
FBX and APB Files: Dropbox - Error - Simplify your life
Video: This will not cover much other than a run through of the process.
Step 1: Create a plane with a lot of verts (within reason) and convert to Edit Poly
Pretty straight forward. Create a plane and add some verts to it. I just used an arbitrary size and set the length and width segments to 24 for this demonstration.
Step 2: Apply a material to the plane (Important!)
This, at least to me, is a very important step that confused me quite a bit when I first started using cloth. If you do not apply a default material to your mesh and use the one that is on the mesh when you created it there will be no material assigned to the cloth asset when you import it into UE4.
So make sure to add a default material otherwise you’ll not have a material to be able to assign the cloth apb file to your mesh later when imported into UE4.
Step 3: Create a bone
Create a bone that we can use in the next step to “skin” to our mesh.
Step 4: Add a Skin Modifier to your Plane
Add a skin modifier via the drop down modifier list to your cloth plane.
Once the modifier is selected locate the Bones: “Add” button and click this. This will bring up a small window where you can select the bones in the scene to skin your mesh to.
Step 5: Add the PhysX cloth modifier via the PhysX toolbar
Next you’ll need to add the cloth modifier from the PhysX DCC Plugin toolbar
Once this has been added you will see it populate in your modifier stack along with its settings when selected.
Step 6: Paint weight accordingly for your cloth and test with the simulation
Under the settings locate “Paint” and set a value for the Brush Value.
I will use 200 for mine. The default is 0 which effectively means there will be no cloth simulation for any areas painted with a 0 weight.
Select the brush to paint the weighting.
As you paint you will see red trace lines that come out. This is the 200 cm value that we used. If you use higher or lower values this will be longer or shorter. 0 will have no trace lines.
Step 7: Test your assets simulation
Select the play button here to see your cloth simulation.
If you want to see wind simulation to see a more practical use of your cloth in the settings locate the Wind section and use these settings before hitting play.
Adjust according to your needs.
Simulation result:
Step 8: Select the Cloth and Bone to export selected as and FBX
Select the bone and the cloth plane. Then go to File > Export > Export Selected > Choose a name for your file > Change File Type to FBX > Click Save
**Step 9: Export the scene (not just selected) with the file type PhysX and APEX
**
Same as above with exception that we will just export the scene this time and not just the selected object.
File > Export > Change file type to “PhysX and APEX” > Click Save
After you click save a new window will pop up. Use these settings:
Step 10: Open UE4
Self explanatory.
Step 11: Import the FBX we just created for our Cloth plane
Locate your FBX that was first exported with just your Cloth plane and bone and import this into UE4.
Use these settings:
Once that is imported locate the cloth skeletal mesh and open the asset.
Once this is opened verify that you do have your material slot. If not, you’ll need to go back to Max/Maya and add a default material.
Step 12: Open the our Cloth plane skeletal mesh to apply the cloth apb file we exported last
Now we’ll click the the option to “Add APEX clothing file…” and navigate to where we saved our APB file we created.
After importing the apb file you’ll be able to assign this to the material via a drop down.
You will also notice that you can adjust various settings for your apb file to control how the cloth reacts. These are all settings that can be setup via the PhysX DCC Plugin as well.
Wiki Tutorial 1: Lighting Troubleshooting and Tips Guide
This one is still very much a Work-In-Progress as Eric and I work to get some simple troubleshooting and tips up for everyone. We’ve wanted to do this for a long time and have gotten a little bit of a push to make this available for those having issues.
The majority of these will be simple steps with a little bit of explanation for the “why” of it all.
Over the next couple of weeks Eric and I will be updating this regularly as we knock some of these out.
If you see anything missing or something you want covered please let me know and I’ll add it to our list.
**Here is what has been added so far: **
General Lighting Tips:
- Why are my shadows black?
- Converting BSP to Static Mesh Lightmapping
- Two-Sided Lighting for Single Sided Meshes, or Why does my light come through the roof?
- What if I don’t want to have lightmaps at all or my game doesn’t need them?
- Why Does this look nothing like it did before, or Engine Scalability and you
- Why is there a red ‘X’ over my light?
Movable (Dynamic) Lighting Tips
- Directional Light ONLY: Cascaded Shadow Map Settings
- Adjusting Cascades for better Quality
- All Dynamic Light Types (Light Tab Settings)
**Static Lighting Tips: **
- Lightmap Resolution / Shadow Quality (Static mesh vs BSP)
- What does this “Warning: Overlapping UVs” nonsense mean?
- How do I generate lightmap UVs in the editor?
- How to control Global Illumination with Static Lighting?, or The Wonderful Thing About Bounce
- Why is there shadow splotches on my static mesh?, or How to clean those dirty lightmaps?
- What is the “Lighting needs to be rebuilt” in the Top Left corner error?
- Lighting Quality Comparison, or Production > Preview
Planned:
These are done just not up yet.
In the works.
Hi , the link of the project
's wiki tutorial for Day Night system (with some tweaks)
Redirect you to a dropbox file DayNightProject1.zip of 1,16 KB. I downloaded and it only has 2 .ini
Thx for sharing this tutorials !!!
You’re totally right on that. I’ve fixed it now.
Thanks for letting me know.
Hey -
The Split Screen tutorial images are not showing would you mind fixing them?
It’s fixed now. Thanks for point it out!
Hey thanks for that
Stay Epic !
Thank you very much for all the tutorials and project files.
Plenty more coming in time. Just finding the time to do it all can be troublesome. I’m really wanting to setup a lot of stuff that has been on my bucket list to learn and experiment with since I started at Epic last April. A lot of focus lately has been on the Wiki lighting troubleshooting guide with Eric though. I’ve got so many destructibles Tips, tricks, and setups I want to do just to help people out with them. That may become a wiki as well. We’ll see what happens.
Other How-To #3: Creating Level of Detail (LOD) Meshes in 3Ds Max for UE4
**This is specifically for 3Ds Max and may be similar in other Autodesk or modeling applications. **
**Overview: **
This short tutorial will go over the process of creating and exporting LODs with 3Ds Max to UE4.
Step 1: Base Mesh and LODs
In this example I’ve chosen to use the statue mesh found in the Mobile Sun Temple demo from the Marketplace.
This is my base Mesh showing the shaded model alongside the wireframe mesh.
Often times this much details isn’t always necessary for a mesh as you move further away from it. There is a lot of detail here that will not be perceptible from further distances. By reducing the polygon count we can create a lower Level of Detail (LOD) version that is not noticeable.
In the next steps the mesh will be depreciated for lower LODs that we can use to optimize our games.
Step 2: Creating Lower LODs
With UE4’s LOD system you can use up to 4 LODs.
LOD 0 is our Base mesh with all the awesome detail! LOD 1-3 will be our lower polygon versions.
First we create our copies:
Top is the Wireframe with Bottom being the shaded model.
Before starting the first LOD there are two options that are available inside 3Ds Max to depreciate the mesh.
There is the option of ProOptimizer and Multires Modifiers.
Both are good in their own right and each has it’s own method of depreciating the model, but with one exception. ProOptimizer does it in a destructive way compared to MultRes.
Here is an example. The mesh in this scene has already had it’s UVs completed, but now just needs a lower LOD. ProOptimizer will destroy the UVs in doing so whereas MultiRes will honor them.
Make your choice based on your needs as they are similar in how they do the tasks for actually depreciating.
Moving on…
Select the mesh you want to use and in the modifier stack add the modifier you’ve chosen.
For this example I’ve chosen the MultiRes Modifier.
This is fairly straight forward for this part.
Click Generate at the bottom. This will map the mesh so that the polygon count can be reduced.
The options at the top for Vert Percent are now editable. You can also use the Vert Count option if you have stricter limitations or an OCDness that requires even numbers.
For the three lower LODs I’ll set them up as follows:
LOD 0 (Base) - 4479 verts - No Change
LOD 1 - 2240 verts - 50% of original
LOD 2 - 1120 verts - 25% of original
LOD 3 - 672 verts - 15% of orginal
Final Result after setting up LODs:
Step 3: Grouping the LODs for use in UE4
The next part requires the meshes to be “Grouped” so that they can be used as single LOD.
Select all your meshes and center them up to each other. In Max you can select all the meshes and set the XYZ Locations as the World Origin or use the Align tool from the toolbar.
With your Meshes all aligned use the menu bar and select Group > Group
Next give the group a name
Step 4: Level of Detail Utility in 3Ds Max
In this next step make sure the mesh is selected and then go to the Hammer Icon and select that in the Command Panel
Next select “More”
Select “Level of Detail”
Click “Create New Set”
The LODs should populate the window in the lower area now.
At this point the mesh is ready for export to FBX.
When exporting the FBX make sure to remember to check export Animations otherwise your LODs will not work.
Step 5: Importing into UE4
Once the mesh has been exported to FBX it now just needs to be imported into UE4.
Make sure to select the option for “Import LODs” like so:
Once imported open the mesh in the Mesh Editor.
On the right side there will be a listing of all available LODs.
To see individual LODs use the drop down to select a LOD.
LOD0
LOD1
LOD2
LOD3
Updated Day/Night project for smoother transition to day and night using timeline for the light and skylight intensities.
Is that all i need when i want to offer a coop feature for my game (using ThridPerson setup)??
Honestly, not completely sure. I’ve not messed with multiplayer beyond just getting the single screen multiple players set.
Since it’s using the same screen I wouldn’t think there would be a need for replication since you’re not using a server or anything over a network. As far as I’m aware this should be fine for co-op single screen kinds of games.
My suggestion would be to setup a simple test level with some events, traps, or other goals and see what you get.
Man that is an awesome tutorial on LODs. Little details like that to make games way more optimized.
Now if I take my meshes and make them LOD like this, will I have to redo all their placements on the map? Also do LOD’s apply to foilage such as rocks/trees?
Glad it works for you!
There will be no need to do re-do their placement. If you have your base mesh already placed all you need to do is create the LODs and you can just reimport the original mesh with the newly added LODs or individually import the LODs in the static mesh editor.
If you have any trouble feel free to ask.
Other How-To #3: Light Functions with Color
**Overview: **
Light functions do not provide color when a light function material is plugged in. This does not mean that you cannot get a colored image by taking advantage of the system though.
All that is needed is to setup a material for each color value for Red, Green, and Blue. With the texture sample you’ll plug the single color value into the **Emissive **pin. Also, in the **Material Editor **the **Material Domain **will need to be set to Light Function.
NOTE: This can probably be done with a single material and using an instance to switch on or off the various color values or some other method. I’ve just not looked. If I pursue that method at any point I’ll update here.
You should end up with something like this for the Red, Green, and Blue materials.
Material Setup
Light Functions in Action
Scene Setup: These are all Spotlights with an assigned Light Function Material that corresponds to the color value we will assign it.
Top Row: This is three spot lights each with the either the Red, Green, or Blue material assigned. The light color has been changed to the full value for that color using the Color Picker to set the RGB Value. (ie. Red would be set to R=1, G=0, and B=0)
Middle: The three Spotlights with the assigned light functions overlaid onto each other.
Bottom: The three Spotlights with their Light Function Material assigned with the light’s color value left at default of White.
Hello ,
I followed your destruction tutorial with the parking meter. I used the same settings as you. My problem is that if I drive a car into the mesh the car stops/bounces off. I tried changing the impact resistance but it didn’t seem to have much of an effect. I want the car to be able to plow through the mesh as it is destroyed.
This works if I turn on simulate physics and start awake off. The only problem is that even a small love tap will destroy the object regardless of the impact velocity setting.
Hi Osok,
Custom Impact Resistance is bugged at the moment with 4.7 and previous version. This was fixed recently and will be included in 4.8 once that releases.
This is correct that it will do this when impacting.
With a low value Custom Impact Resistance this will resolve that issue.
Here is a demonstration video with it set. The first is 4.7 and the second part of the video is 4.8 with CIR working.
The original purpose of the FBX Chunk post was to demonstrate the mesh switch rather than focusing on impact velocity or other settings. Once the CIR has been publicly released and fixed I’ll update the video for a better demonstration.
(comments referencing this post in this thread: [TUTORIALS] Photons Be Free: Mini-tutorials and other curiosities - Community & Industry Discussion - Epic Developer Community Forums)