RemoveUserParameter

Introduced

3.5

Description

Removes a user parameter from the particle types given either explicitely (list of particle types) or implicitely (list of clouds).

If one or several particles types are passed as arguments, the user parameter is removed from these particle types. If one or several clouds are passed as arguments, the user parameter is removed from all the particle types present under the clouds.

Scripting Syntax

RemoveUserParameter( [Target], Name )

Parameters

Parameter

Type

Description

Target

String

One or several particle types or clouds.

Default Value: Current selection

Name

String

The name of the parameter to remove.

Examples

VBScript Example

'
'  This example demonstrates how to use the RemoveUserParameter command 
'  to remove an attribute on a particle type
'
NewScene , false
set oParticleType = CreateParticleType()(0)

AddUserParameter oParticleType, "ZetaFactor", siPAVector3 
' Oh no I meant MyZetaFactor
RemoveUserParameter oParticleType, "ZetaFactor" 
AddUserParameter oParticleType, "MyZetaFactor", siPAVector3 

PrintParticleTypeUserAttributes oParticleType 

sub PrintParticleTypeUserAttributes( in_ParticleType )
   aNames = in_ParticleType.AttributeNames
   for each attrib in aNames
       Application.LogMessage aNames(i)
       str = "This attribute type is "

       select case in_ParticleType.AttributeType( aNames(i) ) 
          case siPAVector4 
              str = str & "siPAVector4"
          case siPAVector3 
              str = str & "siPAVector3"
          case siPAFloat 
              str = str & "siPAFloat"
          case siPAInt 
              str = str & "siPAInt"
          case siPAULong 
              str = str & "siPAULong"
          case siPAUShort 
              str = str & "siPAUShort"
          case siPABool 
              str = str & "siPABool"
          case else 
              str = str & "unknown."
       end select
       Application.LogMessage str 
   next
end sub

' Expected results:
'INFO : MyZetaFactor
'INFO : This attribute type is siPAVector3

See Also

AddUserParameter

ParticleAttribute

ParticleType.RemoveAttribute

ParticleType

Particle

 

 

 



Autodesk Softimage v7.5