Author Topic: Request: SEXP to change ambient lighting  (Read 4349 times)

0 Members and 1 Guest are viewing this topic.

Offline Tolwyn

  • The Admiral
  • Administrator
  • 214
  • Ridiculously Old Fraud
    • Wing Commander Saga
Request: SEXP to change ambient lighting
I'd like to request a new feature: a SEXP to change ambient lighting (or star count) during a mission.

Right now it is already possible to set ambient lightning (level/color) in FRED. Default value is RGB=120, 120, 120, I believe. So a system with red nebulas and blue sun, would have rather red ambient lighting while the direct light is still the blue one from the sun. Now, missions which include jumping from one system to another are a problem. It is possible to change background bitmaps, suns and skyboxes, but not lighting (or star count for that matter).

It would greatly enchance visual quality if such a SEXP would be added. ;) Otherwise we would have to use basic white ambient light for all star systems (since otherwise jumping to a different system doesn't work).
Wing Commander Saga: A Legend Is Reborn | WingCenter
 
Tolwyn’s reputation for risk taking with other people’s lives was considered  to understate the facts. The admiral’s willingness to sacrifice anyone or anything to achieve his objectives had long been lauded in the popular press. He was “the man who got things done”.- Colonel Blair

No errors, no random CTDs, just pure fun and proof of why getting hit with missiles is a bad thing.
-WC Saga's beta tester


Report Wing Commander Saga bugs with Mantis

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Request: SEXP to change ambient lighting
I've not looked at the code but the only problem I see with this one is if the light levels are processes in some way at the start of the mission and then the game uses the processed version.

Otherwise we're looking at 10 minutes work. I have to test another feature in multiplayer tomorrow anyway so I'll kill two birds and take a look at this one at the same time.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Tolwyn

  • The Admiral
  • Administrator
  • 214
  • Ridiculously Old Fraud
    • Wing Commander Saga
Re: Request: SEXP to change ambient lighting
Thanks. Much appreciated. ;)
Wing Commander Saga: A Legend Is Reborn | WingCenter
 
Tolwyn’s reputation for risk taking with other people’s lives was considered  to understate the facts. The admiral’s willingness to sacrifice anyone or anything to achieve his objectives had long been lauded in the popular press. He was “the man who got things done”.- Colonel Blair

No errors, no random CTDs, just pure fun and proof of why getting hit with missiles is a bad thing.
-WC Saga's beta tester


Report Wing Commander Saga bugs with Mantis

 
Re: Request: SEXP to change ambient lighting
I've not looked at the code but the only problem I see with this one is if the light levels are processes in some way at the start of the mission and then the game uses the processed version.

I doubt that's the case.. I mean you can add and remove suns during a mission. So you change the specular ligth color and light sources. I see no real reason why then you shouldn't be able to change ambient color as well. I haven't looked at the code yet but I'm pretty sure that shouldn't be a problem.

If you do this you might also want to add a SEXP to change the star count. Saga doesn't use this but I'm sure other mods might appreciate the ability to change that also during a mission.

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Request: SEXP to change ambient lighting
I doubt it's the case either. But it's the only way I could see the SEXP being a problem.
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline karajorma

  • King Louie - Jungle VIP
  • Administrator
  • 214
    • Karajorma's Freespace FAQ
Re: Request: SEXP to change ambient lighting
Turned out in the end that it was indeed calculated at mission start and never touched again. That probably doubled the time it took me to make it work (although that was still only 20 minutes) :D

I've just posted a build which supports this in recent builds but WCS might have another reason for checking it out. :D
Karajorma's Freespace FAQ. It's almost like asking me yourself.

[ Diaspora ] - [ Seeds Of Rebellion ] - [ Mind Games ]

 

Offline Tolwyn

  • The Admiral
  • Administrator
  • 214
  • Ridiculously Old Fraud
    • Wing Commander Saga
Re: Request: SEXP to change ambient lighting
Sweet. I feel like a sack full full of potatoes at the moment, but I will try it out tomorrow. ;)
Wing Commander Saga: A Legend Is Reborn | WingCenter
 
Tolwyn’s reputation for risk taking with other people’s lives was considered  to understate the facts. The admiral’s willingness to sacrifice anyone or anything to achieve his objectives had long been lauded in the popular press. He was “the man who got things done”.- Colonel Blair

No errors, no random CTDs, just pure fun and proof of why getting hit with missiles is a bad thing.
-WC Saga's beta tester


Report Wing Commander Saga bugs with Mantis