Source sdk player shadow

Avatar
Thehungrycore
8 Posts
Posted Nov 01, 2012
I'm not sure if i have posted this in the right section, but if anyone could answer this only question.
Is there any way to get the player shadow in portal, or will i end up coding everything?
Advertisement
Registered users don't see ads! Register now!
Avatar
UsCobra11
272 Posts
Posted Nov 01, 2012
Replied 1 hour later
You can make shadows with light. Try using an env_projected_texture. This light entity can create nice looking shadows. You can also mess around with a shadow_control entity.
Avatar
ChickenMobile
2,460 Posts
Posted Nov 02, 2012
Replied 1 day later

UsCobra11 wrote:
You can make shadows with light. Try using an env_projected_texture. This light entity can create nice looking shadows. You can also mess around with a shadow_control entity.

I thought the players couldn't see their shadows whatsoever unless they were in thirdperson view.

Avatar
Lpfreaky90
2,842 Posts
Posted Nov 02, 2012
Replied 11 minutes later

ChickenMobile wrote:
UsCobra11 wrote:

You can make shadows with light. Try using an env_projected_texture. This light entity can create nice looking shadows. You can also mess around with a shadow_control entity.

I thought the players couldn't see their shadows whatsoever unless they were in thirdperson view.

nor can players see their own reflections in first person.

Avatar
UsCobra11
272 Posts
Posted Nov 02, 2012
Replied 20 minutes later
Hmm. I'm not sure then. I don't think it's that important of a thing, though.
Avatar
Sprowl
97 Posts
Posted Nov 02, 2012
Replied 24 minutes later
There are two things I can say to that topic:
First: sometimes I see real shadows on my portalgun from an env_projectedtexture like it does in CS:GO. I don't why this happens, but it does sometimes.
Second: You could turn on the thirdpersonview and move the camera to a first-person view (should be possible somehow). Or you could use a point_viewproxy (the same entity was used in the container scene at the beginning of the game). I don't know if you see yourself while using it, but it's worth a try.
Avatar
greykarel
225 Posts
Posted Nov 12, 2012
Replied 9 days later
Sexy shadow, ain't it?


There's a workaround to have the player shadow in firstperson. Just attach chell model to info_player_start and in logic_auto set OnMapSpawn >> chell >> SetParent >> !player. In model properties set minimum fade out distance. This way env_projected_texture will cast model's shadow. Though the shadow has no portalgun.

Advertisement
Registered users don't see ads! Register now!