ParticleSystem access code question.

Currently using version 5.3.3f1.

(1) particle.shape.radius = 1.0f;

(2) ParticleSystem.ShapeModule shapeModule = particle.shape;
shapeModule.radius = 1.0f;

If i write code like (1), an error occurs. However, if it is assigned to temporary variables like (2), it works properly. What is the reason why i can access the value if i assign it to a temporary variable? i can see that the get and set methods are implemented when i hover mouse, but can not access them right away. What does it change by assigning it to a temporary variable?

I think that you first need to identify what it is… What you first did wrong was that you were trying to save the 1.0f in nothing. Later you created a shapeModule and then you gave it a value.

Or it was something else… :l