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.

FPSC Classic Scripts / Sun effect in FPSC

Author
Message
cptTomas
15
Years of Service
User Offline
Joined: 18th Aug 2010
Location:
Posted: 31st Aug 2010 15:57
Please can some explain me this lines in the setup.ini?
lightmapsunx=0
lightmapsuny=-1
lightmapsunz=0
lightmapsunr=0
lightmapsung=0
lightmapsunb=0
I read the setup description, but I'm cofused if the sun point in fpsc is really working?
Conjured Entertainment
AGK Developer
20
Years of Service
User Offline
Joined: 12th Sep 2005
Location: Nirvana
Posted: 1st Sep 2010 21:34 Edited at: 1st Sep 2010 21:37
Quote: "Please can some explain me this lines in the setup.ini?
lightmapsunx=0
lightmapsuny=-1
lightmapsunz=0
lightmapsunr=0
lightmapsung=0
lightmapsunb=0
I read the setup description, but I'm cofused if the sun point in fpsc is really working? "

I am not sure because I have not messed around with it, but just guessing...
the _X _Y _Z would be coordinates for the Sun's position in the 3d environment, and the _R _G _B would be the values for the color assignment in an RGB triplet form.

   Conjured Entertainment

 WARNING: Intense Madness
Plystire
23
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 4th Sep 2010 03:10
The sun is a directional light, and will effect everything in the environment. The X, Y, Z settings will set the light's direction normal. So, the current setting of X=0, y=-1, z=0 will make the sun's light shine straight down.

NOTE: Since the coords are a "normal" then the vector length should (by definition of a normal) be equal to 1. So to give a 45 degree shine on the X axis you would use the settings: x=0.707, y=-0.707, z=0 (Someone can check my math on that, lol) Though, if I recall FPSC should let you just use: x=1, y=-1, z=0. To get the same effect.


And, as Conjured pointed out, the R G B values are for the color.


The one and only,


cptTomas
15
Years of Service
User Offline
Joined: 18th Aug 2010
Location:
Posted: 4th Sep 2010 15:31
Thanks for help, but it doesn't work.
I set RGB to 255, 214, 077. The coordinations as you written to 45 degrees (so x=1, y=-1, z=0).
I tried it in test mode but with no solution (like there wasn't any light source). I also move the player mark to the lower floor.

I'm thinking about the coordinates - doesn't it meant as 1 number is every square or layer? And how to correctly calculate the sun angle?
Flatlander
FPSC Tool Maker
19
Years of Service
User Offline
Joined: 22nd Jan 2007
Location: The Flatlands
Posted: 4th Sep 2010 16:44 Edited at: 4th Sep 2010 17:04
Maybe one could email knxrb, hockeykid or Marc Steene and ask them if they know anything about it? I'm sure hockeykid is busy starting school now so maybe one shouldn't bother him.

This feature definitely sounds interesting and therefore I'm going to take a look at the source code myself.

Addendum:

It seems that it should work in test mode but have you tried building a stand-alone game with those settings.

I looked at the source code. The only code that might do anything is the following:



Add Directional Light is a special LM command that is probably found in a DLL specifically for FPSC and not DBPro. It is definitely outside of the scope for DBPro because there is no help available for it. So, I'm not sure exactly what the x,y,z values should be in reference to the 3D coordinate grid. Also, it is interesting to note that the rgb (I'm sure that's what they are) are divided by 100.

Plystire, I'm clueless in Lincoln. Any ideas?

I reject your reality and substitute my own!

Add more adventure to your game -- use RPG Mod
knxrb
FPSC Tool Maker
17
Years of Service
User Offline
Joined: 10th Oct 2008
Location: United Kingdom
Posted: 4th Sep 2010 21:03
This is what Lee has told me about it:
Quote: "They were added for DarkLIGHTS but are not exposed in the engine, and have
remained as default values since then. Consider them an unimplemented feature."


knxrb
Flatlander
FPSC Tool Maker
19
Years of Service
User Offline
Joined: 22nd Jan 2007
Location: The Flatlands
Posted: 4th Sep 2010 21:54 Edited at: 4th Sep 2010 21:55
Darn, thanks knxrb for finding out for us. Oh well.

I reject your reality and substitute my own!

Add more adventure to your game -- use RPG Mod
cptTomas
15
Years of Service
User Offline
Joined: 18th Aug 2010
Location:
Posted: 4th Sep 2010 23:17
Thank you very much that was the main point what I wanted to know.
vortech
16
Years of Service
User Offline
Joined: 18th Mar 2010
Location: Finland
Posted: 5th Sep 2010 17:41
Why he didn't added whole darkLIGHTS into fpsc


Check for pure horror.
cptTomas
15
Years of Service
User Offline
Joined: 18th Aug 2010
Location:
Posted: 5th Sep 2010 22:55
beacause he planned it to next version 118 or 119
knxrb
FPSC Tool Maker
17
Years of Service
User Offline
Joined: 10th Oct 2008
Location: United Kingdom
Posted: 5th Sep 2010 23:35 Edited at: 6th Sep 2010 00:03
Quote: "Why he didn't added whole darkLIGHTS into fpsc"

DarkLIGHTS is in the engine already, it's a lightmapping plugin and not a dynamic lighting plugin.

knxrb
Brunopark09
16
Years of Service
User Offline
Joined: 7th Jul 2010
Location: Santiago de Chile
Posted: 6th Sep 2010 01:41
Quote: "DarkLIGHTS is in the engine already, it's a lightmapping plugin and not a dynamic lighting plugin."


but, will we ever have the ability to direct ligths?

-Why didn't God take gaga,justin bieber or kesha instead of Randy Rhoads, Cliff Burton or Dio?
Nbt
16
Years of Service
User Offline
Joined: 11th Oct 2009
Location: Behind you!!
Posted: 6th Sep 2010 22:48
Quote: "but, will we ever have the ability to direct ligths?
"


Already have that ability to an extent, using light cones, cylinders etc to create spotlights and other directional lighting (as I said to an extent)

Plystire
23
Years of Service
User Offline
Joined: 18th Feb 2003
Location: Staring into the digital ether
Posted: 7th Sep 2010 03:29
Those type of lights are not "directional lighting", though, Nbt.

Directional lighting is a global lighting that effects everything in the scene... it does not come from a specific point and so does not require a position in 3D space. All that it requires is a direction normal to specify which direction the global light shines in.

Quote: "note that the rgb (I'm sure that's what they are) are divided by 100.

Plystire, I'm clueless in Lincoln. Any ideas?"


Try using 100 as the max value for colors in your settings. It is likely that DarkLIGHTS is expecting a normalized value for color settings (0.0 - 1.0)

Also, please note that since this is the sun, you may need to use an outside scene to see if the lighting effect is working, as I'm unsure if indoor areas will be effected by this (what with having a ceiling and all )

If that doesn't work, Lee may have disabled this feature elsewhere in the source as I am positive the feature itself functions with DarkLIGHTS. (I've used this in a seperate project)


The one and only,


Login to post a reply

Server time is: 2026-07-26 05:21:34
Your offset time is: 2026-07-26 05:21:34