summaryrefslogtreecommitdiff
path: root/doc/classes
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2020-05-07 21:16:51 +0200
committerGitHub <noreply@github.com>2020-05-07 21:16:51 +0200
commitae33cf5f458a57fbf8aa3ec0a65c94e86cd4d6f4 (patch)
treebad1a6e46923b7ea1f77d328bb47525e5e348d12 /doc/classes
parentbef52957d00c50323824e4fa0a778453214721cf (diff)
parent90df1d67cbc06f2742c11dad57ca940b9ed7c0d4 (diff)
Merge pull request #36379 from aaronfranke/color-constructors
Add a Color constructor for Color with alpha
Diffstat (limited to 'doc/classes')
-rw-r--r--doc/classes/Color.xml14
1 files changed, 14 insertions, 0 deletions
diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml
index 1af5c87532..b35d4fb36a 100644
--- a/doc/classes/Color.xml
+++ b/doc/classes/Color.xml
@@ -42,6 +42,20 @@
<method name="Color">
<return type="Color">
</return>
+ <argument index="0" name="c" type="Color">
+ </argument>
+ <argument index="1" name="a" type="float">
+ </argument>
+ <description>
+ Constructs a color from an existing color, but with a custom alpha value.
+ [codeblock]
+ var red = Color(Color.red, 0.5) # 50% transparent red.
+ [/codeblock]
+ </description>
+ </method>
+ <method name="Color">
+ <return type="Color">
+ </return>
<argument index="0" name="r" type="float">
</argument>
<argument index="1" name="g" type="float">