Exemplo n.º 1
0
 private void ClientRemote_OnFishCaught(
     ICharacter character,
     IProtoItem protoItemFish,
     Vector2D fishingTargetPosition,
     float sizeValue)
 {
     ComponentFishingCompletedVisualizer.OnFishCaughtOrFishingCancelled(
         character,
         protoItemFishCaught: protoItemFish,
         fishingTargetPosition,
         caughtFishSizeValue: sizeValue);
 }
Exemplo n.º 2
0
        protected override void ClientOnCompleted()
        {
            ComponentFishingCompletedVisualizer.OnFishCaughtOrFishingCancelled(
                this.Character,
                protoItemFishCaught: null,
                this.FishingTargetPosition,
                caughtFishSizeValue: 0);

            if (!this.clientFishingVisualizer.IsDestroyed)
            {
                this.clientFishingVisualizer.Destroy(delay: ComponentFishingVisualizer.DelayFishingOut);
            }

            this.clientFishingVisualizer = null;

            var skeletonRenderer = PlayerCharacter.GetClientState(this.Character).SkeletonRenderer;

            skeletonRenderer.RemoveAnimationTrackNextEntries(AnimationTrackIndexes.Extra);
            skeletonRenderer.AddAnimation(AnimationTrackIndexes.Extra,
                                          FishingOutAnimationName,
                                          isLooped: false);

            ClientFishingSoundsHelper.PlaySoundCancel(this.Character);
        }