Serious Sam Fusion 2017 (beta)

Serious Sam Fusion 2017 (beta)

Not enough ratings
Enemy Destructions and Custom Debris
By Soulmyr
This guide will help you understand how destruction works and how you can make your own gibs
   
Award
Favorite
Favorited
Unfavorite
Getting Started
Today we’re gonna learn about destruction. For example if you want to destroy your will to live simply publish a mod for Serious Sam Fusion and wait for the comments.

Alright, joking aside, I’ll tell you how enemies die, how to make gibs and how the mutilator and C4 work.

To start off, enemies have pre-made destruction “animations”, which are stored in their destruction holder. These include debris (gibs), particle effects and sounds. The holder also determines when a destruction is executed. For example, if X weapon lands the killing blow the Y destruction will be applied. These holders are stored in a monster’s mdl file.

To get a more detailed look into what's what, go to an enemy's destruction editor and select the "Holder" tab on the bottom left.




















Configs is ... well, the configs. You can view them in-depth on the bottom right. If you want to make a new config based on an old one, you can click on the green and orange square button while having the config you want selected, and you'll get a new one BELLOW IT. (Very important, since the cloned config has the same name, not X_01 or X2 or whatever)

Destruction settings is the interesting part. This is where you link weapons and damage type to destruction configs. "Player data" is generally used for weapon types and "Generic data" is used for damage type, from what I've noticed.
Destruction Details
Now, a destruction is usually comprised of 3 things - debris (gibs), sound files and particle effects. Some also have decals.



















Each type of destruction has it's own settings. In the picture you can see the debris settings. The important ones are:

Model - The model of the debris itself
Stretch min/max - This makes the model bigger or smaller. If you have different values, the debris will be a size between the minimum and maximum value each time that destruction is triggered.
Min/Max Velocity - This controls the speed at which your debris is sent flying.
Disturb velocity - This sets the direction of which the debris is sent flying. (Values are revolve after a certain point, so there's no point going for big numbers)
Toughness - This determines whether or not your debris stays or breaks upon colliding with the ground.
Life min/max - Supposedly, this determines how long a debris lasts, though I've tried a lot of different values to no effect.
Trail effect - Basically the blood stains a debris leaves on the ground
Distribution - If you want several gibs of the same type (like meaty chunks) then you'll wanan select Box Distribution. Otherwise Normal distribution is just one debris

If you want to make custom debris, you’ll need to do 3 things – cut the mesh, set the collision and adjust the skeleton
Cutting the Mesh
First, open the monster’s mdl file, and resave it. Then, go to model editor, click on mesh and resave the mesh. Now you can cut out the part you want without accidentally overwriting the main part.

Some models have official resources (skeleton and mechanism) which you can't unshare, so just resave them as something new. You can remove everything else like children and animations.

If you have "Wires" enabled you can better see where all the polygons are

Now you can either select each polygon by hand (hold down Shift and click/drag the mouse across), or you can use the knife (K button) tool (not recommended, unless you’re making very clean cut gibs).

You only need to select the polygons which are next to the "last" ones. After you've removed those, you can double click on the unnecesary part of the mesh for a quick and easy way to select it all

Like so

After you’ve removed the unnecessary parts, select the vertices on the wounded end of the limb in a CONSECUTIVE MANNER i.e. one after another (otherwise the end result will be a weird mess).

A useful trick I've found is to get the camera "inside" the debris. That way you won't accidentally click on a vertice inside the mesh.

Once all the vertices are selected, press P and you'll create a polygon


















Now, you’ll want to apply a texture to them. First, while having the newly-made polygon selected, create a new polygon map (shortcut is Ctrl+G).


















If it’s a fleshy part, you can find the material file in Content/SeriousSam3/Presets/ShaderPresets/Generic/HammeredWound.mtr and apply it to your layer. To fit the meat bits accordingly, press VM -> T, create new map, and now select either Atlas or Planar (and select along which coordinate to move).

Just go with whichever one looks better

If the texture doesn’t look right, you can simply repeat the process.

Now press Numpad 8 to bring up the Peeled Look, as it’s probably not official called, and you’ll see how your texture is applied.

Simply stretch the model until the wound looks presentable and you’re done.

Good enough

If you want, you can triangulate the mesh with Shift+T. Sometimes it makes it look better

Adjusting the skeleton
Now, for the skeleton, you’ll want to see which bone your debri ends at, and make that your new root part. Select that bone, and go to tools. Write down the X,Y,Z,H,P and B coordinates.

Or just press PrintScreen and paste them somewhere

Now, while still having the bone selected, press Reparent on the right side, and leave the field blank. Input the values from earlier and delete the unnecessary bones.

Adjusting Collisions
Lastly, you’ll want to edit the collision. Go to collision editor, click on mechanism on the bottom left and on the root part, keep going through Children, until you find the first one that fits your mesh



















Click on the part where you can expand/collapse, Ctrl + C, then click on the root part and Ctrl + V. Yeah it’s a bit awkward, but bear with me. If you do it right the shapes will move somewhere

Usually the center

Select "Align to bone" (press B) and the shape will automatically go where the bone of the same name is. Lastly, remove the joint of the new root part.

You can also add more shapes and adjust the accordingly to make the collision more true to the mesh



















Just make sure to have Shape selected on the bottom.

Rendering
Some monsters have several Levels of Detail (LOD) which basically reduce the polygon count the further they are. You'll want to remove anything other than the first one, and increase it's range.

You can see these while in the mesh editor, on the bottom. An easy way to switch between them is the 1 through 4 keys. On the bottom right, press LM and R and you'll see the LODs. Remove all except the first one, then increase it's value to something like 1000.

Since we only edited the mesh on the first LOD, the others have the mesh intact
Mutilator Hooks
For this part we're gonna need 3 things - an entry in the monster's destruction config (duh), children, and a decapitation scheme.

If your monster doesn't have a Mutilator destruction by default, you can add one in Destruction Editor. Under "Generic data", add a new entry, select "Decapitator" as your damage type, and input what destruction you want to happen when you kill an enemy with the Mutilator.



















Next up, you'll want to make children (lol). In Model Editor, under children holder, a monster needs to have at least one child attached to a bone (lol).

If you can't see the child, simply hold Ctrl to bring up the XYZ mover

Now, a little lower, where is says "Decapitation scheme" is the important part. There are 2 values you need to know:

Resilience - The lower this value is, the more enemies you will be able to hook. So you can hook 4-5 Rocketeers but only 1 Scrapjack at a time. Think of it as the monster's weight.
Lethal power - How long it takes before the Mutilator is charged up and ready to kill.



















Hooks are where the mutilator goes. Here you just need to put the previously established child as an attachment, and configure the width and height. Sometimes the hook will be perpendicular, in which case you will need to rotate the child.

It's interesting to note that you can have several ... states(?) of hooks. As you can see in the picture above, the Rocketeer has 3. First one is only the chest, second one is chest and arms, third one is chest, arms and legs.

C4 Indicator
This is the easiest part. First you'll need to create an entry in Destruction Settings under Player Data and set the weapon category to StickyBomb.

Then create a new child, like the lasso hooks above, and name it "StickyBomb_00" (if you want more than one, name them "StickyBomb_01", "StickyBomb_02" and so forth). Select a bone to attach it to, adjust accordingly and you're set.

If you have a simulation open in another window you can edit the position more easily.

And now to end this guide on a funny picture

3 Comments
Yurka262 14 Dec, 2024 @ 8:17am 
super guide, helped a lot, thanks ) only when I clicked Reparent I did not reset the coordinates, everything works fine.
LexMental 27 May, 2018 @ 1:25pm 
Brilliant!
The solar flare. 26 Feb, 2018 @ 2:44pm 
the more guides the better we will all be