mirror of
https://github.com/scratchfoundation/scratch-vm.git
synced 2024-12-24 06:52:40 -05:00
On set color using picker, reset transparency to 0
This commit is contained in:
parent
a32f7a6402
commit
aab1b834d6
1 changed files with 2 additions and 0 deletions
|
@ -383,6 +383,7 @@ class Scratch3PenBlocks {
|
|||
|
||||
/**
|
||||
* The pen "set pen color to {color}" block sets the pen to a particular RGB color.
|
||||
* The transparency is reset to 0.
|
||||
* @param {object} args - the block arguments.
|
||||
* @property {int} COLOR - the color to set, expressed as a 24-bit RGB value (0xRRGGBB).
|
||||
* @param {object} util - utility object provided by the runtime.
|
||||
|
@ -394,6 +395,7 @@ class Scratch3PenBlocks {
|
|||
penState.color = (hsv.h / 360) * 100;
|
||||
penState.saturation = hsv.s * 100;
|
||||
penState.brightness = hsv.v * 100;
|
||||
penState.transparency = 0;
|
||||
this._updatePenColor(penState);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue