diff --git a/source/Main.gd b/source/Main.gd index 5c9886a..33953fa 100644 --- a/source/Main.gd +++ b/source/Main.gd @@ -14,6 +14,7 @@ const password = "TETRIS 3000" const NEXT_POSITION = Vector3(13, 16, 0) const START_POSITION = Vector3(5, 20, 0) const HOLD_POSITION = Vector3(-5, 16, 0) +const THERE = Vector3(0, 0, 0) const movements = { "move_right": Vector3(1, 0, 0), @@ -70,12 +71,11 @@ func new_piece(): autoshift_action = "" next_piece = random_piece() next_piece.translation = NEXT_POSITION - if move(movements["soft_drop"]): + if move(THERE): $DropTimer.start() $LockDelay.start() current_piece_held = false else: - current_piece.translate(movements["soft_drop"]) game_over() func random_piece(): diff --git a/source/Main.tscn b/source/Main.tscn index ff4ff8e..533789b 100644 --- a/source/Main.tscn +++ b/source/Main.tscn @@ -1,7 +1,7 @@ [gd_scene load_steps=21 format=2] [ext_resource path="res://Main.gd" type="Script" id=1] -[ext_resource path="res://night-sky-background-14391263141jp.jpg" type="Texture" id=2] +[ext_resource path="res://pexels-photo-1341279.jpeg" type="Texture" id=2] [ext_resource path="res://Tetrominos/Mino/MinoLibrary.tres" type="MeshLibrary" id=3] [ext_resource path="res://GridMap.gd" type="Script" id=4] [ext_resource path="res://midi/MidiPlayer.tscn" type="PackedScene" id=5] @@ -236,7 +236,7 @@ script = ExtResource( 1 ) [node name="Sprite3D" type="Sprite3D" parent="." index="0"] -transform = Transform( 19.2, 0, 0, 0, 12.8, 0, 0, 0, 1, 5, 10, -80 ) +transform = Transform( 12.8, 0, 0, 0, 8.53, 0, 0, 0, 1, 5, 10, -30 ) layers = 1 material_override = null cast_shadow = 1 @@ -264,7 +264,7 @@ hframes = 1 frame = 0 region_enabled = false region_rect = Rect2( 0, 0, 0, 0 ) -_sections_unfolded = [ "Animation", "Flags", "Transform" ] +_sections_unfolded = [ "Animation", "Flags", "Geometry", "Transform" ] [node name="Camera" type="Camera" parent="." index="1"] @@ -336,7 +336,6 @@ NB_COLLUMNS = 10 [node name="Backs" type="Spatial" parent="." index="4"] -editor/display_folded = true visible = false [node name="GridBack" type="MeshInstance" parent="Backs" index="0"] diff --git a/source/pexels-photo-1341279.jpeg b/source/pexels-photo-1341279.jpeg new file mode 100644 index 0000000..d2d1406 Binary files /dev/null and b/source/pexels-photo-1341279.jpeg differ