Пример #1
0
    protected void SetUp()
    {
        RenderProfileManifest.i.Initialize();

        sceneHandler = Substitute.For <ISceneHandler>();

        var allLoadedParcelCoords = new HashSet <Vector2Int>();

        allLoadedParcelCoords.Add(new Vector2Int(0, 0));
        allLoadedParcelCoords.Add(new Vector2Int(-1, 0));
        allLoadedParcelCoords.Add(new Vector2Int(-1, 1));

        sceneHandler.GetAllLoadedScenesCoords().Returns(allLoadedParcelCoords);

        blockerAnimationHandler = Substitute.For <IBlockerAnimationHandler>();

        //NOTE(Brian): Call OnFinish() when blockerAnimationHandler.FadeOut is called.
        blockerAnimationHandler.FadeOut(Arg.Any <GameObject>(), Arg.Invoke());

        blockerInstanceHandler = new BlockerInstanceHandler(new DCLCharacterPosition(), blockerAnimationHandler);

        blockersParent = new GameObject();

        blockerInstanceHandler.SetParent(blockersParent.transform);
    }
Пример #2
0
        public BlockerInstanceHandler(DCLCharacterPosition characterPosition, IBlockerAnimationHandler animationHandler)
        {
            this.characterPosition = characterPosition;
            this.animationHandler  = animationHandler;

            RenderProfileManifest.i.OnChangeProfile += OnChangeProfile;
            OnChangeProfile(RenderProfileManifest.i.currentProfile);
        }
 public void Initialize(IBlockerAnimationHandler animationHandler)
 {
     this.animationHandler = animationHandler;
 }
Пример #4
0
 public void Initialize(IBlockerAnimationHandler animationHandler, ICullingController cullingController)
 {
     this.cullingController = cullingController;
     this.animationHandler  = animationHandler;
 }