Jibble

Author Topic: PLUGIN: Flashlight plugin v1.2  (Read 13714 times)

Slasher

  • slasher
    • I can help with AGS tutoring
    • Lifetime Achievement Award Winner
    • I can help with scripting
    • I can help with story design
    • Slasher worked on one or more games that won an AGS Award!
    •  
    • Slasher worked on one or more games that was nominated for an AGS Award!
SOLVED: Turn off Flashlight 1.2.1
« Reply #20 on: 27 Sep 2012, 06:31 »
I am using Flashlight plugin 1.2.1 by Andreas Vogel and I can't seem to turn it off.

I was ok, if I remember, with and older version.

After using it in a darkened room and then going back to previous room I have the room state set to background 1 and the player back to normal views. However at most I clear the follow character spotlight but the room looks 'washed'.

Tried
Code: Adventure Game Studio
  1. SetFlashlightDarkness (GetFlashlightMaxLightLevel ());

Are you able to assist:

many thanks

« Last Edit: 27 Sep 2012, 19:41 by slasher »

Gilbert

  • Local Moderator
  • * KILL* * KILL * * KILL *
    • Lifetime Achievement Award Winner
Re: PLUGIN: Flashlight plugin v1.2
« Reply #21 on: 27 Sep 2012, 06:43 »
(Merged with the plugin's thread.)

I'm not sure as I have never used it, but since the plugin is rather old there may be some compatibility problems (people more familiar with the plugin may be able to share some light on this). You may also try the module version which is a bit newer.
« Last Edit: 27 Sep 2012, 06:47 by Iceboty V7000a »

Slasher

  • slasher
    • I can help with AGS tutoring
    • Lifetime Achievement Award Winner
    • I can help with scripting
    • I can help with story design
    • Slasher worked on one or more games that won an AGS Award!
    •  
    • Slasher worked on one or more games that was nominated for an AGS Award!
Re: PLUGIN: Flashlight plugin v1.2
« Reply #22 on: 27 Sep 2012, 13:50 »
Flashlight Version 1.2.1

I was having trouble turning it off.

For those that may come across my scenereo I have made 2 buttons: light on and light off which controls flashlight on and off. I can also switch it on via a light item in the inventory which i use on player. I have 2 backgrounds: black room (background 0) and the main room background 1.

This is what I used:

Code: Adventure Game Studio
  1. function Blighton_OnClick(GUIControl *control, MouseButton button)
  2. {
  3.   SetBackgroundFrame(1);
  4.  
  5.   cELF.ChangeView(40);
  6.   cELF.SpeechView=41;
  7.   cELF.SetIdleView(42, 0);
  8.  
  9.   SetFlashlightDarkness (20);
  10.   SetFlashlightBrightness (GetFlashlightMaxLightLevel ());
  11.   SetFlashlightDarknessSize (50);
  12.   SetFlashlightBrightnessSize (100);
  13.   SetFlashlightFollowCharacter ( (1), 0, -20, 20, 10);
  14. }
  15.  
  16.     function Blightoff_OnClick(GUIControl *control, MouseButton button)
  17.    {
  18.     cELF.ChangeView(3);
  19.     cELF.SpeechView=4;
  20.     cELF.SetIdleView(12, 0);
  21.  
  22.     SetBackgroundFrame(0);
  23.     SetFlashlightBrightness (GetFlashlightMaxLightLevel ());
  24.    }


sorted
« Last Edit: 27 Sep 2012, 19:40 by slasher »