Host typegenerated
Light2d
A light in a 2D scene: it brightens sprites, tiles and shapes near it when the scene's environment turns 2D lighting on, in every direction or, with a cone_angle below 360, in a beam. Switch one off with its object's set_active.
8 members · engine 0.1.0
Light2d.color: ColorThe light's color. Loweringadims it, the way it fades a sprite.Light2d.cone_angle: numberHow wide the beam is, in degrees across: 360 lights every way, less is a spot light that lights only a cone. Must stay above 0 and at most 360.Light2d.cone_direction: numberWhere the beam points, in degrees: 0 is right and 90 is up. Write it each frame to sweep a beam.Light2d.cone_softness: numberHow much of the beam's width fades out at its edge, 0 to 1: 0 is a hard edge, 1 is brightest only along the middle.Light2d.falloff: numberHow the light fades toward its edge: 1 fades evenly, higher numbers keep it bright near the middle and drop off sharply.Light2d.height: numberHow high above the scene the light hangs. Only images with a normal map notice: low lights rake across their bumps, high ones light them evenly.Light2d.intensity: numberHow bright the light is; 0 is off.Light2d.radius: numberHow far the light reaches, in world units.
- Source
- docs/generated/decay-api.json
- Schema
- v1
- Engine version
- 0.1.0
- Source commit
909aca81368b