1
0
mirror of https://github.com/Cardidi/dotween-upm-fork.git synced 2025-12-20 01:06:02 +08:00
This commit is contained in:
Demigiant 2017-06-02 02:31:46 +02:00
parent 69be5c6a90
commit 2b81429fec
15 changed files with 45 additions and 65 deletions

2
.gitignore vendored
View File

@ -35,4 +35,4 @@ zzTestBuilds
*.pdb
UnityTests.Unity5BETA
Unity_Marketing_Pamphlet.pdf
biz

View File

@ -1,9 +0,0 @@
fileFormatVersion: 2
guid: 02fe78e962405814a83b8ba6c9471d32
folderAsset: yes
timeCreated: 1439628445
licenseType: Free
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,9 +0,0 @@
fileFormatVersion: 2
guid: 6e71a3e2fb5854e43823a9da25b68e21
folderAsset: yes
timeCreated: 1439628445
licenseType: Free
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1 +0,0 @@
guid: 38d405c119fcc7c4e83d4a478a40ff2f

View File

@ -1 +0,0 @@
guid: 4ad02dc83da735c4e8d945332b9202f6

View File

@ -1,20 +0,0 @@
fileFormatVersion: 2
guid: 42c12149efdc035458bffa42058b9a04
timeCreated: 1439628452
licenseType: Free
PluginImporter:
serializedVersion: 1
iconMap: {}
executionOrder: {}
isPreloaded: 0
platformData:
Any:
enabled: 0
settings: {}
Editor:
enabled: 1
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: aee9a8210ca82c3439f4dd5bc03d2506
timeCreated: 1496055090
licenseType: Pro
DefaultImporter:
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,22 @@
using System.Collections;
using System.Collections.Generic;
using DG.Tweening;
using UnityEngine;
public class ShakeExample : MonoBehaviour
{
public Transform target;
public Tween shakeTween;
void Start()
{
// Create the tween (using default values)
shakeTween = target.DOShakePosition(1.5f).SetAutoKill(false).Pause();
}
// Called by UI button
public void Shake()
{
shakeTween.Restart();
}
}

View File

@ -0,0 +1,12 @@
fileFormatVersion: 2
guid: 2b1c898c63fb9874d93e1dbafd15dd0b
timeCreated: 1496055165
licenseType: Pro
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -10,31 +10,9 @@ using UnityEngine;
public class TempTests : BrainBase
{
public Transform target;
Tween myTween;
bool aBool;
void Start()
{
DOTween.Init();
this.StartCoroutine(COUpdate());
}
IEnumerator COUpdate()
{
yield return null;
yield return null;
target.DOMoveX(2, 7);
yield return null;
// for (int i = 0; i < 1000; ++i) target.DOMoveX(2, 7).OnComplete(ACallback);
// for (int i = 0; i < 1000; ++i) target.DOMoveX(2, 7).OnComplete(()=> aBool = true);
target.DOMoveX(2, 7).OnComplete(()=> aBool = true);
// myTween.Kill();
// myTween = target.DOMoveX(2, 1);
// myTween.OnComplete(ACallback);
}
void ACallback()
{
Debug.Log("DO SOMETHING");
target.DOShakeScale(2, 0.15f, 10, 90f, true);
}
}

View File

@ -1 +1 @@
m_EditorVersion: 5.6.0f3
m_EditorVersion: 5.6.1f1