generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Blue fog not turning on

Previous Thread :: Next Thread 
austint30 is not online. austint30
Joined: 20 Mar 2010
Total Posts: 1482
06 Jun 2014 04:05 PM
I made a code that successfully changed the fog black, but it doesn't turn the lighting to blue.
__________________________________________________
local Lighting = game:GetService("Lighting")

function onLightingChanged()

if Lighting.TimeOfDay == "6:00:00" then
Lighting.FogColor = Color3.new(180, 255, 234) --Day
print("Day time")
end

if Lighting.TimeOfDay == "18:00:00" then
Lighting.FogColor = Color3.new(0, 0, 0) --Night
print("Night time")
end
end


Lighting.LightingChanged:connect(onLightingChanged)

__________________________________________________


I can't figure out why it is not turning blue when it turns daytime.
Report Abuse
Quasar99 is not online. Quasar99
Joined: 21 Nov 2009
Total Posts: 9328
06 Jun 2014 04:06 PM
color 3 values are in between 0 and 1, so it has to be a fraction over /255.

e.g it would be:

Color3.new(180/255, 1, 234/255)
Report Abuse
austint30 is not online. austint30
Joined: 20 Mar 2010
Total Posts: 1482
06 Jun 2014 04:07 PM
I tried and nothing changed.
Report Abuse
Quasar99 is not online. Quasar99
Joined: 21 Nov 2009
Total Posts: 9328
06 Jun 2014 04:08 PM
well then i'm stumped.
Report Abuse
austint30 is not online. austint30
Joined: 20 Mar 2010
Total Posts: 1482
06 Jun 2014 04:09 PM
It also prints "Night time" 4 times for some reason.
Report Abuse
austint30 is not online. austint30
Joined: 20 Mar 2010
Total Posts: 1482
06 Jun 2014 04:39 PM
help
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image