Notifications
Clear all

[Closed] Simple Mod Animatable not working 2009?

I have a scripted modifier that has some animatable properties. It works fine in 2008 but in 2009 the modifier is no longer animatable. All of the properties have animatable:true set. Is this just me or has anyone else had this issue, also any suggestions on how to fix would be great. Thanks,

-bnvm

7 Replies

hi,

i have the same problem.


bo_default = attributes bo_default_definition
attribID:#(0x2d8552ed, 0x4f2b95b0)
version:1
(
 parameters main
 (
 bo_film_iso   type:#integer default:100 	 animatable:true 
bo_camera_shutter  type:#float default:1000 	animatable:true
bo_f_number   type:#float default:5.3 	 animatable:true
bo_vignetting   type:#float default:0.0 	 animatable:true
bo_film_iso_slider  type:#integer default:2 
bo_camera_shutter_slider type:#integer default:10
bo_f_number_slider  type:#integer default:5
)
)

can anybody help?

are you sure you have the same problem, Thorsten?


maxVersion()
#(11000, 25, 0)
$
$GeoSphere:GeoSphere01 @ [36.531364,-0.000001,12.915129]
custAttributes.add $ bo_default
true
with animate on at time 100 ( $.bo_film_iso = 200.0 )
200.0
at time 0 ( $.bo_film_iso )
100
at time 100 ( $.bo_film_iso )
200

Keyframes also show up in the timeslider and in trackview. Tested both 3ds max 2008 and 2009 – the above is 2009, sp3 ( not quite sure if the ‘sp3’ is reflected in the maxVersion() result )

Can’t say I’ve done much with scripted modifiers, but mine are okay. Here’s the Help file example adjusted to have its one parameter be animatable:


plugin simpleMod saddle
	name:"SaddleDeform"
	classID:#(685325,452281)
	version:1 ( 

	parameters main rollout:params (
		amount type:#integer ui:amtSpin default:20 animatable:true
	)

	rollout params "Saddle Parameters" (
		spinner amtSpin "Amount: " type:#integer range:[0,1000,20]
	)

	on map i p do (
		p.z += amount * sin((p.x * 22.5/extent.x) * (p.y * 22.5/extent.y))
		p
	)
)

See if that works? Worked fine in 2008 and 2009sp3 here.

ah thank you very much.

Hi

when i try it, comes a error.


macroScript Photostudio category:"mental ray" buttonText:"Photo Studio Pro (eng)" tooltip:"Photo Studio Pro (eng)" icon:#("Exposure",1)
(
parameters main rollout:rDOF (
ani_mount type:#integer ui:amount default:20 animatable:true
) 

Error:


-- Error occurred in anonymous codeblock; filename: C:\Documents and Settings	horsten\Local Settings\Application Data\Autodesk\3dsmax\2009 - 64bit\enu\UI\usermacros\mental ray-Photostudio.mcr; position: 154
-- Syntax error: at parameters, expected <factor>
-- In line: parameters m

rDOF is the Name of Rollout
amount is the Rollout-Button
ani_amount is the Variable

mfg
hot chip

hi thorsten,

Looks like you’re confusing macroscripts with scripted plugins.

Macroscripts (definitions starting with ‘macroscript’) are only containers for script code, allowing you to use that script code in toolbar buttons, menu items, the right-click menu, etc.

Scripted plugin definitions (starting with ‘plugin’) are what allow you to create ‘plugins’ that show up in things like the create panel, modify panel, material editor, etc. depending on the plugin you’re scripting.

In your case, as you’re scripting a modifier plugin, you would be using something like:


 plugin simpleMod photostudio
 	name:"Photo Studio Pro (eng)"
 	classID:#(0x5d8f8ad0, 0x3d2c7ed6)
 	version:1 (
 
 	rollout rDOF "rDOF" (
 		spinner amount "amount"
 	)
 
 	parameters main rollout:rDOF (
 		ani_mount type:#integer ui:amount default:20 animatable:true
 	)
 )
 

However, I’m not sure if a scripted modifier plugin is actually what you’re looking for – as scripted ‘simple’ modifiers are typically used to adjust geometry – whereas the nature of your code leads me to believe that you would be modifying existing parameters of a camera type.

If the latter is the case, you may wish to write a scripted camera plugin instead, which then ‘extends’ the existing camera plugin’s class. That gives you direct access to the original camera’s parameters, while being able to specify your own parameters, own user interface and even your own camera mesh (if desired).
Check the “Scripted Camera Plug-ins” topic for more information on this

ah,

know i am understand. Thank you…

mfg
hot chip