Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TileMode opacity fix #414

Merged
merged 1 commit into from
Dec 30, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/UI/Canvas/TileMode.gd
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ func _draw() -> void:
var current_cels : Array = Global.current_project.frames[Global.current_project.current_frame].cels
var size : Vector2 = Global.current_project.size
var positions : Array = get_tile_positions(size)
var tilemode_opacity = 1.0 - Global.tilemode_opacity
var tilemode_opacity := Global.tilemode_opacity

var _position := position
var _scale := scale
Expand All @@ -18,7 +18,7 @@ func _draw() -> void:
draw_set_transform(_position, rotation, _scale)

for i in range(Global.current_project.layers.size()):
var modulate_color := Color(1, 1, 1, current_cels[i].opacity - tilemode_opacity)
var modulate_color := Color(1, 1, 1, current_cels[i].opacity * tilemode_opacity)
if Global.current_project.layers[i].visible: # if it's visible
if Global.current_project.tile_mode:
for pos in positions:
Expand Down