effects package

Module contents

Provides access to all effects within the engine.

class effects.BloodColor

Bases: Boost.Python.enum

DONT_BLEED = _effects.BloodColor.DONT_BLEED
GREEN = _effects.BloodColor.GREEN
MECH = _effects.BloodColor.MECH
RED = _effects.BloodColor.RED
YELLOW = _effects.BloodColor.YELLOW
names = {'DONT_BLEED': _effects.BloodColor.DONT_BLEED, 'RED': _effects.BloodColor.RED, 'YELLOW': _effects.BloodColor.YELLOW, 'GREEN': _effects.BloodColor.GREEN, 'MECH': _effects.BloodColor.MECH}
values = {-1: _effects.BloodColor.DONT_BLEED, 0: _effects.BloodColor.RED, 1: _effects.BloodColor.YELLOW, 2: _effects.BloodColor.GREEN, 3: _effects.BloodColor.MECH}
class effects.ShatterSurface

Bases: Boost.Python.enum

GLASS = _effects.ShatterSurface.GLASS
TILE = _effects.ShatterSurface.TILE
names = {'GLASS': _effects.ShatterSurface.GLASS, 'TILE': _effects.ShatterSurface.TILE}
values = {0: _effects.ShatterSurface.GLASS, 1: _effects.ShatterSurface.TILE}
effects.ball(recipients, center, radius, steps=15, upper_half=True, lower_half=True, **kwargs)[source]

Create a ball by using the remporary effect BeamRingPoint.

Parameters:
  • recipients (RecipientFilter) – Players that should see the beam.
  • center (Vector) – The center location of the ball.
  • radius (float) – The radius of the ball.
  • steps (int) – Number of rings that should be used to create the ball.
  • upper_half (bool) – If False, the upper half of the ball isn’t created.
  • lower_half (bool) – If False, the lower half of the ball isn’t created.

Note

The number of steps is used for the lower and upper half. So, if you define 15 steps, 29 rings are created (the center ring is shared by both halves).

effects.beam(recipients, start, end, parent=False, **kwargs)[source]

A simple wrapper for the temporary effect BeamEntPoint.

Parameters:
  • recipients (RecipientFilter) – Players that should see the beam.
  • start (int/BaseEntity/Vector) – The start location of the beam.
  • end (int/BaseEntity/Vector) – The end location of the beam.
  • parent (bool) – If True, the beam will be parented to the given entities.
  • kwargs – Additional attributes that will be send to the effect.
effects.box(recipients, start, end, **kwargs)[source]

Create a box using the temporary effect BeamPoints.

Parameters:
  • recipients (RecipientFilter) – Players that should see the beam.
  • start (Vector) – Upper left corner of the box.
  • end (Vector) – Lower right corner of the box.
  • kwargs – Additional attributes that will be send to the effect.
effects.polygon(recipients, points, parent=False, **kwargs)[source]

Create a polygon using beam().

Parameters:
  • recipients (RecipientFilter) – Players that should see the beam.
  • points (iterable) – An iterable that contains at least 3 mathlib.Vector instances.
  • parent (bool) – If True, the beam will be parented to the given entities.
  • kwargs – Additional attributes that will be send to the effect.
effects.square(recipients, start, end, **kwargs)[source]

Create a square using the temporary effect BeamPoints.

Parameters:
  • recipients (RecipientFilter) – Players that should see the beam.
  • start (Vector) – Upper left corner of the square.
  • end (Vector) – Lower right corner of the square.
  • kwargs – Additional attributes that will be send to the effect.