Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / Repositioning Light 0

Author
Message
Inflictive
17
Years of Service
User Offline
Joined: 16th Jun 2009
Location: Altis
Posted: 14th Nov 2011 04:38
So, It seems to me that most games involve the player walking around on a planet's surface, and for that type of game, having light 0 fixed being up in the sky, like a big wave of light coming down from above, seems like a good thing.

But I'm making a space shooter, and the sun won't be directly above you. It will be to the side of you, so I want sunlight(light 0) to come in from the X or Z axis, not the Y axis. Is there a way, by commands or changing the compiler's dlls, to reposition light 0 so it comes from the x or z axis? I know I could just make another light, but you can only have 7 at a time and I want to have free as many as I can. And I know I could write my game so everything sort of happens sideways, but all that just to save 1 light...? Isn't there an easier way?

Thanks

Your signature has been erased by a mod - Please reduce it to (600x120) maximum size
Sixty Squares
20
Years of Service
User Offline
Joined: 7th Jun 2006
Location: Somewhere in the world
Posted: 14th Nov 2011 05:30
I believe POSITION LIGHT works for any light, including light 0. Have you tried that?

When I want to reposition light 0 I tend to use POSITION LIGHT and SET POINT LIGHT, specifying the same coordinates for each.

ex.
x# = something
y# = something
z# = something

Position Light 0, x#, y#, z#
Point Light 0, x#, y#, z#

Hope this helps!


Guns, cinematics, stealth, items and more!
Inflictive
17
Years of Service
User Offline
Joined: 16th Jun 2009
Location: Altis
Posted: 16th Nov 2011 03:17
I tried position but it didn't work. But I figured it out-use the rotate light command!

Your signature has been erased by a mod - Please reduce it to (600x120) maximum size
Inflictive
17
Years of Service
User Offline
Joined: 16th Jun 2009
Location: Altis
Posted: 16th Nov 2011 06:00
Update: ok, position light then point light works too.

Your signature has been erased by a mod - Please reduce it to (600x120) maximum size

Login to post a reply

Server time is: 2026-07-10 01:59:14
Your offset time is: 2026-07-10 01:59:14