Hello Guest

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.


Messages - chobi77

Pages: [1]
1
Support / Re: anim.currentClip.name problem.
« on: September 08, 2012, 05:14:01 pm »
Oh wow yes, that never occurred to me...

Seems i also have to upgrade Unity to 3.5.5 as well.

Thanks for that, i hope all this works when i finish upgrading.  :)

2
Support / Re: anim.currentClip.name problem.
« on: September 08, 2012, 04:29:56 pm »
version 1.51

:)

3
Support / Re: anim.currentClip.name problem.
« on: September 08, 2012, 04:06:38 pm »
Thanks for the quick reply.

I changed it to CurrentClip and now i get this error.

Type `tk2dAnimatedSprite' does not contain a definition for `CurrentClip' and no extension method `CurrentClip' of type `tk2dAnimatedSprite' could be found (are you missing a using directive or an assembly reference?)

any ideas?

4
Support / anim.currentClip.name problem.
« on: September 08, 2012, 03:45:39 pm »
Hi all,

I am doing a check to see if an animation is playing so i can get Mario to walk after he lands from a jump and make the jump animation stop.

The problem is that the code  i am using does not work, i have seen examples here and they seem to be working for others so i would like to figure out where i am going wrong.

                       
Code: [Select]
if (velocity.x < 0)
{
velocity *= walkSpeed;
if (anim.isPlaying() && anim.currentClip.name != "MarioSmallWalkLeft")
anim.Play("MarioSmallWalkLeft");
jumpEnable = false;
}

the problem is with the if (anim.isPlaying() && anim.currentClip.name != "MarioSmallWalkLeft") line.

the error i am getting is `tk2dAnimatedSprite.currentClip' is inaccessible due to its protection level.

Can anyone shed any light on why this is happening?

Thanks.

Pages: [1]