Namespace Particles

Module to work with vanilla and custom particles.

Functions

  • Spawns EParticleType.ITEM_BREAK particles at a given location with a given item in world.

    Parameters

    • id: number

      numeric item ID

    • data: number

      item data

    • x: number
    • y: number
    • z: number

    Returns void

    Called only on the client side! Use packets to spawn particles for multiple players.

    2.4.0b119

  • Same as Particles.addParticle, but applies far shader to the particle.

    Parameters

    • type: number
    • x: number
    • y: number
    • z: number
    • vx: number
    • vy: number
    • vz: number
    • Optionaldata: number

    Returns void

  • Spawns particle of given type on given coords with given velocity and additional parameters in the world.

    Parameters

    • type: number

      particle type's numeric ID; if you want to spawn vanilla particles, see EParticleType enums

    • x: number
    • y: number
    • z: number
    • vx: number

      velocity for the particle by X-axis

    • vy: number

      velocity for the particle by Y-axis

    • vz: number

      velocity for the particle by Z-axis

    • Optionaldata: number

      additional params, currently don't know how to use, just put 0

    Returns void

    Called only on the client side! Use packets to spawn particles for multiple players.

  • Spawnds particles in line with specified gapness.

    Parameters

    • type: number

      particle type's numeric ID; if you want to spawn vanilla particles, see EParticleType enums

    • coords1: Vector

      start location of line

    • coords2: Vector

      end location of line

    • Optionalgap: number

      gapness means step of particles, values more than 1 will increase offsets between particles; randomized

    • Optionalvel: Vector

      velocity of spawned particles

    • Optionaldata: number

      variant of spawned particles or properties

    Returns void

  • Registers new custom particle type of given params object.

    Parameters

    Returns number

    Created particle type's numeric ID.

Copyright © 2024 Nernar. Copyright © 2020 #mineprogramming. Built with ❤ and TypeDoc.