Renaming ParticleSystem:setAreaSpread etc. to be more clear

Issue #1311 resolved
hahawoo
created an issue

I don't think the name ParticleSystem:setAreaSpread is perfectly clear.

It defines an area from which particles are emitted. I get that the location that particles are emitted from could be said to be "spread" within this area, but the term "spread" is already used to mean something different in ParticleSystem:setSpread.

I think that setEmissionArea is a clearer name, because it could be said to "set the emission area", whereas setAreaSpread couldn't really be said to "set the area spread".

getAreaSpreadAngle then becomes setEmissionAreaAngle.

setAreaSpreadIsRelativeDirection is particularly hard to understand in my experience. What it means is that, when set to true, the directions of particles are relative to their initial position within the emission area (and the direction set by setDirection is relative to this direction).

I think that setDirectionRelativeToEmissionArea and isDirectionRelativeToEmissionArea are clearer names. The setter could be said to "set the direction (of particles) relative to (their initial position in the) emission area". (I also like that it starts with "Direction" instead of "EmissionArea"/"AreaSpread" because it changes the direction, not the emission area.)

(After writing this I noticed that the term "emission area" is used in the title of #1172, so I guess I'm not the only person who thinks of it as that.)

Comments (1)

  1. Log in to comment