Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
W
wdlc_mjb_unity
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
王雪伟
wdlc_mjb_unity
Commits
ecee9940
Commit
ecee9940
authored
Jun 22, 2021
by
zhangzhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
no message
parent
f531f188
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
75 additions
and
516 deletions
+75
-516
Scripts.meta
Assets/AdSDK/AD/CSJ/PangleAdapterScripts/Scripts.meta
+0
-8
iOS.meta
Assets/AdSDK/AD/CSJ/PangleSDK/iOS.meta
+0
-8
NetWork.meta
Assets/AdSDK/NetWork.meta
+0
-8
DOTweenTextMeshPro.cs.addon
Assets/Base/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.addon
+0
-239
DOTweenTextMeshPro.cs.addon.meta
...ase/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.addon.meta
+0
-8
DOTweenTk2d.cs.addon
Assets/Base/Demigiant/DOTweenPro/DOTweenTk2d.cs.addon
+0
-225
DOTweenTk2d.cs.addon.meta
Assets/Base/Demigiant/DOTweenPro/DOTweenTk2d.cs.addon.meta
+0
-8
manifest.json
Packages/manifest.json
+7
-0
packages-lock.json
Packages/packages-lock.json
+65
-0
EditorBuildSettings.asset
ProjectSettings/EditorBuildSettings.asset
+3
-12
No files found.
Assets/AdSDK/AD/CSJ/PangleAdapterScripts/Scripts.meta
deleted
100644 → 0
View file @
f531f188
fileFormatVersion: 2
guid: e8fc61bed8a2640c7a2c6d5a51574621
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Assets/AdSDK/AD/CSJ/PangleSDK/iOS.meta
deleted
100644 → 0
View file @
f531f188
fileFormatVersion: 2
guid: 9b3f9e305d4804719b5f4505912accf2
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Assets/AdSDK/NetWork.meta
deleted
100644 → 0
View file @
f531f188
fileFormatVersion: 2
guid: a75f8ac9bc3f8414cb9b1aca48735084
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
Assets/Base/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.addon
deleted
100644 → 0
View file @
f531f188
// Author: Daniele Giardini - http://www.demigiant.com
// Created: 2015/03/27 19:02
//
// License Copyright (c) Daniele Giardini.
// This work is subject to the terms at http://dotween.demigiant.com/license.php
using UnityEngine;
using TMPro;
namespace DG.Tweening
{
/// <summary>
/// Methods that extend Text Mesh Pro objects and allow to directly create and control tweens from their instances.
/// </summary>
public static class ShortcutExtensionsTextMeshPro
{
#region Colors
/// <summary>Tweens a TextMeshPro's color to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOColor(this TextMeshPro target, Color endValue, float duration)
{
return DOTween.To(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's faceColor to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFaceColor(this TextMeshPro target, Color32 endValue, float duration)
{
return DOTween.To(() => target.faceColor, x => target.faceColor = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's outlineColor to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOOutlineColor(this TextMeshPro target, Color32 endValue, float duration)
{
return DOTween.To(() => target.outlineColor, x => target.outlineColor = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's glow color to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
/// <param name="useSharedMaterial">If TRUE will use the fontSharedMaterial instead than the fontMaterial</param>
public static Tweener DOGlowColor(this TextMeshPro target, Color endValue, float duration, bool useSharedMaterial = false)
{
return useSharedMaterial
? target.fontSharedMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target)
: target.fontMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's alpha color to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFade(this TextMeshPro target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro faceColor's alpha to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFaceFade(this TextMeshPro target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.faceColor, x => target.faceColor = x, endValue, duration)
.SetTarget(target);
}
#endregion
#region Other
/// <summary>Tweens a TextMeshPro's scale to the given value (using correct uniform scale as TMP requires).
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScale(this TextMeshPro target, float endValue, float duration)
{
Transform t = target.transform;
Vector3 endValueV3 = new Vector3(endValue, endValue, endValue);
return DOTween.To(() => t.localScale, x => t.localScale = x, endValueV3, duration).SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's fontSize to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFontSize(this TextMeshPro target, float endValue, float duration)
{
return DOTween.To(() => target.fontSize, x => target.fontSize = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's maxVisibleCharacters to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOMaxVisibleCharacters(this TextMeshPro target, int endValue, float duration)
{
return DOTween.To(() => target.maxVisibleCharacters, x => target.maxVisibleCharacters = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshPro's text to the given value.
/// Also stores the TextMeshPro as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end string to tween to</param><param name="duration">The duration of the tween</param>
/// <param name="richTextEnabled">If TRUE (default), rich text will be interpreted correctly while animated,
/// otherwise all tags will be considered as normal text</param>
/// <param name="scrambleMode">The type of scramble mode to use, if any</param>
/// <param name="scrambleChars">A string containing the characters to use for scrambling.
/// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters.
/// Leave it to NULL (default) to use default ones</param>
public static Tweener DOText(this TextMeshPro target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null)
{
return DOTween.To(() => target.text, x => target.text = x, endValue, duration)
.SetOptions(richTextEnabled, scrambleMode, scrambleChars)
.SetTarget(target);
}
#endregion
}
/// <summary>
/// Methods that extend Text Mesh Pro objects and allow to directly create and control tweens from their instances.
/// </summary>
public static class ShortcutExtensionsTextMeshProUGUI
{
#region Colors
/// <summary>Tweens a TextMeshProUGUI's color to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOColor(this TextMeshProUGUI target, Color endValue, float duration)
{
return DOTween.To(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's faceColor to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFaceColor(this TextMeshProUGUI target, Color32 endValue, float duration)
{
return DOTween.To(() => target.faceColor, x => target.faceColor = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's outlineColor to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOOutlineColor(this TextMeshProUGUI target, Color32 endValue, float duration)
{
return DOTween.To(() => target.outlineColor, x => target.outlineColor = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's glow color to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
/// <param name="useSharedMaterial">If TRUE will use the fontSharedMaterial instead than the fontMaterial</param>
public static Tweener DOGlowColor(this TextMeshProUGUI target, Color endValue, float duration, bool useSharedMaterial = false)
{
return useSharedMaterial
? target.fontSharedMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target)
: target.fontMaterial.DOColor(endValue, "_GlowColor", duration).SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's alpha color to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFade(this TextMeshProUGUI target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI faceColor's alpha to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFaceFade(this TextMeshProUGUI target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.faceColor, x => target.faceColor = x, endValue, duration)
.SetTarget(target);
}
#endregion
#region Other
/// <summary>Tweens a TextMeshProUGUI's scale to the given value (using correct uniform scale as TMP requires).
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScale(this TextMeshProUGUI target, float endValue, float duration)
{
Transform t = target.transform;
Vector3 endValueV3 = new Vector3(endValue, endValue, endValue);
return DOTween.To(() => t.localScale, x => t.localScale = x, endValueV3, duration).SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's fontSize to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFontSize(this TextMeshProUGUI target, float endValue, float duration)
{
return DOTween.To(() => target.fontSize, x => target.fontSize = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's maxVisibleCharacters to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOMaxVisibleCharacters(this TextMeshProUGUI target, int endValue, float duration)
{
return DOTween.To(() => target.maxVisibleCharacters, x => target.maxVisibleCharacters = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a TextMeshProUGUI's text to the given value.
/// Also stores the TextMeshProUGUI as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end string to tween to</param><param name="duration">The duration of the tween</param>
/// <param name="richTextEnabled">If TRUE (default), rich text will be interpreted correctly while animated,
/// otherwise all tags will be considered as normal text</param>
/// <param name="scrambleMode">The type of scramble mode to use, if any</param>
/// <param name="scrambleChars">A string containing the characters to use for scrambling.
/// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters.
/// Leave it to NULL (default) to use default ones</param>
public static Tweener DOText(this TextMeshProUGUI target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null)
{
return DOTween.To(() => target.text, x => target.text = x, endValue, duration)
.SetOptions(richTextEnabled, scrambleMode, scrambleChars)
.SetTarget(target);
}
#endregion
}
}
\ No newline at end of file
Assets/Base/Demigiant/DOTweenPro/DOTweenTextMeshPro.cs.addon.meta
deleted
100644 → 0
View file @
f531f188
fileFormatVersion: 2
guid: 8eb04b85cc6f89344a7c271e1bfef46d
timeCreated: 1428774842
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
Assets/Base/Demigiant/DOTweenPro/DOTweenTk2d.cs.addon
deleted
100644 → 0
View file @
f531f188
// Author: Daniele Giardini - http://www.demigiant.com
// Created: 2014/10/27 15:59
//
// License Copyright (c) Daniele Giardini.
// This work is subject to the terms at http://dotween.demigiant.com/license.php
using UnityEngine;
namespace DG.Tweening
{
/// <summary>
/// Methods that extend 2D Toolkit objects and allow to directly create and control tweens from their instances.
/// </summary>
public static class ShortcutExtensionsTk2d
{
#region Sprite
/// <summary>Tweens a 2D Toolkit Sprite's dimensions to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScale(this tk2dBaseSprite target, Vector3 endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a Sprite's dimensions to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleX(this tk2dBaseSprite target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(endValue, 0, 0), duration)
.SetOptions(AxisConstraint.X)
.SetTarget(target);
}
/// <summary>Tweens a Sprite's dimensions to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleY(this tk2dBaseSprite target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, endValue, 0), duration)
.SetOptions(AxisConstraint.Y)
.SetTarget(target);
}
/// <summary>Tweens a Sprite's dimensions to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleZ(this tk2dBaseSprite target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, 0, endValue), duration)
.SetOptions(AxisConstraint.Z)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit Sprite's color to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOColor(this tk2dBaseSprite target, Color endValue, float duration)
{
return DOTween.To(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit Sprite's alpha color to the given value.
/// Also stores the Sprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFade(this tk2dBaseSprite target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit Sprite's color using the given gradient
/// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener).
/// Also stores the image as the tween's target so it can be used for filtered operations</summary>
/// <param name="gradient">The gradient to use</param><param name="duration">The duration of the tween</param>
public static Sequence DOGradientColor(this tk2dBaseSprite target, Gradient gradient, float duration)
{
Sequence s = DOTween.Sequence();
GradientColorKey[] colors = gradient.colorKeys;
int len = colors.Length;
for (int i = 0; i < len; ++i) {
GradientColorKey c = colors[i];
if (i == 0 && c.time <= 0) {
target.color = c.color;
continue;
}
float colorDuration = i == len - 1
? duration - s.Duration(false) // Verifies that total duration is correct
: duration * (i == 0 ? c.time : c.time - colors[i - 1].time);
s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear));
}
return s;
}
#endregion
#region tk2dSlicedSprite
/// <summary>Tweens a 2D Toolkit SlicedSprite's dimensions to the given value.
/// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleDimensions(this tk2dSlicedSprite target, Vector2 endValue, float duration)
{
return DOTween.To(() => target.dimensions, x => target.dimensions = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a SlicedSprite's dimensions to the given value.
/// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleDimensionsX(this tk2dSlicedSprite target, float endValue, float duration)
{
return DOTween.To(() => target.dimensions, x => target.dimensions = x, new Vector2(endValue, 0), duration)
.SetOptions(AxisConstraint.X)
.SetTarget(target);
}
/// <summary>Tweens a SlicedSprite's dimensions to the given value.
/// Also stores the SlicedSprite as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleDimensionsY(this tk2dSlicedSprite target, float endValue, float duration)
{
return DOTween.To(() => target.dimensions, x => target.dimensions = x, new Vector2(0, endValue), duration)
.SetOptions(AxisConstraint.Y)
.SetTarget(target);
}
#endregion
#region TextMesh
/// <summary>Tweens a 2D Toolkit TextMesh's dimensions to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScale(this tk2dTextMesh target, Vector3 endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's dimensions to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleX(this tk2dTextMesh target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(endValue, 0, 0), duration)
.SetOptions(AxisConstraint.X)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's dimensions to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleY(this tk2dTextMesh target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, endValue, 0), duration)
.SetOptions(AxisConstraint.Y)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's dimensions to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOScaleZ(this tk2dTextMesh target, float endValue, float duration)
{
return DOTween.To(() => target.scale, x => target.scale = x, new Vector3(0, 0, endValue), duration)
.SetOptions(AxisConstraint.Z)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's color to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOColor(this tk2dTextMesh target, Color endValue, float duration)
{
return DOTween.To(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's alpha color to the given value.
/// Also stores the TextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end value to reach</param><param name="duration">The duration of the tween</param>
public static Tweener DOFade(this tk2dTextMesh target, float endValue, float duration)
{
return DOTween.ToAlpha(() => target.color, x => target.color = x, endValue, duration)
.SetTarget(target);
}
/// <summary>Tweens a 2D Toolkit TextMesh's color using the given gradient
/// (NOTE 1: only uses the colors of the gradient, not the alphas - NOTE 2: creates a Sequence, not a Tweener).
/// Also stores the image as the tween's target so it can be used for filtered operations</summary>
/// <param name="gradient">The gradient to use</param><param name="duration">The duration of the tween</param>
public static Sequence DOGradientColor(this tk2dTextMesh target, Gradient gradient, float duration)
{
Sequence s = DOTween.Sequence();
GradientColorKey[] colors = gradient.colorKeys;
int len = colors.Length;
for (int i = 0; i < len; ++i) {
GradientColorKey c = colors[i];
if (i == 0 && c.time <= 0) {
target.color = c.color;
continue;
}
float colorDuration = i == len - 1
? duration - s.Duration(false) // Verifies that total duration is correct
: duration * (i == 0 ? c.time : c.time - colors[i - 1].time);
s.Append(target.DOColor(c.color, colorDuration).SetEase(Ease.Linear));
}
return s;
}
/// <summary>Tweens a tk2dTextMesh's text to the given value.
/// Also stores the tk2dTextMesh as the tween's target so it can be used for filtered operations</summary>
/// <param name="endValue">The end string to tween to</param><param name="duration">The duration of the tween</param>
/// <param name="richTextEnabled">If TRUE (default), rich text will be interpreted correctly while animated,
/// otherwise all tags will be considered as normal text</param>
/// <param name="scrambleMode">The type of scramble mode to use, if any</param>
/// <param name="scrambleChars">A string containing the characters to use for scrambling.
/// Use as many characters as possible (minimum 10) because DOTween uses a fast scramble mode which gives better results with more characters.
/// Leave it to NULL (default) to use default ones</param>
public static Tweener DOText(this tk2dTextMesh target, string endValue, float duration, bool richTextEnabled = true, ScrambleMode scrambleMode = ScrambleMode.None, string scrambleChars = null)
{
return DOTween.To(() => target.text, x => target.text = x, endValue, duration)
.SetOptions(richTextEnabled, scrambleMode, scrambleChars)
.SetTarget(target);
}
#endregion
}
}
\ No newline at end of file
Assets/Base/Demigiant/DOTweenPro/DOTweenTk2d.cs.addon.meta
deleted
100644 → 0
View file @
f531f188
fileFormatVersion: 2
guid: 696fb534c77ea9241a70586ef5260a92
timeCreated: 1428774842
licenseType: Store
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:
Packages/manifest.json
View file @
ecee9940
{
"dependencies"
:
{
"com.unity.2d.sprite"
:
"1.0.0"
,
"com.unity.2d.tilemap"
:
"1.0.0"
,
"com.unity.ads"
:
"3.6.1"
,
"com.unity.analytics"
:
"3.3.5"
,
"com.unity.collab-proxy"
:
"1.2.16"
,
"com.unity.ide.rider"
:
"1.1.4"
,
"com.unity.ide.vscode"
:
"1.2.3"
,
"com.unity.multiplayer-hlapi"
:
"1.0.8"
,
"com.unity.purchasing"
:
"2.2.1"
,
"com.unity.test-framework"
:
"1.1.20"
,
"com.unity.textmeshpro"
:
"2.1.1"
,
"com.unity.timeline"
:
"1.2.17"
,
"com.unity.ugui"
:
"1.0.0"
,
"com.unity.xr.legacyinputhelpers"
:
"2.1.7"
,
"com.unity.modules.ai"
:
"1.0.0"
,
"com.unity.modules.androidjni"
:
"1.0.0"
,
"com.unity.modules.animation"
:
"1.0.0"
,
...
...
Packages/packages-lock.json
View file @
ecee9940
{
"dependencies"
:
{
"com.unity.2d.sprite"
:
{
"version"
:
"1.0.0"
,
"depth"
:
0
,
"source"
:
"builtin"
,
"dependencies"
:
{}
},
"com.unity.2d.tilemap"
:
{
"version"
:
"1.0.0"
,
"depth"
:
0
,
"source"
:
"builtin"
,
"dependencies"
:
{}
},
"com.unity.ads"
:
{
"version"
:
"3.6.1"
,
"depth"
:
0
,
"source"
:
"registry"
,
"dependencies"
:
{
"com.unity.ugui"
:
"1.0.0"
},
"url"
:
"https://packages.unity.com"
},
"com.unity.analytics"
:
{
"version"
:
"3.3.5"
,
"depth"
:
0
,
"source"
:
"registry"
,
"dependencies"
:
{
"com.unity.ugui"
:
"1.0.0"
},
"url"
:
"https://packages.unity.com"
},
"com.unity.collab-proxy"
:
{
"version"
:
"1.2.16"
,
"depth"
:
0
,
...
...
@@ -30,6 +60,24 @@
"dependencies"
:
{},
"url"
:
"https://packages.unity.com"
},
"com.unity.multiplayer-hlapi"
:
{
"version"
:
"1.0.8"
,
"depth"
:
0
,
"source"
:
"registry"
,
"dependencies"
:
{
"nuget.mono-cecil"
:
"0.1.6-preview"
},
"url"
:
"https://packages.unity.com"
},
"com.unity.purchasing"
:
{
"version"
:
"2.2.1"
,
"depth"
:
0
,
"source"
:
"registry"
,
"dependencies"
:
{
"com.unity.ugui"
:
"1.0.0"
},
"url"
:
"https://packages.unity.com"
},
"com.unity.test-framework"
:
{
"version"
:
"1.1.20"
,
"depth"
:
0
,
...
...
@@ -66,6 +114,23 @@
"com.unity.modules.imgui"
:
"1.0.0"
}
},
"com.unity.xr.legacyinputhelpers"
:
{
"version"
:
"2.1.7"
,
"depth"
:
0
,
"source"
:
"registry"
,
"dependencies"
:
{
"com.unity.modules.vr"
:
"1.0.0"
,
"com.unity.modules.xr"
:
"1.0.0"
},
"url"
:
"https://packages.unity.com"
},
"nuget.mono-cecil"
:
{
"version"
:
"0.1.6-preview"
,
"depth"
:
1
,
"source"
:
"registry"
,
"dependencies"
:
{},
"url"
:
"https://packages.unity.com"
},
"com.unity.modules.ai"
:
{
"version"
:
"1.0.0"
,
"depth"
:
0
,
...
...
ProjectSettings/EditorBuildSettings.asset
View file @
ecee9940
...
...
@@ -5,22 +5,13 @@ EditorBuildSettings:
m_ObjectHideFlags
:
0
serializedVersion
:
2
m_Scenes
:
-
enabled
:
0
-
enabled
:
1
path
:
Assets/Game/Main/Scenes/InitScene.unity
guid
:
902436d14e36d4d42921eab701175b51
-
enabled
:
0
-
enabled
:
1
path
:
Assets/Game/Splash/Splash.unity
guid
:
37af8cf3fb373478ab04e3ee2f3b700a
-
enabled
:
0
-
enabled
:
1
path
:
Assets/Game/Main/Scenes/CrazyCar.unity
guid
:
2ae344869669f6641a05481805b94e98
-
enabled
:
0
path
:
Assets/Base/AdSDK/AD/Demo/AdDemo.unity
guid
:
ef80a35d44f809e4a8957d1ed9571fd2
-
enabled
:
0
path
:
Assets/Base/AdSDK/AD/CSJ/Example/Example.unity
guid
:
1e4f8457b1266154e80399e42b932ceb
-
enabled
:
1
path
:
Assets/Base/AdSDK/AD/GDT/UnionDemo/UnionExample.unity
guid
:
6c963ae210fa3c3438c2f6770ee81fc9
m_configObjects
:
{}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment