online multiplayer chess game (note server currently down)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
[gd_scene load_steps=6 format=2]

[ext_resource path="res://Square.gd" type="Script" id=1]
[ext_resource path="res://assets/ui/whitespace.png" type="Texture" id=2]

[sub_resource type="RectangleShape2D" id=1]

[sub_resource type="Shader" id=2]
code = "shader_type canvas_item;

uniform float amt : hint_range(0.0, 1.0);
uniform vec4 color : hint_color;

void fragment() 
{
	if (distance(UV, vec2(0.5,0.5)) > amt/2.0) 
	{
		COLOR = vec4(0.0);
	}
	else 
	{
		COLOR = vec4(color);
	}
}"

[sub_resource type="ShaderMaterial" id=3]
shader = SubResource( 2 )
shader_param/amt = 1.0
shader_param/color = Color( 0.431373, 0.584314, 0.388235, 0.639216 )

[sub_resource type="Shader" id=2]
code = "shader_type canvas_item;

uniform float amt : hint_range(0.0, 1.0);
uniform vec4 color : hint_color;

void fragment() 
{
	if (distance(UV, vec2(0.5,0.5)) > amt/2.0) 
	{
		COLOR = vec4(0.0);
	}
	else 
	{
		COLOR = vec4(color);
	}
}"

[sub_resource type="ShaderMaterial" id=3]
shader = SubResource( 2 )
shader_param/amt = 1.0
shader_param/color = Color( 0.431373, 0.584314, 0.388235, 0.639216 )

[node name="Square" type="ColorRect"]
anchor_right = 1.0
anchor_bottom = 1.0
margin_right = -1180.0
margin_bottom = -780.0
mouse_filter = 2
script = ExtResource( 1 )

[node name="Squarea" type="Area2D" parent="."]
collision_mask = 0
monitoring = false
monitorable = false

[node name="CollisionShape2D" type="CollisionShape2D" parent="Squarea"]
visible = false
z_index = 3
shape = SubResource( 1 )

[node name="Circle" type="Sprite" parent="."]
visible = false
material = SubResource( 3 )
position = Vector2( 8, 8 )
scale = Vector2( 25, 25 )
texture = ExtResource( 2 )

[connection signal="input_event" from="Squarea" to="." method="_on_Squarea_input_event"]