Kraken Logo

Kraken Engine

DocumentationGuidesShowcaseCommunity
Ctrl
K
Navigating the Docs
Building Docs
Overview
Anchor
AnimationController
Audio
Batcher
Body
Camera
Capsule
CastHit
CharacterBody
Circle
Collision
Color
DistanceJoint
Effect
Event
FilterJoint
Flip (Texture)
Font
ImageLayer
InputAction
Joint
Layer
Line
Map
MapObject
Mask
MotorJoint
MouseJoint
ObjectGroup
Orchestrator
PixelArray
PolarCoordinate
Polygon
PrismaticJoint
Rect
RevoluteJoint
RigidBody
Sample
Sampler
Shader
SheetStrip
StaticBody
Stream
Style
Terrain (TileSet)
Text
TextProperties
Texture
Tile (TileLayer)
Tile (TileSet)
TileLayer
TileResult (TileLayer)
TileSet
Timer
Transform
Tween
Vec2
Vertex
WeldJoint
WheelJoint
World

Built bydurkisneer1.Kraken Engine is open source and available onGitHub.

  1. Docs
  2. Classes
  3. Color

Color

Represents an RGBA color.

Constructor

  • Color() → ColorColor() → Color
  • Color(r: int, g: int, b: int, a: int = 255) → ColorColor(r: int, g: int, b: int, a: int = 255) → Color
  • Color(hex: str) → ColorColor(hex: str) → Color

Represents an RGBA color.

Properties


NameDescriptionType
BLACKColor(0, 0, 0, 255)Color
BLUEColor(0, 0, 255, 255)Color
BROWNColor(139, 69, 19, 255)Color
CYANColor(0, 255, 255, 255)Color
DARK_GRAYColor(64, 64, 64, 255)Color
GRAYColor(128, 128, 128, 255)Color
GREENColor(0, 255, 0, 255)Color
LIGHT_GRAYColor(192, 192, 192, 255)Color
MAGENTAColor(255, 0, 255, 255)Color
MAROONColor(128, 0, 0, 255)Color
NAVYColor(0, 0, 128, 255)Color
OLIVEColor(128, 128, 0, 255)Color
ORANGEColor(255, 165, 0, 255)Color
PINKColor(255, 192, 203, 255)Color
PURPLEColor(128, 0, 128, 255)Color
REDColor(255, 0, 0, 255)Color
TEALColor(0, 128, 128, 255)Color
WHITEColor(255, 255, 255, 255)Color
YELLOWColor(255, 255, 0, 255)Color
aAlpha (transparency) channel value.int
bBlue channel value.int
gGreen channel value.int
hexGet or set the color as a hex string.str
hsvGet or set the color as an HSV tuple.tuple[float, float, float, float]
rRed channel value.int

Methods


Copy

copy() → Colorcopy() → Color

Create a copy of the color.

Returns

Color : A new Color object with the same RGBA values.

PreviousCollision
NextDistanceJoint

On this page

ConstructorPropertiesMethodsCopy