Board Scene: Chip spawning and basic error checking
This commit is contained in:
26
scenes/board_screen.tscn
Normal file
26
scenes/board_screen.tscn
Normal file
@@ -0,0 +1,26 @@
|
||||
[gd_scene load_steps=4 format=3 uid="uid://m542qwlp7hl7"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dg5jt0o0r0v3r" path="res://scripts/BoardScreen.cs" id="1_b3w8x"]
|
||||
[ext_resource type="PackedScene" uid="uid://d1wr0v5ht8vqb" path="res://scenes/button_small.tscn" id="1_tbc1w"]
|
||||
|
||||
[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_b3w8x"]
|
||||
|
||||
[node name="BoardScreen" type="Node2D"]
|
||||
script = ExtResource("1_b3w8x")
|
||||
|
||||
[node name="StaticBody2D" type="StaticBody2D" parent="."]
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="StaticBody2D"]
|
||||
shape = SubResource("WorldBoundaryShape2D_b3w8x")
|
||||
|
||||
[node name="SpwnRed" parent="." instance=ExtResource("1_tbc1w")]
|
||||
offset_left = 512.0
|
||||
offset_top = -324.0
|
||||
offset_right = 576.0
|
||||
offset_bottom = -292.0
|
||||
|
||||
[node name="SpwnYlw" parent="." instance=ExtResource("1_tbc1w")]
|
||||
offset_left = 512.0
|
||||
offset_top = -292.0
|
||||
offset_right = 576.0
|
||||
offset_bottom = -260.0
|
||||
@@ -17,22 +17,24 @@ atlas = ExtResource("2_q2stu")
|
||||
region = Rect2(8, 0, 32, 16)
|
||||
|
||||
[node name="ButtonSmall" type="TextureButton"]
|
||||
offset_top = -16.0
|
||||
offset_left = -32.0
|
||||
offset_top = -32.0
|
||||
offset_right = 32.0
|
||||
texture_normal = SubResource("AtlasTexture_6ptbq")
|
||||
texture_pressed = SubResource("AtlasTexture_06p6p")
|
||||
texture_hover = SubResource("AtlasTexture_q2stu")
|
||||
stretch_mode = 4
|
||||
script = ExtResource("2_06p6p")
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
layout_mode = 0
|
||||
offset_left = 1.0
|
||||
offset_top = 5.0
|
||||
offset_right = 31.0
|
||||
offset_bottom = 13.0
|
||||
offset_left = 2.0
|
||||
offset_top = 9.0
|
||||
offset_right = 62.0
|
||||
offset_bottom = 25.0
|
||||
theme_override_colors/font_color = Color(2.7723312e-05, 0.60865843, 0.9772685, 1)
|
||||
theme_override_fonts/font = ExtResource("3_dxjfy")
|
||||
theme_override_font_sizes/font_size = 8
|
||||
theme_override_font_sizes/font_size = 16
|
||||
text = "TEMP"
|
||||
horizontal_alignment = 1
|
||||
|
||||
|
||||
@@ -4,16 +4,15 @@
|
||||
[ext_resource type="Script" uid="uid://b1ogflafdte71" path="res://scripts/create_join_room.gd" id="1_k6yuv"]
|
||||
|
||||
[node name="CreateJoinRoom" type="Node2D"]
|
||||
position = Vector2(0, 42)
|
||||
script = ExtResource("1_k6yuv")
|
||||
|
||||
[node name="JoinGameButton" parent="." instance=ExtResource("1_4km6l")]
|
||||
offset_left = -16.0
|
||||
offset_top = 12.0
|
||||
offset_right = 16.0
|
||||
offset_bottom = 28.0
|
||||
offset_top = 17.0
|
||||
offset_bottom = 49.0
|
||||
metadata/_edit_use_anchors_ = true
|
||||
|
||||
[node name="CreateGameButton" parent="." instance=ExtResource("1_4km6l")]
|
||||
offset_left = -16.0
|
||||
offset_top = 40.0
|
||||
offset_right = 16.0
|
||||
offset_bottom = 56.0
|
||||
offset_top = 85.0
|
||||
offset_bottom = 117.0
|
||||
metadata/_edit_use_anchors_ = true
|
||||
|
||||
@@ -1,12 +1,15 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://cr8fi0e4r88s8"]
|
||||
[gd_scene load_steps=3 format=3 uid="uid://cr8fi0e4r88s8"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://cct663hb47yka" path="res://scenes/create_join_room.tscn" id="1_uwrxv"]
|
||||
[ext_resource type="PackedScene" uid="uid://m542qwlp7hl7" path="res://scenes/board_screen.tscn" id="2_yqjtg"]
|
||||
|
||||
[node name="Game" type="Node2D"]
|
||||
|
||||
[node name="GameManager" type="Node" parent="."]
|
||||
|
||||
[node name="Camera2D" type="Camera2D" parent="."]
|
||||
zoom = Vector2(5, 5)
|
||||
|
||||
[node name="CreateJoinRoom" parent="." instance=ExtResource("1_uwrxv")]
|
||||
visible = false
|
||||
|
||||
[node name="BoardScreen" parent="." instance=ExtResource("2_yqjtg")]
|
||||
|
||||
14
scenes/red_chip.tscn
Normal file
14
scenes/red_chip.tscn
Normal file
@@ -0,0 +1,14 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://b4tujjdhmk4h"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://ckmfi0cjgxgyk" path="res://assets/sprites/RedChip.png" id="1_qsflu"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_tfypd"]
|
||||
radius = 12.0415945
|
||||
|
||||
[node name="RedChip" type="RigidBody2D"]
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("1_qsflu")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("CircleShape2D_tfypd")
|
||||
14
scenes/yellow_chip.tscn
Normal file
14
scenes/yellow_chip.tscn
Normal file
@@ -0,0 +1,14 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://lruk652t0xe5"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://qy30emdgrk7o" path="res://assets/sprites/YellowChip.png" id="1_eu0sq"]
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_epi6l"]
|
||||
radius = 12.0
|
||||
|
||||
[node name="YellowChip" type="RigidBody2D"]
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="."]
|
||||
texture = ExtResource("1_eu0sq")
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||
shape = SubResource("CircleShape2D_epi6l")
|
||||
Reference in New Issue
Block a user