News:

One Minute Game Review by The Happy Friar: https://ugetube.com/@OneMinteGameReviews
Also on Rumble: https://rumble.com/c/c-1115371

idTech 4 (aka Doom 3 tech) Discord Server! https://discord.gg/9wtCGHa

Main Menu

Plasma Gun Material

Started by spamclark15, August 07, 2017, 04:30:22 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

spamclark15

Something I'm trying to fix is the player shadow being cast on the Plasma gun. This is the only gun that has this behavior, and also the only gun that will cast a shadow of itself onto objects like dead monsters. The pictures show the player shadow casting ugly shadows on the top of the plasma gun, the plasma gun casting a shadow on a dead pinky, and for comparison, the machine gun, which does not do this. What is going on?

Snehk

Check the material if there is noShadows or noSelfShadow. Maybe plasma gun material doesn't have those?

spamclark15

...and that was it. The world mesh is missing noSelfShadow so I added it and it fixes both problems? Are the viewmesh and worldmesh separate? I figured the game handled them separately but apparently not if flags on one affect the other?

Snehk

Viewmesh and worldmesh are separate models, guess that they use the same material for both of them?

spamclark15

No, if they shared a material then they'd be using the same textures as well.

Phrozo

#5
There is a separate material for world and view models. Put noShadows on the plasmagun world material and noSelfShadow on the plasmagun view material.

spamclark15

All it took was noSelfShadow on the world model material. As weird as that is, it prevents player shadows from appearing on the view model material as well. This is why there's more than meets the eye with this I think.