Search Unity

  1. Check out our Unite Austin 2017 YouTube playlist to catch up on what you missed. More videos coming soon.
    Dismiss Notice
  2. Unity 2017.2 is now released.
    Dismiss Notice
  3. The Unity Gear Store is here to help you look great at your next meetup, user group or conference. With all new Unity apparel, stickers and more!
    Dismiss Notice
  4. Introducing the Unity Essentials Packs! Find out more.
    Dismiss Notice
  5. Want to see the most recent patch releases? Take a peek at the patch release page.
    Dismiss Notice
  6. Unity 2017.3 beta is now available for download.
    Dismiss Notice

[SALE] Screen Fader 1.6 - Screen transitions with effects in one line of code

Discussion in 'Assets and Asset Store' started by Patico, Oct 28, 2013.

  1. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Screen Fader
    [​IMG]

    Main features:
    - Screen transitions with different effects
    - Fading of GameObjects
    - Fading of UI elements
    - Load Levels with fading effect
    - Makes any fading with one line of code

    - Chain calls, like: Fader.Instance.FadeIn().Pause(10).FadeOut()
    - Easy to extend with own Actions and Coroutines
    - Dynamic change of fading color
    - Compatible with Unity 5
    - Friendly Price



    This easy-to-use script will allow you to fade in or out your screen with only one line of code, so all you need is to write:
    Code (csharp):
    1. Fader.Instance.FadeIn();
    Very easy, but on the other hand, you will get infinite possibilities. You can fade the screen, UI elements or objects, change the speed and colors, join methods in chains, call Coroutines and your own actions. You can subscribe on events and get notifications when fading will be started or completed. Screen Fader also supports fluent interface, so you can make more readable code with chains of methods, for example:
    Code (csharp):
    1. Fader.Instance.FadeIn().Pause(10).FadeOut();
    This script also support invoking of coroutines and any actions (it's realy any actions that implement IAction or IParametrizedAction interface), so you can write such sequences:
    Code (csharp):
    1. Fader.Instance.FadeIn().StartCoroutine(this, PostMyScoreCoroutine()).FadeOut();
    2. //or
    3. Fader.Instance.FadeIn().StartAction(new MyMostLovelyAction(), parameter).FadeOut()
    At the last version (1.3) was added LoadLevel method, and fading of game objects:
    Code (csharp):
    1. /// Load "Scene2", it's also possible to load level by its index
    2. Fader.Instance.FadeIn().Pause().LoadLevel("Scene2").FadeOut(2);
    3.  
    4. /// Hide character
    5. Fader.Instance.FadeIn(characterGameObject);
    This works well on Free and Pro Unity, suitable for Web, Standalone, Android and iOS platform. And all this takes less then 50kb on your drive and costs less then your morning coffee.

    So, the another features of Screen Fader are:
    - Easy-to-use, easy-to-write and easy-to-read what you wrote - it is just one line of code!
    - Powerfull sequences
    - Possibility to call coroutines
    - Possibility to make you own actions
    - All Screen Fader's code gathered into couple of files, that takes only 10kb.
    ...and some other cool features are coming soon...

    What is more: you'll get 2 extra scripts that will allow you to fade your screen with squares or stripes effect, and of course you can also setup their additional parameters, such as number of stripes or squares and direction of effect.

    API Example of usage screenshots

    $0e395ed2-58ec-4ccc-9849-bebd9df0307f_orig.jpg

    $6aba571c-a9cb-404e-a413-3ca2f7c0e2fc_orig.jpg

    [​IMG]

    API Help
    Table of content
    - FadeIn
    - FadeOut
    - Pause
    - Flash
    - LoadLevel
    - SetColor
    - StartAction
    - StartCoroutine
    - StopAllFadings


    FadeIn( time )
    Fade-in screen in 'time' seconds. 'time' argument is optional, default value - 1.
    Code (csharp):
    1. Fader.Instance.FadeIn();
    2. Fader.Instance.FadeIn( 3 ); /// Fade screen in in 3 seconds

    FadeIn( GameObject, time )
    FadeIn( UI.Element, time )
    FadeIn( UI.Image, time )

    Fade-in gameobject. GameObject's material should support transparency. 'time' argument is optional, default value - 1.
    Code (csharp):
    1. /// Hide characterGO in 3 seconds
    2. Fader.Instance.FadeIn( characterGO, 3 );
    3. /// Change character’ hemlet
    4. Fader.Instance.FadeIn( HemletOfWarion ).FadeOut( HemletOfKing );

    FadeOut( time )

    Fade screen out in 'time' seconds. 'time' argument is optional, default value - 1.
    Code (csharp):
    1. Fader.Instance.FadeOut();
    2. Fader.Instance.FadeOut( 3 ); /// Fade screen out in 3 seconds
    FadeOut( GameObject, time )
    FadeOut( UI.Element, time )
    FadeOut( UI.Image, time )

    Fade gameobject out. GameObject's material should support transparency. 'time' argument is optional, default value - 1.
    Code (csharp):
    1. /// Hide wall and show Enemy Boss character.
    2. Fader.Instance.FadeOut( Wall ).FadeIn( EnemyBoss );

    Pause( time )
    Make pause in chain of fadings or actions.
    Code (csharp):
    1. Fader.Instance.FadeIn().Pause().FadeOut();  /// pause 1 second
    2. Fader.Instance.FadeIn().Pause( 3 ).FadeOut(); /// pause 3 second
    Flash( inTime, outTime )
    Make flash - quick fade-in and fade-out. Arguments inTime and outTime are optional. Default values are inTime = 0.075, outTime = 0.15
    Code (csharp):
    1. Fader.Instance.Flash();
    2. Fader.Instance.Flash( 0.1, 3 ); /// Quickly fade screen in and slowly out
    LoadLevel( name )
    Load new scene by its name
    Code (csharp):
    1. Fader.Instance.LoadLevel( "IntroScene" );
    2. Fader.Instance.FadeIn().LoadLevel( "Scene-1" ).FadeOut();
    LoadLevel( index )
    Load new scene by its index
    Code (csharp):
    1. Fader.Instance.LoadLevel( 1 );
    2. Fader.Instance.FadeIn().LoadLevel( 1 ).FadeOut();
    SetColor( color )
    Default color of fading is black, but this method allow changing of color at runtime.
    Code (csharp):
    1. Fader.Instance.SetColor( Color.white ).FadeIn().LoadLevel( 0 ).FadeOut();
    2. Fader.Instance.SetColor( Color.red ).Flash(); /// Damage - red flash

    StartAction( IAction )

    Execute a custom action. Custom action is an instance of class implementing IAction interface. Here is an example:
    Code (csharp):
    1. HidePrincessAction action = new HidePrincessAction();
    2. Fader.Instance.StartAction( action );
    3.  
    4. /// Hide princess while screen is faded, and then fade screen out.
    5. Fader.Instance.FadeIn().StartAction( action ).FadeOut();  
    IAction interface, defines Execute() method that will be called and Completed property, that you should set to 'true' when action will completed:
    Code (csharp):
    1. public interface IAction
    2. {
    3.   bool Completed { get; set; }
    4.   void Execute();
    5. }
    6.  
    7. public interface HidePrincessAction: IAction
    8. {
    9.   public bool Completed { get; set; }
    10.   public void Execute()
    11.   {
    12.   GameObject.Find("MarioPrincess").GetComponent<Renderer>().enabled = false;
    13.  
    14. /// It lets screen fader know that action is completed
    15. /// and next action could started.
    16.   this.Completed = true;
    17.   }
    18. }
    StartAction( IParametrizedAction, object[] )
    Execute a custom action that accept some parameters. Here, custom action is an instance of class implementing IParametrizedAction interface. Let's improve our example:
    ChangeCharacterAction param_action = new ChangeCharacterAction();
    Code (csharp):
    1. /// Hide Mario and show Princess
    2. Fader.Instance.StartAction( param_action, "Mario", "Princess" );
    3. /// Hide Princess and show Mario
    4. Fader.Instance.StartAction( param_action, "Princess", "Mario" );
    IParametrizedAction's Execute() method can get any number of parameters. See the implementation of ChangeCharacterAction:
    Code (csharp):
    1. public interface ChangeCharacterAction: IParametrizedAction
    2. {
    3.   public bool Completed { get; set; }
    4.   public void Execute( params object[] args )
    5.   {
    6.   GameObject.Find( args[0] ).GetComponent<Renderer>().enabled = false;
    7.   GameObject.Find( args[1] ).GetComponent<Renderer>().enabled = true;
    8.  
    9. /// It lets screen fader know that action is completed
    10. /// and next action can be started.
    11.   this.Completed = true;
    12.   }
    13. }
    StartCoroutine( MonoBehaviour, Coroutine )
    Start coroutine method in series. Next fading tasks will be starter after coroutine finish. MonoBehaviour is an game object where coroutine ( IEnumerator method ) located. NOTE: This Conoutine's methods have to have 'yield break' operator!
    Code (csharp):
    1. /// Show 'Game Over' for 5 sec and fade-in screen.
    2. Fader.Instance.StartCoroutine( this, ShowGameOver() ).Pause( 5 ).FadeIn();
    3.  
    4. ...
    5.  
    6. IEnumerator ShowGameOver()
    7. {
    8.   text.text = "Game Over";
    9.   yield return new WaitForSeconds( 5 );
    10. }

    StartCoroutine( MonoBehaviour, methodName, methodParameter )

    Start coroutine method in parallel and pass parameter to it. Next fading tasks will be starter right after coroutine was started.
    Code (csharp):
    1. /// Show 'You Game is Over, Mario' text for 5 sec and fade-in screen.
    2. Fader.Instance.StartCoroutine( this, "ShowGameOver", "Mario" ).Pause( 5 ).FadeIn();
    3.  
    4. ...
    5.  
    6. IEnumerator ShowText( string name )
    7. {
    8.   text.text = "You Game is Over, " + name;
    9.   yield return new WaitForSeconds( 5 );
    10. }
    StopAllFadings()
    Brakes all fadings immediately.
    Code (csharp):
    1. Fader.Instance.StopAllFadings();
    Video tutorial:

    Thank you!
     

    Attached Files:

    Last edited: May 15, 2015
  2. carinha

    carinha

    Joined:
    Nov 29, 2013
    Posts:
    4
    is it possible to make a fade in/out for the children of a specific gameobj without fade in/out all the scene ?
     
    Patico likes this.
  3. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    I'm not sure that I understand you correctly. Do you mean to fade-in/out gameobject - in other words to hide or show gameobject smoothly?

    [UPDATE]
    Yes, I've just released an update, and now it is possible.

    Check out new demo and try (Object Fading button): http://patico.pro/Content/ScreenFader/Demo_1_3/ it also include a code samples, so you can see how to use it.
     
    Last edited: Jul 26, 2014
  4. imtrobin

    imtrobin

    Joined:
    Nov 30, 2009
    Posts:
    1,534
    Hi Patico, sent you a email on issues couple of weeks ago, you have not replied.
     
  5. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi,Robin! Thanks for notifying me, I've just found your emails amongs the tons of spam messages. I will reply you today.
     
  6. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi, Robin
    I've send you an e-mail.
     
  7. imtrobin

    imtrobin

    Joined:
    Nov 30, 2009
    Posts:
    1,534
    Hi Patico, didn't get your email. Where did u send it to?
     
  8. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi, I send it to ...@cyberversion.com, I hope it is your email.
    Send again via PM on this site. Check out Notifications.
     
  9. imtrobin

    imtrobin

    Joined:
    Nov 30, 2009
    Posts:
    1,534
    Hmm, Got your pm. but didn't get your email. I don't have any spam filters.
     
  10. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    New version of Screen Fader now available on Asset Store.
    Update unclude some new features:
    - LoadLevel() method (see screenshot bellow)
    - GameObjects fading (2D and 3D)
    - Changing fade color at runtime via SetColor() method

    Check out new demo with code samples: http://patico.pro/Content/ScreenFader/Demo_1_3/

    [​IMG]
     
  11. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Some new features added in version 1.3:
    [​IMG]
     
  12. cfxzscv

    cfxzscv

    Joined:
    Apr 29, 2014
    Posts:
    5
    Is there anyway to separate fading by camera or layer ?
     
  13. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi, to avoid misunderstanding, could you describe what do you mean by "separate by camera" and "separate by layer"?
     
  14. cfxzscv

    cfxzscv

    Joined:
    Apr 29, 2014
    Posts:
    5
    For example i have 2 cameras: ui camera and scene camera and i want limit fading to only scene camera therefore ui is always visible and is not affected by fading.
    .
    Same goes to the layers if i want fade only this partical layer.
     
  15. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Well, understand you now. Unfortunately such features not implemented in current version. I'll consider about possibility of adding them in the further releases, but I can't promise it now.
     
  16. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Version 1.4.1 of Screen Fader now available on Asset Store.
    Update unclude next new features:
    - Lines Effect
    - Image Effect - screen transition with image (could be transparent). In demonstration scene it used for making of damage flash.

    Check out new demo with code samples here: DEMO

    [​IMG]
     
  17. cruzader

    cruzader

    Joined:
    Jan 27, 2015
    Posts:
    1
    Hi Patico,

    I've just purchased your ScreenFader Asset. It looks amazing and it's exactly what i need. My problem is that I'm a beginner in unity and programming.

    Can I use your asset in javascript?
    Maybe you can give me a few examples.

    I'd like to transition between scenes using the SquaredScreenFader.
    Here's my function to switch to the next scene:

    function NextLevel () {
    Application.LoadLevel(GameStart.level); // switch to the upcoming scene
    }

    Allthough I'll try to learn c# I would love to use JavaScript in my first project.

    best wishes

    Edit: I would need this code in JS "Fader.Instance.FadeIn().Pause().LoadLevel("Scene2").FadeOut(2);"

    Edit2: It seems that I have only access to the SquaredScreenFader with a c# script... maybe it doesn't work with a JS-Script at all... :D

    Edit3: After diving into Unity a couple of hours I was able to solve my problems and now the fader is running like a charm...

    When accessing the classes (precompiled under the assetfolder/Plugins/) from within JavaScript you have to send arguments... example:
    Fader.Instance.FadeIn().Pause().LoadLevel("Scene2").FadeOut(2); --> this doesn't run. Instead:
    Fader.Instance.FadeIn(0).Pause(0).LoadLevel("Scene2").FadeOut(2); ---> runs like hell! ;)

    After bringing this wonderful asset to life, i'm loving it... :)
     
    Last edited: Feb 3, 2015
  18. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    [NEW FEATURE DONE]

    Updated to 1.5


    Hi everybody, here is a good news, guys - just now Screen Fader 1.5 update was accepted by Unity Asset Store Team and became available here - https://www.assetstore.unity3d.com/en/#!/content/9526

    This update includes some fixes for full compatibility with new Unity 5 API, and couple of minor changes eliminating annoing warning messages from output console.

    Recomend to update : )
     
    Last edited: Apr 24, 2015
  19. Cascho01

    Cascho01

    Joined:
    Mar 19, 2010
    Posts:
    960
    Can you explain me what are the benefits of your plugin against just using an alphablended quad in front of the camera?
     
  20. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Okay
    there are a lot of them..

    First of all you don't need "alphablended quad" at all. Forget about it and just type:
    Code (csharp):
    1. Fader.Instance.FadeIn();
    - another one, is possibility to combain calls in chains, like this:
    Code (csharp):
    1. Fader.Instance.FadeIn().Pause( 10 ).StartAction( YouCustomAction ).FadeOut();
    - also you can "fade objects" in the same way ( probably, you can meet some problems here when you will try to do the same with "alphablended quad" ; ) ):
    Code (csharp):
    1. Fader.Instance.FadeIn( myCharacterGameObject ).StartAction( ChangeCharactersAction ).FadeOut( myNewCharacterGameObject );
    - or load levels:
    Code (csharp):
    1. Fader.Instance.LoadLevel( "IntroScene" ).FadeOut( 3 ).Pause( 10 ).FadeIn().LoadLevel( "Level-1" ).FadeOut();
    and so on...
    A lot of other cases described above, but i recommend just try a demo - here

    And one more thing - there also some different fading effects, you also can see them in demo.
     
  21. Cascho01

    Cascho01

    Joined:
    Mar 19, 2010
    Posts:
    960
    Sorry, I meant what is different with your solution compared to a simple quad that I could place in front of my camera instead?
    For example: Does it cost less performance? If yes - why?
     
    Patico likes this.
  22. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Ohh, I understand, from the perfomance point of view, quard will be better in simple fading, main values of my solution are different effects, extendability and easiness of usage.
     
  23. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    For clarify possibilities of ScreenFader, and for helping users, I've added API Help section in the topic.
     
  24. Gekigengar

    Gekigengar

    Joined:
    Jan 20, 2013
    Posts:
    337
    What is the transition effect based of? (The boxes, the faders)
    Is it based on the Legacy GUI?

    I am thinking of loading bars after fading in, then fade out when the loading bar is complete.

    How easy would it be to create that with this? (I hope you can include this in your examples too.)
     
    Patico likes this.
  25. HeadTrip

    HeadTrip

    Joined:
    Apr 1, 2013
    Posts:
    418
    VR friendly?
     
    Patico likes this.
  26. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Why not? :) If you have any doubts, share it please.
     
  27. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    [Hotfix for ScreenFader 1.5]

    Issue: SetColor method was not working in sequences. So, such code as below, has changed color of fading effect only once.
    Code (csharp):
    1. Fader.Instance
    2.   .SetColor( Color.black ).FadeIn().FadeOut()
    3.   .SetColor( Color.white ).FadeIn().FadeOut();
    Now issue is fixed and published as v.1.5.1
     
  28. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Published version 1.6 with fading of UI elements.
    Now waiting for AssetStore team review.
     
  29. anyothername

    anyothername

    Joined:
    May 8, 2015
    Posts:
    2
    Your fader doesn't work.

    Assets/Screen Fader Pack/Code/Fader.cs(16,14): error CS0738: `Fader' does not implement interface member `IFader.FadeOut(UnityEngine.GameObject, float)' and the best implementing candidate `Fader.FadeIn(float)' return type `IFader' does not match interface member return type `IFader'

    This issue is citing your unedited code in Unity 4.6.5
     
    Patico likes this.
  30. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi AnyOtherName, fortunately UnityTeam checks every asset and every update of asset and does not allow to publish broken or non-compilable code. So I can guarantee that all published code is working and all interfaces are implemented. Most likely you need to remove it and download again, moreover just now new update (1.6) become available.
    I hope this will help your, and I really sorry for you meet these problems.
     
  31. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    [NEW FEATURE DONE]

    Updated to 1.6

    Added methods for fading of UI elements and images:
    - FadeIn( UI.Element, time )
    - FadeIn( UI.Image, time )
    - FadeOut( UI.Element, time )
    - FadeOut( UI.Image, time )

    Code (csharp):
    1. GameObject startBtn= GameObject.Find( "StartButton" );
    2. UI.Image backgroundImg = GameObject.Find( "BackgroundImage" ).GetComponent<UI.Image>();
    3.  
    4. Fader.Instance.FadeIn( startBtn ).Pause().FadeIn( backgroundImg );
    [​IMG]
     
  32. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Screen fader has changed icon:
    [​IMG]
     
  33. anyothername

    anyothername

    Joined:
    May 8, 2015
    Posts:
    2
    I have re-downloaded it and it compiles now, but does nothing. Besides one line of code what else needs to be done to get this thing working? I really just need a very simple fade-out.
     
  34. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi, can you describe more detailed, maybe with little peace of code, what exactly do you do and what do you want to achieve?


    Thanx a lot,
    Paul
     
  35. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Limited support till 13th of June

    Hi guys, I going to travel during next two weeks, and can not make any development/ fixes till come back.
     
  36. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Full support mode ON

    Hi everybody, I've come back and ready to give full support to anyone.
     
  37. Mr.Stein

    Mr.Stein

    Joined:
    Dec 4, 2013
    Posts:
    169
    Hi @Patico,
    I see your asset in the store and in demo have LoadLevel Fading and look great, I want to know if there is a method to do that with your asset but for the LoadLevel of Photon Network.. I mean PhotonNetwork.LoadLevel or some method to initialize a level with a Fading.

    Regards
     
  38. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Yes of course, you can extend Screen Fader's functionality with any custom action. See an examples of custom actions or email me.

    Thanks
     
  39. D0R1N

    D0R1N

    Joined:
    Oct 4, 2013
    Posts:
    206
    Hey @Patico ,
    Very nice asset excellent work, I wonder if your extension supports custom shapes for fading, instead the classic ones ( square & stripes) ? Thanks !
     
  40. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi @D0R1N, currently this asset has not such functionality, but I have this feature request in the planned tasks. Subscribe on this thread and you will be notified when feature will be done ;-)
     
  41. CoderPro

    CoderPro

    Joined:
    Feb 21, 2014
    Posts:
    264
    Could you make demo of latest version. I want to try demo before buy it ? And another question: Do you using shaders for transitions ?
     
  42. HeadTrip

    HeadTrip

    Joined:
    Apr 1, 2013
    Posts:
    418
    Friendly Request, playmaker actions?
    :) thanks!
     
  43. D0R1N

    D0R1N

    Joined:
    Oct 4, 2013
    Posts:
    206
    O.K @Patico , today I will buy your product & will wait patient the feature !
    Thanks (Spasiba)
     
  44. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi CoderPro, you can find the demo of latest version of asset here, it's the same link as at the asset's page (don't pay attention to"1_3" in the url, it is not version number :rolleyes: )
     
    Last edited: Jun 26, 2015
  45. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi there,
    I'd like to inform you, that you can meet an issue after updating Unity engine to the next version (the same as I've got some days ago, after installing 5.2). It looks like, no one project can be compiled - unity says something about errors in the scripts and console log shows an empty error without any message.

    It does not connected with Screen Fader asset or any other script, real cause of such behaviour is antivirus software, that marks new unity.exe and mono.exe as untrusted apps and runs them in a sandbox mode.

    I think it occurs when you install new unity "in parallel" - without removing older version (as I did). And to fix it, all you need is to add Unity and Mono to list of trusted applications (or something like this, depends on software you use).
     
  46. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Congratules!
    Yesterday ScreenFader has achieved 3rd position by popularity in GUI category!

    [​IMG]

    To be the honest, a day before it was at 2nd, but I didn't made any screenshot. Pitty :-]
     
  47. KamiKaze425

    KamiKaze425

    Joined:
    Nov 20, 2012
    Posts:
    177
    Hey there,
    So just one issue I'm having: If I use Squared Screen Fader and my columns are less than 8, the squares are more like rectangles (they are stretched in width). And my texture IS a perfect square. (Clip of how it looks when columns set to 4. Aspect ratio does not change it)
    Also, is there a way to randomize the texture on Squared Screen Fader prior to FadeIn()?

    Thanks!
     

    Attached Files:

  48. asifh

    asifh

    Joined:
    Sep 22, 2016
    Posts:
    1
    Hi Patico,

    I just bought your asset and it's great to see how easy it is to use !
    I do a lot of screen fading in my game as it contains a lot of 2d dialogs and i would like to know if it is possible to combine different fade effects in one scene ?
    Like fade one time with squares than another time do a classic fade but staying in the same scene.
    I would like to change the fade effect according to the button pressed by the player.

    Thanks.
     
  49. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Hi @asifh
    There are few methods for changing fading effect at runtime, they're starting with Fader.SetupAs...()

    Try to call one of them when you need to change effect:
    Fader.SetupAsDefaultFader(), Fader.SetupAsLinesFader(), Fader.SetupAsSquaredFader(), Fader.SetupAsStripesFader() or Fader.SetupAsImageFader()

    One note: you cannot change type of effect during the playing of current effect. So, call these methods before or after the run of fading.
     
  50. Patico

    Patico

    Joined:
    May 21, 2013
    Posts:
    883
    Dear customers,
    I going to migrate my domain name to another registrator, during this process my website http://patico.pro and main support email will not work. I hope it won't take more couple of days, but anyway in this time you can rich me via http://gamedev.click/ mirror or info@gamedev.click email

    I'll post a new message here when migration completed.
    Thanks, Paul.