phaser - v4.0.0-rc.4
    Preparing search index...
    • Takes an array of Game Objects and then modifies their property so the value equals, or is incremented, by the calculated spread value.

      The spread value is derived from the given min and max values and the total number of items in the array.

      For example, to cause an array of Sprites to change in alpha from 0 to 1 you could call:

      Phaser.Actions.Spread(itemsArray, 'alpha', 0, 1);
      

      Type Parameters

      Parameters

      • items: G

        An array of Game Objects. The contents of this array are updated by this Action.

      • property: string

        The property of the Game Object to spread.

      • min: number

        The minimum value.

      • max: number

        The maximum value.

      • Optionalinc: boolean

        Should the values be incremented? true or set (false) Default false.

      Returns G