Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - boolean0101

Pages: [1]
Hi there

I tend to use "DOTween.To(()=> myFloat, x=> myFloat = x, 45, 1);" quite often, it's a really nice pausable way of tweening floats. However, when DOTween changed a few versions back to use Ease.OutQuad as its default type instead of Ease.Liner, I didn't notice until today that it also affects my floats. This means things like tweening a 5 second cooldown it's actually closer to 6 seconds because of the easing.

Now this is 100% on me, no fault of DOTween, however it would be nice if the documentation made a note of this. Just a line above it on the documentation page that if your tweening floats you should be sure to set the easing type to Liner.

"DOTween.To(()=> myFloat, x=> myFloat = x, 45, 1).SetEase(Ease.Linear);"


DOTween & DOTween Pro / Possible pause/resume bug
« on: October 14, 2015, 11:13:55 PM »
I recently added a pause button to my game which means I also want to pause all my tweens when the user clicks the button.

I'm making a call to "DOTween.TogglePauseAll();". That works fine, but I have AutoPlay for sequences disabled, so when the player unpauses the game I then need to call " DOTween.TogglePauseAll()" again - you might already suspect the problem. The second pause toggle is just shorthand for ".PlayAll()", the problem being DOTween has no way of knowing which sequences were halfway through playing when the game paused and which sequences are still in a pause state because they have not been run at least once.

I was able to get around this by ensuring I add "sequence.Complete()" after every sequence I create. I'm guessing this works because behind the scenes there is a flag that is changing from "Paused" to "Completed" after the first play through.

This may or not be by design - the workaround I'm using isn't really that much of a hassle. However if this isn't intended behavior, perhaps starting all tweens in the completed state when AutoPlay is disabled might be handy.


DOTween & DOTween Pro / Any way around PunchPosition not being relative?
« on: October 08, 2015, 12:53:15 AM »
Hi there

Another question :P

I was having trouble getting DOPunchPosition to work and found this thread. Basically DOPunchPosition stores a series of Vector3 points when the tween is first created  - so technically it's relative, but only relative to the first time it runs.

This is ok for single tweens that are created on-the-fly, but this am I correct in thinking this rules out their use in reusable sequences? I have a couple of sequences that I recycle in a few places (all the other coordinates are relative) but I can't use DOPunchPosition because it jumps back to the spot where the sequence was first played.

SetRelative works so well for everything else I figured I'd ask if there's any way around this.


DOTween & DOTween Pro / Can a join be used to join to a join?
« on: October 07, 2015, 01:06:39 AM »
Hi there

Random question: Is it possible to use .Join on another .Join? I have a few events in a sequence that all need to fire at the same time, so I added a few tweens like this:

Code: [Select]
Sequence mySequence = DOTween.Sequence();
mySequence.Join(*something joined*);
mySequence.Join(*something else joined*);
mySequence.Join(*something else joined*);

In the example I could obviously just use Insert(0), but poor examples aside: Is it possible to do this? I was experimenting in a project and getting some odd results when restarting the tween, like as if it was running them all sometimes but skipping over them others.

If this is perfectly valid then I'll go back and just check my tweens are working correctly, but if this is a known no-no then figured I'd ask  :)


Pages: [1]