资源简介
基于dotween可直接在节点上挂载tweenanimation,设定动画类型,并可预览
可设置dotweenpath
可设置dotweenpath

代码片段和文件信息
// Author: Daniele Giardini - http://www.demigiant.com
// Created: 2018/07/13
#if true // MODULE_MARKER
using System;
using UnityEngine;
#if UNITY_5 || UNITY_2017_1_OR_NEWER
using UnityEngine.Audio; // Required for AudioMixer
#endif
#pragma warning disable 1591
namespace DG.Tweening
{
public static class DOTweenModuleAudio
{
#region Shortcuts
#region Audio
/// Tweens an AudioSource‘s volume to the given value.
/// Also stores the AudioSource as the tween‘s target so it can be used for filtered operations
/// The end value to reach (0 to 1)The duration of the tween
public static Tweener DOFade(this AudioSource target float endValue float duration)
{
if (endValue < 0) endValue = 0;
else if (endValue > 1) endValue = 1;
return DOTween.To(() => target.volume x => target.volume = x endValue duration).SetTarget(target);
}
/// Tweens an AudioSource‘s pitch to the given value.
/// Also stores the AudioSource as the tween‘s target so it can be used for filtered operations
/// The end value to reachThe duration of the tween
public static Tweener DOPitch(this AudioSource target float endValue float duration)
{
return DOTween.To(() => target.pitch x => target.pitch = x endValue duration).SetTarget(target);
}
#endregion
#if UNITY_5 || UNITY_2017_1_OR_NEWER
#region AudioMixer (Unity 5 or Newer)
/// Tweens an AudioMixer‘s exposed float to the given value.
/// Also stores the AudioMixer as the tween‘s target so it can be used for filtered operations.
/// Note that you need to manually expose a float in an AudioMixerGroup in order to be able to tween it from an AudioMixer.
/// Name given to the exposed float to set
/// The end value to reachThe duration of the tween
public static Tweener DOSetFloat(this AudioMixer target string floatName float endValue float duration)
{
return DOTween.To(()=> {
float currVal;
target.GetFloat(floatName out currVal);
return currVal;
} x=> target.SetFloat(floatName x) endValue duration)
.SetTarget(target);
}
#region Operation Shortcuts
///
/// Completes all tweens that have this target as a reference
/// (meaning tweens that were started from this target or that had this target added as an Id)
/// and returns the total number of tweens completed
/// (meaning the tweens that
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 27231 2019-09-21 17:59 DOTweenPro\DOTweenAnimation.cs
文件 243 2019-09-21 17:59 DOTweenPro\DOTweenAnimation.cs.me
文件 15872 2019-09-21 17:59 DOTweenPro\DOTweenPro.dll
文件 2469 2019-09-21 17:59 DOTweenPro\DOTweenPro.dll.mdb
文件 155 2019-09-21 17:59 DOTweenPro\DOTweenPro.dll.mdb.me
文件 569 2019-09-21 17:59 DOTweenPro\DOTweenPro.dll.me
文件 2185 2019-09-21 17:59 DOTweenPro\DOTweenPro.xm
文件 158 2019-09-21 17:59 DOTweenPro\DOTweenPro.xm
文件 4084 2019-09-21 17:59 DOTweenPro\DOTweenProShortcuts.cs
文件 243 2019-09-21 17:59 DOTweenPro\DOTweenProShortcuts.cs.me
文件 22718 2019-09-21 17:59 DOTweenPro\DOTweenTextMeshPro.cs
文件 243 2019-09-21 17:59 DOTweenPro\DOTweenTextMeshPro.cs.me
文件 13743 2019-09-21 17:59 DOTweenPro\DOTweenTk2d.cs
文件 243 2019-09-21 17:59 DOTweenPro\DOTweenTk2d.cs.me
文件 35346 2019-09-21 17:59 DOTweenPro\Editor\DOTweenAnimationInspector.cs
文件 243 2019-09-21 17:59 DOTweenPro\Editor\DOTweenAnimationInspector.cs.me
文件 11363 2019-09-21 17:59 DOTweenPro\Editor\DOTweenPreviewManager.cs
文件 243 2019-09-21 17:59 DOTweenPro\Editor\DOTweenPreviewManager.cs.me
文件 28672 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.dll
文件 4053 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.dll.mdb
文件 155 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.dll.mdb.me
文件 569 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.dll.me
文件 542 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.xm
文件 158 2019-09-21 17:59 DOTweenPro\Editor\DOTweenProEditor.xm
文件 172 2019-09-21 17:59 DOTweenPro\Editor.me
文件 2439 2019-09-21 17:59 DOTweenPro\readme.txt
文件 158 2019-09-21 17:59 DOTweenPro\readme.txt.me
文件 9728 2019-09-21 17:59 DemiLib\Core\DemiLib.dll
文件 2517 2019-09-21 17:59 DemiLib\Core\DemiLib.dll.mdb
文件 155 2019-09-21 17:59 DemiLib\Core\DemiLib.dll.mdb.me
............此处省略262个文件信息
相关资源
- res10_300x300_ssd_iter_140000.caffemodel与dep
- 《Visual Prolog 集成开发环境(下)》
- 《Visual Prolog 基础类》 中文参考.chm
- 我的界面(visual foxpro)源码
- Apolipoprotein E4 Impairs in vivo Hippocampal
- 周立功开发板ProASIC3实验-syn_FIFO代码
- Zprotect专业版(无限制) 一机一码E
- 51单片机PWM程序,占空比、周期可调整
- PIC单片机完成的电子密码锁
- BCG帮助手册,完整版_修正
- proteus仿真 AT89C51输出各种波形
- 00
- 51单片机基于protues的几个仿真实例
- DOS播放器 QuickViewPro破解版
- VPC3_DPV1源代码,Profibus
- 步进电机protues仿真
- 51单片机读取温度数据存储到SD卡中并
- 【单片机】51单片机数码管显示万年历
- proteus_24C08—有注释(proteus里面使用的
- 毕业设计 单片机 对讲机 protues仿真
- 数据采集系统——ADC0808的应用,单片
- WinForm属性编辑 propertyGrid示例 仿wind
- DS18B20分布式多点测温的Proteus仿真
- DUMPROM工具
- 课程设计蔬菜大棚自动控制系统,包
- 基于proteus的单片机仿真--交通灯控制
- 带时间温度显示的室内灯光控制系统
- 用PIC16F877实现EEPROM读写程序
- protues万年历仿真
- 51多机通信(内附Proteus及.hex文件)
评论
共有 条评论