Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Coding Poll Results

New Here ,
Jul 28, 2015 Jul 28, 2015

Hello,

I have some questions. I am creating a meter that I would update to put a number or percent of votes for a category collected on my website. I've made a flash document (http://wlqtdb.com/meter.swf), but what I am wanting to do is after it does one loop.. stop at a certain point.. We created a timeline where if you go slow, you can see it goes every certain amount of points.

I am wanting to create a function called Jolly.. with a number.. let's say 52.. 50 is at the edge of HO HO HO on this graphic. the meter arrow is actually called arrow in action script. I am new to action script, and would love to figure out how to go about doing this. Is there a way after it goes to HO HO HO and back to Bah Humbug, then go to the stop point? It can either begin to go forward until it gets there or just go there.. How would I go about doing this?

Thanks,

Mike

TOPICS
ActionScript
487
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 29, 2015 Jul 29, 2015

the easiest way would be to use actionscript to tween your arrows rotation property.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 29, 2015 Jul 29, 2015

Would you be willing to help me? I'd love to figure this out. I'd like to simply put a value at the top of the action script, and however the tween is set it will stop based on where the value is.

Thanks.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 29, 2015 Jul 29, 2015

it would be easier to use a third party tween like tweenlite.

google greensock's tweenlite.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 29, 2015 Jul 29, 2015

Can I use the background I have designed??

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 30, 2015 Jul 30, 2015

yes.

it's only the code that would change if you use the TweenLite class instead of the Tween class.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 30, 2015 Jul 30, 2015

I was looking and didn't see anything.. Wouldn't even be probable using ActionScript in flash??

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 30, 2015 Jul 30, 2015

you can use actionscript, but you may not get the exact effect you want:

//import the needed classes

var tween:Tween;

var endRotation:int = 260;  // or whatever

tween=new Tween(arrow,'rotation',youreasing,arrow.rotation,315,2,true);

tween.addEventListener(TweenEvent.MOTION_FINISH,finishF);

function finishF(e:TweenEvent):void{

tween.continueTo(260,2);

}

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 30, 2015 Jul 30, 2015

Depending on the number I type.. I actually have 52 keyframes.. It goes forward to HO HO HO then backwards to Bah Humbug.. After that I wanted it to go to a certain category depending on the value.. I didn't know if that was writing cases, etc.. I'm new to flash, but am eager to learn

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 30, 2015 Jul 30, 2015

eliminate all the frames except the first that has your arrow and the background.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 30, 2015 Jul 30, 2015

Wouldn't that stop the arrow from moving??? The only two elements are the arrow and the bg. There are 52 keyframes which actually make it move from one side to the other and backwards.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 31, 2015 Jul 31, 2015

again, the easiest way would be to use actionscript to tween your arrows rotation property.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 31, 2015 Jul 31, 2015

This is where I can use some help. I'm not very good at the actionscript aspect. I've got the keyframes figured out though.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 31, 2015 Jul 31, 2015
LATEST

you just need your first keyframe and the code is in message 7.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines