Reduced visibility during night time only

Moderators: rbodleyscott, Slitherine Core, Gothic Labs

Post Reply
Paul59
General - King Tiger
General - King Tiger
Posts: 3800
Joined: Tue Jul 21, 2015 11:26 pm

Reduced visibility during night time only

Post by Paul59 »

Just a quick scripting question!

In many of my scenarios I have used the reduced visibility script from the vanilla Lutzen scenario. I am now designing a battle that starts during the night (2.30am) and goes on into the morning. How do I reduce visibility only for the hours of darkness?


Cheers


Paul
Field of Glory II Scenario Designer - Age of Belisarius, Rise of Persia, Wolves at the Gate and Swifter than Eagles.

Field of Glory II Medieval Scenario Designer.

FOGII TT Mod Creator

Warhammer 40,000: Sanctus Reach Tournament Scenario Designer.
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28007
Joined: Sun Dec 04, 2005 6:25 pm

Re: Reduced visibility during night time only

Post by rbodleyscott »

Paul59 wrote:Just a quick scripting question!

In many of my scenarios I have used the reduced visibility script from the vanilla Lutzen scenario. I am now designing a battle that starts during the night (2.30am) and goes on into the morning. How do I reduce visibility only for the hours of darkness?
Surround the reduced visibility code with a conditional statement so that it only functions before a certain turn.

e.g.

Code: Select all

if (GetTurn() < 13)
  {
     // Reduced visibility code here
  }
Richard Bodley Scott

Image
Paul59
General - King Tiger
General - King Tiger
Posts: 3800
Joined: Tue Jul 21, 2015 11:26 pm

Re: Reduced visibility during night time only

Post by Paul59 »

Thanks Richard, that seems to have worked.
Field of Glory II Scenario Designer - Age of Belisarius, Rise of Persia, Wolves at the Gate and Swifter than Eagles.

Field of Glory II Medieval Scenario Designer.

FOGII TT Mod Creator

Warhammer 40,000: Sanctus Reach Tournament Scenario Designer.
edward77
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 231
Joined: Wed Nov 10, 2010 9:11 pm

Re: Reduced visibility during night time only

Post by edward77 »

Richard, Is it possible to change the lighting with code?
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28007
Joined: Sun Dec 04, 2005 6:25 pm

Re: Reduced visibility during night time only

Post by rbodleyscott »

edward77 wrote:Richard, Is it possible to change the lighting with code?
What exactly do you want to achieve?
Richard Bodley Scott

Image
edward77
Sergeant - 7.5 cm FK 16 nA
Sergeant - 7.5 cm FK 16 nA
Posts: 231
Joined: Wed Nov 10, 2010 9:11 pm

Re: Reduced visibility during night time only

Post by edward77 »

I am ok with changing visibility but how do you create the dawn effect with the light becomes gradually stronger in subsequent turns?
rbodleyscott
Field of Glory 2
Field of Glory 2
Posts: 28007
Joined: Sun Dec 04, 2005 6:25 pm

Re: Reduced visibility during night time only

Post by rbodleyscott »

edward77 wrote:I am ok with changing visibility but how do you create the dawn effect with the light becomes gradually stronger in subsequent turns?
I have no idea.

I noticed that happened with some scenarios by other designers, but I don't know how they did it.
Richard Bodley Scott

Image
Odenathus
Staff Sergeant - StuG IIIF
Staff Sergeant - StuG IIIF
Posts: 287
Joined: Sat Jun 27, 2009 10:02 pm

Re: Reduced visibility during night time only

Post by Odenathus »

Only just seen this so probably too late. I think it's built into the game, so the calendar says such and such darkness setting will show from e.g. four a.m. to six a.m., then another setting from six a.m. to eight a.m., then full daylight from eight a.m. to whenever, so you just need to adjust the time settings, and possibly the length of the game turns,all via the Calendar setting, to get the effect that you want. I think.
Post Reply

Return to “Scenario Design”