mirror of
https://github.com/tonytins/CozyPixelStudio.git
synced 2025-12-17 05:04:42 -05:00
The world_2d of the preview viewports is no longer the same as the main viewport's
A "CanvasPreview" Node2D has been added to every preview viewport, where it draws the current frame. This solves #205.
This commit is contained in:
parent
2371238ec0
commit
e6aea97f1b
7 changed files with 55 additions and 27 deletions
17
src/UI/TransparentChecker.tscn
Normal file
17
src/UI/TransparentChecker.tscn
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
[gd_scene load_steps=4 format=2]
|
||||
|
||||
[ext_resource path="res://src/Shaders/TransparentChecker.shader" type="Shader" id=1]
|
||||
[ext_resource path="res://src/UI/TransparentChecker.gd" type="Script" id=2]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=1]
|
||||
shader = ExtResource( 1 )
|
||||
shader_param/size = 10.0
|
||||
shader_param/color1 = Color( 0.7, 0.7, 0.7, 1 )
|
||||
shader_param/color2 = Color( 1, 1, 1, 1 )
|
||||
|
||||
[node name="TransparentChecker" type="ColorRect"]
|
||||
material = SubResource( 1 )
|
||||
margin_right = 40.0
|
||||
margin_bottom = 40.0
|
||||
mouse_filter = 2
|
||||
script = ExtResource( 2 )
|
||||
Loading…
Add table
Add a link
Reference in a new issue