player shadow on ground

Posted By: Delirium

player shadow on ground - 11/06/11 12:42

I'd like to put a shadow just below the players feet, all the time. I tried writing a player_shadow action to attach to a simple ball I squashed vertically, then set it translucent. I also tried adding something like player.shadow = on; in the player action. I finally got a large level working and the character walking around. It just looks unnatural without some kind of shadow below the player. Probably ditto the npcs in the level so I'd like to know the right way to put shadows at model's feel. Your help is appreciated. perhaps some kind of shadow casting light? Seems a transparent grey sprite or something would work well enough.
Posted By: Superku

Re: player shadow on ground - 11/06/11 12:47

I know you're just starting with lite-C, but the searchable manual answers this question in 1 second. wink
Write "set(my,SHADOW);" in the player action. The default shadow is a decal shadow, you may or may not want to have stencil shadows or even shadow mapping/ PSSM (see manual).
Posted By: Delirium

Re: player shadow on ground - 11/06/11 12:59

Thank you. The only defense I can offer for not finding that in the manual is that between studying the code in examples I've downloaded and the many help systems there is a lot to go through, and my time to be at my computer when family isn't distracting me is precious. I apologize. This should have been in a beginning forum category. Code is just, you know, unforgiving. A single bracket overlooked can drive you to pulling your hair out.
© 2024 lite-C Forums