part_type_alpha2

Sets a particle type to start at one alpha value and fade to another throughout its lifespan.

语法:

part_type_alpha2(ind, alpha1, alpha2);


参数 描述
ind The index of the particle type to change.
alpha1 The start alpha of the particle.
alpha2 The end alpha of the particle.


返回: N/A(无返回值)


描述

This function can be used to set an alpha value (transparency) gradient for each particle created of the given type. The first alpha is that which all particles will start with, and the second alpha is the one on with which the particle will end with, and a smooth gradient change will occur to the alpha over the particles lifetime from one to the other. This can be from 0 (transparent) to 1 (opaque).


例如:

part_type_alpha2(global.Snow_Part, 0, 1);

The above code will set all particles created of the particle type indexed in the global variable "Snow_Part" to have an alpha value of 0 (transparent) and then fade in to have an alpha of 1 (opaque) at the end of their lifetime.


上一页: Particle Types
下一页: part_type_alpha3
© Copyright YoYo Games Ltd. 2018 All Rights Reserved