sprockets The Snowman is coming! Realistic head model by Dan Skelton Vintage character and mo-cap animation by Joe Williamsen Character animation exercise by Steve Shelton an Animated Puppet Parody by Mark R. Largent Sprite Explosion Effect with PRJ included from johnL3D New Radiosity render of 2004 animation with PRJ. Will Sutton's TAR knocks some heads!
sprockets
Recent Posts | Unread Content
Jump to content
Hash, Inc. - Animation:Master

Expression help


johnl3d

Recommended Posts

Expression experts

 

Was wondering if its possible to have a statement that says

 

if (Chortime() >.5 and Chortime()

 

 

I know this works

If(ChorTime()>0.5,ChorTime()*1000){,0}))

 

it passes the variable Chortime()*1000 after 15 frames which is .5 of 30

 

What I was thinking was lets say Thom is wearing a bowtie at frame 15 to 30 a good looking female thom goes by and therefore his bowtie spins

I tried a number of combinations but get a syntax err

 

Anyone know ?

Link to comment
Share on other sites

  • Replies 11
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

I'm not an "Expression expert", but you might try nesting IF statements.

 

if (Chortime() >.5, if( Chortime()<1,Chortime()*1000{,0}))

 

Just a thought :blink:

 

Just tried it: If(ChorTime()>0.5,If(ChorTime()<1,ChorTime()*1000,0),0)

 

It works B)

You can leave the ",0"'s off as they seem to be optional and zero is the default.

Link to comment
Share on other sites

From: "johnl" johnl3dx@excite.com

Date: 2004-4-29 23:41:46

 

as you suggested

I'm not an "Expression expert", but you might try nesting IF statements if(Chortime()>.5,if( Chortime()<1,Chortime()*1000{,0}))

thanks but get a syntax error..

johnl3d

 

_______________________________________________

Join Excite! - http://www.excite.com

The most personalized portal on the Web!

.

Link to comment
Share on other sites

sorry for double post but found a way to sort of solve my example

 

 

If(Round(ChorTime(),1)=1,ChorTime()*1000){,0}))

 

but this is clumsy it now will return right value from .5 to 1.4 I think at least it starts and stops about there

 

still looking for other ideas

 

 

 

Haven't programed for awhile...getting to old for this... :blink::rolleyes:B)

Link to comment
Share on other sites

You are right! thank you and anyone else reading this will thank you too

not sure what I did wrong when I tried it but you're answer I copied and pasted and It worked...

 

now where's the bow tie

Link to comment
Share on other sites

a good looking female thom goes by and therefore his bowtie spins

You said you'd do it, and you did.

 

Now that you've got me interested in expresions, I found the functions (drop down from the expresion edit window), but where do I find the list of A:M values/variable (i.e. ChorTime()).

Link to comment
Share on other sites

From: "johnl" johnl3dx@excite.com

Date: 2004-4-30 08:06:22

 

From: Ganthofer : Glenn Anthofer : help with condition statement< John,< Now that you've got me interested in expresions. I found the functions (drop down from the expresion edit window), but where do I find the list of A:M values/variable (i.e. ChoreTime()

I got most of my information which is rather limited to the propeller posting

and this tutorial

http://users.hol.gr/~sogou/animaster/expressions.htm

 

there is some stuff in the online tech reference too

 

 

Anyone else...?????

http://www.hash.com/htmlHelp/v10.5/Technical_Reference.htm

 

_______________________________________________

Join Excite! - http://www.excite.com

The most personalized portal on the Web!

.

Link to comment
Share on other sites

I do not have AM yet, but I am a programmer. (no I don't play one on tv)

 

Your code:

if (Chortime() >.5 and Chortime()<1,Chortime()*1000{,0})

 

 

Looks to me like it should be:

if (Chortime() >.5 && Chortime()<1,Chortime()*1000{,0})

 

or

if (Chortime() >.5 And Chortime()<1,Chortime()*1000{,0})

 

Note the upper case A.

 

And a tip on getting a responce to code snippits.

Always include the syntax error message.

 

Just trying to help.

Jack

Link to comment
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...