commit 68e8a4223f309678bb948fcbacec1f0bf60ce3e1 Author: notdraimdev Date: Mon Sep 9 09:17:29 2024 +0200 Simplaudio. diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..8ad74f7 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Normalize EOL for all files that Git considers text files. +* text=auto eol=lf diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..0af181c --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +# Godot 4+ specific ignores +.godot/ +/android/ diff --git a/BigLogo.png b/BigLogo.png new file mode 100644 index 0000000..9f3dfec Binary files /dev/null and b/BigLogo.png differ diff --git a/BigLogo.png.import b/BigLogo.png.import new file mode 100644 index 0000000..f4146d9 --- /dev/null +++ b/BigLogo.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b00wlqid2jdvi" +path="res://.godot/imported/BigLogo.png-5051142ace79d986d878d7479103140f.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://BigLogo.png" +dest_files=["res://.godot/imported/BigLogo.png-5051142ace79d986d878d7479103140f.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Cat_August_2010-4.jpg b/Cat_August_2010-4.jpg new file mode 100644 index 0000000..5fc9655 Binary files /dev/null and b/Cat_August_2010-4.jpg differ diff --git a/Cat_August_2010-4.jpg.import b/Cat_August_2010-4.jpg.import new file mode 100644 index 0000000..4b151b3 --- /dev/null +++ b/Cat_August_2010-4.jpg.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://drj8iwoxqu7kk" +path="res://.godot/imported/Cat_August_2010-4.jpg-ee22e0b2d7c21625ade8bb157ecd9ac0.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Cat_August_2010-4.jpg" +dest_files=["res://.godot/imported/Cat_August_2010-4.jpg-ee22e0b2d7c21625ade8bb157ecd9ac0.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/CoverShader.gdshader b/CoverShader.gdshader new file mode 100644 index 0000000..8e7b28a --- /dev/null +++ b/CoverShader.gdshader @@ -0,0 +1,17 @@ +shader_type canvas_item; + +uniform sampler2D dissolve; + +void vertex() { + // Called for every vertex the material is visible on. +} + +void fragment() { + vec4 tex = texture(dissolve,UV); + COLOR.a = tex.a; +} + +//void light() { + // Called for every pixel for every light affecting the CanvasItem. + // Uncomment to replace the default light processing function with this one. +//} diff --git a/Dropdown.png b/Dropdown.png new file mode 100644 index 0000000..cdae058 Binary files /dev/null and b/Dropdown.png differ diff --git a/Dropdown.png.import b/Dropdown.png.import new file mode 100644 index 0000000..0acdafe --- /dev/null +++ b/Dropdown.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dwvy6crqhardn" +path="res://.godot/imported/Dropdown.png-c266aedf7196a233015624b329244429.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Dropdown.png" +dest_files=["res://.godot/imported/Dropdown.png-c266aedf7196a233015624b329244429.ctex"] + +[params] + +compress/mode=1 +compress/high_quality=false +compress/lossy_quality=1.0 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=1 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=0 diff --git a/Evening_view_of_Munnar_1633.jpg b/Evening_view_of_Munnar_1633.jpg new file mode 100644 index 0000000..f70d65a Binary files /dev/null and b/Evening_view_of_Munnar_1633.jpg differ diff --git a/Evening_view_of_Munnar_1633.jpg.import b/Evening_view_of_Munnar_1633.jpg.import new file mode 100644 index 0000000..01d36ea --- /dev/null +++ b/Evening_view_of_Munnar_1633.jpg.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://snne8iiftksi" +path="res://.godot/imported/Evening_view_of_Munnar_1633.jpg-4870b614e5bd4e88e63602e1260d7057.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Evening_view_of_Munnar_1633.jpg" +dest_files=["res://.godot/imported/Evening_view_of_Munnar_1633.jpg-4870b614e5bd4e88e63602e1260d7057.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/File.png b/File.png new file mode 100644 index 0000000..79ed753 Binary files /dev/null and b/File.png differ diff --git a/File.png.import b/File.png.import new file mode 100644 index 0000000..7a8cf06 --- /dev/null +++ b/File.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://pgij783wgbhn" +path="res://.godot/imported/File.png-57bbd962d1d727ee4616fbeb9b4b7d6d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://File.png" +dest_files=["res://.godot/imported/File.png-57bbd962d1d727ee4616fbeb9b4b7d6d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Headphones.png b/Headphones.png new file mode 100644 index 0000000..39b7913 Binary files /dev/null and b/Headphones.png differ diff --git a/Headphones.png.import b/Headphones.png.import new file mode 100644 index 0000000..cfe9a81 --- /dev/null +++ b/Headphones.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cekkhyppj88xi" +path="res://.godot/imported/Headphones.png-d3ff607bfcad0de8118c5633a583eaf3.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Headphones.png" +dest_files=["res://.godot/imported/Headphones.png-d3ff607bfcad0de8118c5633a583eaf3.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Loding.png b/Loding.png new file mode 100644 index 0000000..eb4612d Binary files /dev/null and b/Loding.png differ diff --git a/Loding.png.import b/Loding.png.import new file mode 100644 index 0000000..3684038 --- /dev/null +++ b/Loding.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b5eims5ucn81r" +path="res://.godot/imported/Loding.png-13d0c1c393fa96e7f8c05bd230c70d68.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Loding.png" +dest_files=["res://.godot/imported/Loding.png-13d0c1c393fa96e7f8c05bd230c70d68.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Logo.png b/Logo.png new file mode 100644 index 0000000..fffca3c Binary files /dev/null and b/Logo.png differ diff --git a/Logo.png.import b/Logo.png.import new file mode 100644 index 0000000..f9a7640 --- /dev/null +++ b/Logo.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b5ml1dkiuo5ta" +path="res://.godot/imported/Logo.png-3f727bc575b71196031e5024c4a29f71.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Logo.png" +dest_files=["res://.godot/imported/Logo.png-3f727bc575b71196031e5024c4a29f71.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Logo2.png b/Logo2.png new file mode 100644 index 0000000..5bcba99 Binary files /dev/null and b/Logo2.png differ diff --git a/Logo2.png.import b/Logo2.png.import new file mode 100644 index 0000000..4ef381f --- /dev/null +++ b/Logo2.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://c7h2dlsbj7e0u" +path="res://.godot/imported/Logo2.png-d2b706aaa6822e4fe45113d605e69914.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Logo2.png" +dest_files=["res://.godot/imported/Logo2.png-d2b706aaa6822e4fe45113d605e69914.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Loop.png b/Loop.png new file mode 100644 index 0000000..4ff6586 Binary files /dev/null and b/Loop.png differ diff --git a/Loop.png.import b/Loop.png.import new file mode 100644 index 0000000..c5cf12b --- /dev/null +++ b/Loop.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://38c8dfym0svn" +path="res://.godot/imported/Loop.png-bfc3463d46fb58690ebdf4ee06fd021a.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Loop.png" +dest_files=["res://.godot/imported/Loop.png-bfc3463d46fb58690ebdf4ee06fd021a.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/LoopPressed.png b/LoopPressed.png new file mode 100644 index 0000000..acf8852 Binary files /dev/null and b/LoopPressed.png differ diff --git a/LoopPressed.png.import b/LoopPressed.png.import new file mode 100644 index 0000000..a0236f2 --- /dev/null +++ b/LoopPressed.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://b8on1case224h" +path="res://.godot/imported/LoopPressed.png-2571b6b294b9535da3cebb236adaaf3d.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://LoopPressed.png" +dest_files=["res://.godot/imported/LoopPressed.png-2571b6b294b9535da3cebb236adaaf3d.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Mai255.tmp b/Mai255.tmp new file mode 100644 index 0000000..eb518a9 --- /dev/null +++ b/Mai255.tmp @@ -0,0 +1,312 @@ +[gd_scene load_steps=26 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 2 +outline_color = Color(0, 0, 0, 1) +shadow_color = Color(0, 0, 0, 0.643137) +shadow_offset = Vector2(7.88, 4.31) + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="Sprite2D" parent="."] +position = Vector2(576.949, 401) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="Evening" type="Sprite2D" parent="."] +position = Vector2(582, 342) +scale = Vector2(1.00181, 1.00181) +texture = ExtResource("6_5vm0w") + +[node name="Nighttime" type="Sprite2D" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +position = Vector2(610, 326) +scale = Vector2(1.49056, 1.51111) +texture = ExtResource("6_8abnc") + +[node name="CoverHolder" type="Node2D" parent="."] +position = Vector2(-3, 649) + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +position = Vector2(200, -122.333) +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 20.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +text = "select the directory +(playlist's folder)" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 897.0 +offset_top = 24.0 +offset_right = 1132.0 +offset_bottom = 80.0 +focus_mode = 0 +text = "Randomize the Playlist" + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(470, 320) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] + +[node name="playList" type="Button" parent="."] +offset_left = 20.0 +offset_top = 572.0 +offset_right = 92.0 +offset_bottom = 644.0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 64.0 +offset_top = 560.0 +offset_right = 944.0 +offset_bottom = 624.0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="Skip2" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +offset_left = 1000.0 +offset_top = 573.0 +offset_right = 1040.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +offset_left = 994.0 +offset_top = 613.0 +offset_right = 1034.0 +offset_bottom = 653.0 +rotation = 3.14159 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +offset_left = 66.0 +offset_top = 524.0 +offset_right = 994.0 +offset_bottom = 581.0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchBar" type="TextEdit" parent="."] +offset_left = 266.0 +offset_top = 24.0 +offset_right = 888.0 +offset_bottom = 81.0 +placeholder_text = "Search" +wrap_mode = 1 +script = ExtResource("12_mr42x") + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(625, 300) +max_size = Vector2i(625, 300) +hide_on_state_item_selection = true +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +offset_left = 1092.0 +offset_top = 573.0 +offset_right = 1132.0 +offset_bottom = 613.0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_direction = 3 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1121.0 +offset_top = 563.0 +offset_right = -1103.0 +offset_bottom = 571.0 +grow_horizontal = 2 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="Logo" type="Sprite2D" parent="."] +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="TimeListeningSong" type="Label" parent="."] +offset_left = 66.0 +offset_top = 597.0 +offset_right = 178.0 +offset_bottom = 633.0 + +[node name="YtTabButton" type="Button" parent="."] +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = 1065.0 +offset_top = 107.0 +offset_right = 1713.0 +offset_bottom = 558.0 +grow_horizontal = 0 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 794.0 +offset_top = 107.0 +offset_right = 834.0 +offset_bottom = 147.0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -201.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_top = 58.0 +offset_right = 87.0 +offset_bottom = 98.0 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(113, 78) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Version" type="Label" parent="."] +offset_left = 1083.0 +offset_top = 625.0 +offset_right = 1147.0 +offset_bottom = 648.0 +text = "v0.9.2" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +position = Vector2i(495, 305) +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="text_changed" from="SearchBar" to="SearchBar" method="_on_text_changed"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/Mai3BB1.tmp b/Mai3BB1.tmp new file mode 100644 index 0000000..032c61f --- /dev/null +++ b/Mai3BB1.tmp @@ -0,0 +1,668 @@ +[gd_scene load_steps=53 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Shader" path="res://Main.gdshader" id="10_20857"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Texture2D" uid="uid://0r1tx6l1lc6x" path="res://settingscog.png" id="11_esjel"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Script" path="res://settings_button.gd" id="12_073mb"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Texture2D" uid="uid://myq6n4bshduj" path="res://search.png" id="12_cv2gm"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Script" path="res://search_toggle.gd" id="13_5illk"] +[ext_resource type="PackedScene" uid="uid://dqg674t6kun4e" path="res://Settings.tscn" id="13_7atry"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="14_mioc4"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ku7tv"] +shader = ExtResource("10_20857") +shader_parameter/intensity = 1.0 + +[sub_resource type="Gradient" id="Gradient_7vgyc"] +offsets = PackedFloat32Array(0.00292398, 0.845029) +colors = PackedColorArray(0, 0, 0, 0, 1, 1, 1, 1) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_bhdch"] +gradient = SubResource("Gradient_7vgyc") +fill_to = Vector2(0, 1) + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_x0ps1"] +device = -1 +ctrl_pressed = true +keycode = 68 + +[sub_resource type="Shortcut" id="Shortcut_vp2fh"] +events = [SubResource("InputEventKey_x0ps1")] + +[sub_resource type="LabelSettings" id="LabelSettings_0fjy0"] +font_size = 21 + +[sub_resource type="InputEventKey" id="InputEventKey_0jlka"] +device = -1 +ctrl_pressed = true +keycode = 82 + +[sub_resource type="Shortcut" id="Shortcut_axi6u"] +events = [SubResource("InputEventKey_0jlka")] + +[sub_resource type="InputEventKey" id="InputEventKey_117g0"] +device = -1 +ctrl_pressed = true +keycode = 83 + +[sub_resource type="Shortcut" id="Shortcut_8p5o4"] +events = [SubResource("InputEventKey_117g0")] + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="InputEventKey" id="InputEventKey_l1ahe"] +device = -1 +keycode = 4194321 + +[sub_resource type="Shortcut" id="Shortcut_qw6pv"] +events = [SubResource("InputEventKey_l1ahe")] + +[sub_resource type="InputEventKey" id="InputEventKey_c5qef"] +device = -1 +keycode = 76 +unicode = 108 + +[sub_resource type="Shortcut" id="Shortcut_vot6l"] +events = [SubResource("InputEventKey_c5qef")] + +[sub_resource type="InputEventKey" id="InputEventKey_y4cc2"] +device = -1 +keycode = 4194319 + +[sub_resource type="Shortcut" id="Shortcut_xu6hm"] +events = [SubResource("InputEventKey_y4cc2")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 3 +outline_color = Color(0.215902, 0.215902, 0.215902, 1) + +[sub_resource type="LabelSettings" id="LabelSettings_jg5vn"] +font_size = 20 +outline_size = 3 +outline_color = Color(0.393086, 0.393086, 0.393085, 1) + +[sub_resource type="InputEventKey" id="InputEventKey_puhgg"] +device = -1 +ctrl_pressed = true +keycode = 81 + +[sub_resource type="Shortcut" id="Shortcut_g3fcr"] +events = [SubResource("InputEventKey_puhgg")] + +[sub_resource type="LabelSettings" id="LabelSettings_fiiw4"] +font_size = 12 + +[node name="Node2D" type="Control"] +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("2_wf35v") +stretch_mode = 6 + +[node name="Evening" type="TextureRect" parent="."] +visible = false +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_5vm0w") +stretch_mode = 6 + +[node name="Nighttime" type="TextureRect" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_8abnc") +stretch_mode = 6 + +[node name="UserBG" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +expand_mode = 5 +stretch_mode = 6 + +[node name="Logo" type="Sprite2D" parent="."] +visible = false +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="PausedIndicator" type="TextureRect" parent="."] +material = SubResource("ShaderMaterial_ku7tv") +layout_mode = 1 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_top = -164.0 +grow_horizontal = 2 +grow_vertical = 0 +texture = SubResource("GradientTexture2D_bhdch") + +[node name="CoverHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = -3.0 +offset_top = 1.0 +offset_right = -3.0 +offset_bottom = 1.0 +grow_vertical = 0 + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectDirectory" type="Button" parent="."] +layout_mode = 0 +offset_left = 140.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "select the +directory" + +[node name="SelectPlaylist" type="Button" parent="."] +layout_mode = 0 +offset_left = 20.0 +offset_top = 24.0 +offset_right = 131.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "Playlists" + +[node name="PlaylistsContainer" type="ScrollContainer" parent="."] +layout_mode = 0 +offset_left = 3.0 +offset_top = 83.0 +offset_right = 352.0 +offset_bottom = 661.0 +follow_focus = true +horizontal_scroll_mode = 0 + +[node name="VBoxContainer" type="VBoxContainer" parent="PlaylistsContainer"] +layout_mode = 2 +size_flags_horizontal = 0 +size_flags_vertical = 4 +alignment = 1 + +[node name="Label" type="Label" parent="PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 0 +text = "PLAYLISTS" +label_settings = SubResource("LabelSettings_0fjy0") + +[node name="PlaylistsHolder" type="VBoxContainer" parent="PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_vertical = 4 +alignment = 1 + +[node name="RandomizeList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -254.0 +offset_top = 24.0 +offset_right = -86.0 +offset_bottom = 80.0 +grow_horizontal = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_axi6u") +text = "Randomize" + +[node name="SettingsButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -77.0 +offset_top = 23.0 +offset_right = -5.0 +offset_bottom = 95.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +shortcut = SubResource("Shortcut_8p5o4") +icon = ExtResource("11_esjel") +script = ExtResource("12_073mb") + +[node name="SettingsPopup" type="Popup" parent="."] +position = Vector2i(319, 85) +size = Vector2i(591, 501) + +[node name="SettingsMenuChild" parent="SettingsPopup" instance=ExtResource("13_7atry")] +offset_left = -272.0 +offset_top = 8.0 +offset_bottom = 458.0 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(576, 507) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] +bus = &"Music" + +[node name="playList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 20.0 +offset_top = -77.0 +offset_right = 92.0 +offset_bottom = -5.0 +grow_vertical = 0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="AddRemoveFromPlaylist" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 62.0 +offset_top = -77.0 +offset_right = 134.0 +offset_bottom = -5.0 +grow_vertical = 0 +scale = Vector2(0.5, 0.5) +icon = ExtResource("14_mioc4") + +[node name="CurrentProgress" type="HSlider" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 106.0 +offset_top = -88.0 +offset_right = -211.0 +offset_bottom = -24.0 +grow_horizontal = 2 +grow_vertical = 0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -105.0 +offset_top = -75.0 +offset_right = -65.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_qw6pv") +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -152.0 +offset_top = -75.0 +offset_right = -112.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vot6l") +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -157.0 +offset_top = -35.0 +offset_right = -117.0 +offset_bottom = 5.0 +grow_horizontal = 0 +grow_vertical = 0 +rotation = 3.14159 +focus_mode = 0 +shortcut = SubResource("Shortcut_xu6hm") +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -124.0 +offset_right = -158.0 +offset_bottom = -93.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="ArtistName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -103.0 +offset_right = -158.0 +offset_bottom = -72.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "if this text is visible the programmer is lazy" +label_settings = SubResource("LabelSettings_jg5vn") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchToggle" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -318.0 +offset_top = 24.0 +offset_right = -246.0 +offset_bottom = 96.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_g3fcr") +icon = ExtResource("12_cv2gm") +script = ExtResource("13_5illk") +PressedIcon = ExtResource("14_mioc4") +NotPressedIcon = ExtResource("12_cv2gm") + +[node name="SearchBar" type="LineEdit" parent="."] +visible = false +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +focus_mode = 1 +placeholder_text = "Search" +alignment = 1 +caret_blink = true +script = ExtResource("12_mr42x") + +[node name="SongsMenu" type="MenuButton" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +text = "Select Songs" +flat = false + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(623, 300) +wrap_controls = false +max_size = Vector2i(625, 300) +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -58.0 +offset_top = -75.0 +offset_right = -18.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -46.0 +offset_top = -83.0 +offset_right = -30.0 +offset_bottom = -75.0 +grow_horizontal = 0 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="TimeListeningSong" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -47.0 +offset_right = 221.0 +offset_bottom = -11.0 +grow_vertical = 0 + +[node name="DiscordMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 1042.0 +offset_top = 174.0 +offset_right = 1082.0 +offset_bottom = 214.0 + +[node name="YtTabButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -97.0 +offset_top = 109.0 +offset_right = 551.0 +offset_bottom = 560.0 +grow_horizontal = 0 +grow_vertical = 2 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -358.0 +offset_top = 107.0 +offset_right = -318.0 +offset_bottom = 147.0 +grow_horizontal = 0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -229.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_left = -29.0 +offset_top = 70.465 +offset_right = 58.0 +offset_bottom = 110.465 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(80, 90.165) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Label" type="Label" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 0 +offset_left = -27.795 +offset_top = 49.0 +offset_right = 197.205 +offset_bottom = 72.0 +text = "NOTE: speeds depend on your internet" +label_settings = SubResource("LabelSettings_fiiw4") + +[node name="Version" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -64.0 +offset_top = -23.0 +grow_horizontal = 0 +grow_vertical = 0 +text = "v1.1.0" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +initial_position = 4 +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="pressed" from="SettingsButton" to="SettingsButton" method="_on_pressed"] +[connection signal="toggled" from="SearchToggle" to="SearchToggle" method="_on_toggled"] +[connection signal="text_submitted" from="SearchBar" to="SearchBar" method="_on_text_submitted"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/Mai57B3.tmp b/Mai57B3.tmp new file mode 100644 index 0000000..a545687 --- /dev/null +++ b/Mai57B3.tmp @@ -0,0 +1,308 @@ +[gd_scene load_steps=26 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 2 +outline_color = Color(0, 0, 0, 1) +shadow_color = Color(0, 0, 0, 0.643137) +shadow_offset = Vector2(7.88, 4.31) + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="Sprite2D" parent="."] +position = Vector2(576.949, 401) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="Evening" type="Sprite2D" parent="."] +position = Vector2(582, 342) +scale = Vector2(1.00181, 1.00181) +texture = ExtResource("6_5vm0w") + +[node name="Nighttime" type="Sprite2D" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +position = Vector2(610, 326) +scale = Vector2(1.49056, 1.51111) +texture = ExtResource("6_8abnc") + +[node name="CoverHolder" type="Node2D" parent="."] +position = Vector2(-3, 649) + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +position = Vector2(200, -122.333) +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 20.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +text = "select the directory +(playlist's folder)" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 897.0 +offset_top = 24.0 +offset_right = 1132.0 +offset_bottom = 80.0 +focus_mode = 0 +text = "Randomize the Playlist" + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(470, 320) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] + +[node name="playList" type="Button" parent="."] +offset_left = 20.0 +offset_top = 572.0 +offset_right = 92.0 +offset_bottom = 644.0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 64.0 +offset_top = 560.0 +offset_right = 944.0 +offset_bottom = 624.0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="Skip2" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +offset_left = 1000.0 +offset_top = 573.0 +offset_right = 1040.0 +offset_bottom = 613.0 +focus_mode = 0 +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +offset_left = 994.0 +offset_top = 613.0 +offset_right = 1034.0 +offset_bottom = 653.0 +rotation = 3.14159 +focus_mode = 0 +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +offset_left = 66.0 +offset_top = 524.0 +offset_right = 994.0 +offset_bottom = 581.0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchBar" type="LineEdit" parent="."] +offset_left = 266.0 +offset_top = 24.0 +offset_right = 883.0 +offset_bottom = 83.0 +script = ExtResource("12_mr42x") + +[node name="SearchResults" type="PopupMenu" parent="."] +position = Vector2i(265, 80) +size = Vector2i(625, 300) +max_size = Vector2i(625, 300) +hide_on_state_item_selection = true +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +offset_left = 1092.0 +offset_top = 573.0 +offset_right = 1132.0 +offset_bottom = 613.0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_direction = 3 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1121.0 +offset_top = 563.0 +offset_right = -1103.0 +offset_bottom = 571.0 +grow_horizontal = 2 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="Logo" type="Sprite2D" parent="."] +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="TimeListeningSong" type="Label" parent="."] +offset_left = 66.0 +offset_top = 597.0 +offset_right = 178.0 +offset_bottom = 633.0 + +[node name="YtTabButton" type="Button" parent="."] +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = 1065.0 +offset_top = 107.0 +offset_right = 1713.0 +offset_bottom = 558.0 +grow_horizontal = 0 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 794.0 +offset_top = 107.0 +offset_right = 834.0 +offset_bottom = 147.0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -201.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_top = 58.0 +offset_right = 87.0 +offset_bottom = 98.0 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(113, 78) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Version" type="Label" parent="."] +offset_left = 1083.0 +offset_top = 625.0 +offset_right = 1147.0 +offset_bottom = 648.0 +text = "v0.9.2" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +position = Vector2i(495, 305) +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="text_changed" from="SearchBar" to="SearchBar" method="_on_text_changed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/Mai5C18.tmp b/Mai5C18.tmp new file mode 100644 index 0000000..af0377d --- /dev/null +++ b/Mai5C18.tmp @@ -0,0 +1,100 @@ +[gd_scene load_steps=5 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] + +[sub_resource type="LabelSettings" id="LabelSettings_4jg7r"] +font_size = 34 +outline_size = 2 +outline_color = Color(0, 0, 0, 1) +shadow_size = 2 + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") + +[node name="D7Hftxdivxxvm_cloudfront" type="Sprite2D" parent="."] +position = Vector2(576.949, 299) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 43.0 +offset_top = 24.0 +offset_right = 278.0 +offset_bottom = 65.0 +text = "select playlist folder" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 767.0 +offset_top = 29.0 +offset_right = 1002.0 +offset_bottom = 70.0 +text = "Randomize Playlist" + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(325, 115) +size = Vector2i(427, 320) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] + +[node name="playList" type="Button" parent="."] +offset_left = 187.0 +offset_top = 572.0 +offset_right = 274.0 +offset_bottom = 612.0 +text = "play" + +[node name="pause" type="Button" parent="."] +offset_left = 88.0 +offset_top = 572.0 +offset_right = 175.0 +offset_bottom = 612.0 +text = "toggle +pause" + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 286.0 +offset_top = 560.0 +offset_right = 895.0 +offset_bottom = 624.0 +ticks_on_borders = true + +[node name="VolumeSlider" type="VSlider" parent="."] +offset_left = 1125.0 +offset_top = 333.0 +offset_right = 1141.0 +offset_bottom = 623.0 +value = 100.0 + +[node name="Label" type="Label" parent="."] +offset_left = 1094.0 +offset_top = 331.0 +offset_right = 1121.0 +offset_bottom = 611.0 +text = "V +O +L +U +M +E" +label_settings = SubResource("LabelSettings_4jg7r") + +[node name="Skip" type="Button" parent="."] +offset_left = 956.0 +offset_top = 572.0 +offset_right = 996.0 +offset_bottom = 612.0 +icon = ExtResource("3_4vx67") + +[node name="GoBack" type="Button" parent="."] +offset_left = 942.0 +offset_top = 612.0 +offset_right = 982.0 +offset_bottom = 652.0 +rotation = 3.14159 +icon = ExtResource("3_4vx67") diff --git a/MaiC00.tmp b/MaiC00.tmp new file mode 100644 index 0000000..b843585 --- /dev/null +++ b/MaiC00.tmp @@ -0,0 +1,24 @@ +[gd_scene load_steps=2 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 43.0 +offset_top = 24.0 +offset_right = 278.0 +offset_bottom = 65.0 +text = "select playlist folder" + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(140, 225) +size = Vector2i(352, 180) +visible = true +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] diff --git a/MaiD836.tmp b/MaiD836.tmp new file mode 100644 index 0000000..3169b32 --- /dev/null +++ b/MaiD836.tmp @@ -0,0 +1,185 @@ +[gd_scene load_steps=14 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://itxrsfeiey6k" path="res://unnamed.jpg" id="5_o3jj7"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="AudioStream" uid="uid://cvndnnx1mdvqp" path="res://Project_4.mp3" id="7_8fltb"] +[ext_resource type="Texture2D" uid="uid://b5ml1dkiuo5ta" path="res://Logo.png" id="11_boad2"] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 2 +outline_color = Color(0, 0, 0, 1) +shadow_color = Color(0, 0, 0, 0.643137) +shadow_offset = Vector2(7.88, 4.31) + +[sub_resource type="LabelSettings" id="LabelSettings_ywsb0"] +font_size = 36 +outline_size = 2 +outline_color = Color(0, 0, 0, 1) +shadow_size = 2 +shadow_color = Color(0, 0, 0, 0.486275) +shadow_offset = Vector2(6.725, 10.16) + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="Sprite2D" parent="."] +position = Vector2(576.949, 299) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="Evening" type="Sprite2D" parent="."] +position = Vector2(575, 350) +scale = Vector2(2.27353, 2.27353) +texture = ExtResource("5_o3jj7") + +[node name="Nighttime" type="Sprite2D" parent="."] +modulate = Color(0.347817, 0.347817, 0.347817, 1) +position = Vector2(599, 323) +scale = Vector2(1.47, 1.47) +texture = ExtResource("6_8abnc") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 20.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +text = "select the directory +(playlist's folder)" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 897.0 +offset_top = 24.0 +offset_right = 1132.0 +offset_bottom = 80.0 +text = "Randomize the Playlist" + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(470, 320) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] + +[node name="playList" type="Button" parent="."] +offset_left = 12.0 +offset_top = 572.0 +offset_right = 99.0 +offset_bottom = 612.0 +text = "play" + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 107.0 +offset_top = 560.0 +offset_right = 994.0 +offset_bottom = 624.0 +max_value = 1000.0 +editable = false +scrollable = false +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +offset_left = 1092.0 +offset_top = 573.0 +offset_right = 1132.0 +offset_bottom = 613.0 +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +offset_left = 1040.0 +offset_top = 613.0 +offset_right = 1080.0 +offset_bottom = 653.0 +rotation = 3.14159 +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +offset_left = 107.0 +offset_top = 516.0 +offset_right = 993.0 +offset_bottom = 573.0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="Song list" type="MenuButton" parent="."] +offset_left = 265.0 +offset_top = 24.0 +offset_right = 888.0 +offset_bottom = 80.0 +text = "Select a Song" +flat = false +switch_on_hover = true + +[node name="Sprite2D" type="Sprite2D" parent="."] +position = Vector2(1090, 253) +scale = Vector2(1.875, 1.875) +texture = ExtResource("6_3mi6c") + +[node name="Label" type="Label" parent="."] +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 1079.0 +offset_top = 248.0 +offset_right = 1119.0 +offset_bottom = 563.0 +grow_horizontal = 0 +grow_vertical = 0 +text = "V +O +L +U +M +E" +label_settings = SubResource("LabelSettings_ywsb0") + +[node name="VolumeSlider" type="VSlider" parent="."] +offset_left = 1114.0 +offset_top = 250.0 +offset_right = 1130.0 +offset_bottom = 572.0 +value = 100.0 + +[node name="Intro" type="AudioStreamPlayer" parent="."] +stream = ExtResource("7_8fltb") +autoplay = true + +[node name="Logo" type="Sprite2D" parent="."] +modulate = Color(1, 1, 1, 0.423529) +position = Vector2(277, 209) +texture = ExtResource("11_boad2") + +[node name="TimeListeningSong" type="Label" parent="."] +offset_left = 112.0 +offset_top = 603.0 +offset_right = 224.0 +offset_bottom = 639.0 diff --git a/MaiE09B.tmp b/MaiE09B.tmp new file mode 100644 index 0000000..25e8617 --- /dev/null +++ b/MaiE09B.tmp @@ -0,0 +1,665 @@ +[gd_scene load_steps=53 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Shader" path="res://Main.gdshader" id="10_20857"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Texture2D" uid="uid://0r1tx6l1lc6x" path="res://settingscog.png" id="11_esjel"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Script" path="res://settings_button.gd" id="12_073mb"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Texture2D" uid="uid://myq6n4bshduj" path="res://search.png" id="12_cv2gm"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Script" path="res://search_toggle.gd" id="13_5illk"] +[ext_resource type="PackedScene" uid="uid://dqg674t6kun4e" path="res://Settings.tscn" id="13_7atry"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="14_mioc4"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ku7tv"] +shader = ExtResource("10_20857") +shader_parameter/intensity = 1.0 + +[sub_resource type="Gradient" id="Gradient_7vgyc"] +offsets = PackedFloat32Array(0.00292398, 0.845029) +colors = PackedColorArray(0, 0, 0, 0, 1, 1, 1, 1) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_bhdch"] +gradient = SubResource("Gradient_7vgyc") +fill_to = Vector2(0, 1) + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_x0ps1"] +device = -1 +ctrl_pressed = true +keycode = 68 + +[sub_resource type="Shortcut" id="Shortcut_vp2fh"] +events = [SubResource("InputEventKey_x0ps1")] + +[sub_resource type="LabelSettings" id="LabelSettings_0fjy0"] +font_size = 21 + +[sub_resource type="InputEventKey" id="InputEventKey_0jlka"] +device = -1 +ctrl_pressed = true +keycode = 82 + +[sub_resource type="Shortcut" id="Shortcut_axi6u"] +events = [SubResource("InputEventKey_0jlka")] + +[sub_resource type="InputEventKey" id="InputEventKey_117g0"] +device = -1 +ctrl_pressed = true +keycode = 83 + +[sub_resource type="Shortcut" id="Shortcut_8p5o4"] +events = [SubResource("InputEventKey_117g0")] + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="InputEventKey" id="InputEventKey_l1ahe"] +device = -1 +keycode = 4194321 + +[sub_resource type="Shortcut" id="Shortcut_qw6pv"] +events = [SubResource("InputEventKey_l1ahe")] + +[sub_resource type="InputEventKey" id="InputEventKey_c5qef"] +device = -1 +keycode = 76 +unicode = 108 + +[sub_resource type="Shortcut" id="Shortcut_vot6l"] +events = [SubResource("InputEventKey_c5qef")] + +[sub_resource type="InputEventKey" id="InputEventKey_y4cc2"] +device = -1 +keycode = 4194319 + +[sub_resource type="Shortcut" id="Shortcut_xu6hm"] +events = [SubResource("InputEventKey_y4cc2")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 3 +outline_color = Color(0.215902, 0.215902, 0.215902, 1) + +[sub_resource type="LabelSettings" id="LabelSettings_jg5vn"] +font_size = 20 +outline_size = 3 +outline_color = Color(0.393086, 0.393086, 0.393085, 1) + +[sub_resource type="InputEventKey" id="InputEventKey_puhgg"] +device = -1 +ctrl_pressed = true +keycode = 81 + +[sub_resource type="Shortcut" id="Shortcut_g3fcr"] +events = [SubResource("InputEventKey_puhgg")] + +[sub_resource type="LabelSettings" id="LabelSettings_fiiw4"] +font_size = 12 + +[node name="Node2D" type="Control"] +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("2_wf35v") +stretch_mode = 6 + +[node name="Evening" type="TextureRect" parent="."] +visible = false +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_5vm0w") +stretch_mode = 6 + +[node name="Nighttime" type="TextureRect" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_8abnc") +stretch_mode = 6 + +[node name="UserBG" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +expand_mode = 5 +stretch_mode = 6 + +[node name="Logo" type="Sprite2D" parent="."] +visible = false +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="PausedIndicator" type="TextureRect" parent="."] +material = SubResource("ShaderMaterial_ku7tv") +layout_mode = 1 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_top = -164.0 +grow_horizontal = 2 +grow_vertical = 0 +texture = SubResource("GradientTexture2D_bhdch") + +[node name="CoverHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = -3.0 +offset_top = 1.0 +offset_right = -3.0 +offset_bottom = 1.0 +grow_vertical = 0 + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectDirectory" type="Button" parent="."] +layout_mode = 0 +offset_left = 140.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "select the +directory" + +[node name="SelectPlaylist" type="Button" parent="."] +layout_mode = 0 +offset_left = 20.0 +offset_top = 24.0 +offset_right = 131.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "Playlists" + +[node name="PlaylistsContainer" type="ScrollContainer" parent="."] +layout_mode = 0 +offset_left = 3.0 +offset_top = 83.0 +offset_right = 261.0 +offset_bottom = 524.0 + +[node name="VBoxContainer" type="VBoxContainer" parent="PlaylistsContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +alignment = 1 + +[node name="Label" type="Label" parent="PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +text = "PLAYLISTS" +label_settings = SubResource("LabelSettings_0fjy0") + +[node name="PlaylistsHolder" type="VBoxContainer" parent="PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +alignment = 1 + +[node name="RandomizeList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -254.0 +offset_top = 24.0 +offset_right = -86.0 +offset_bottom = 80.0 +grow_horizontal = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_axi6u") +text = "Randomize" + +[node name="SettingsButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -77.0 +offset_top = 23.0 +offset_right = -5.0 +offset_bottom = 95.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +shortcut = SubResource("Shortcut_8p5o4") +icon = ExtResource("11_esjel") +script = ExtResource("12_073mb") + +[node name="SettingsPopup" type="Popup" parent="."] +position = Vector2i(259, 85) +size = Vector2i(576, 493) + +[node name="SettingsMenuChild" parent="SettingsPopup" instance=ExtResource("13_7atry")] +offset_left = -272.0 +offset_top = 8.0 +offset_bottom = 458.0 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(576, 507) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] +bus = &"Music" + +[node name="playList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 20.0 +offset_top = -77.0 +offset_right = 92.0 +offset_bottom = -5.0 +grow_vertical = 0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="AddRemoveFromPlaylist" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 62.0 +offset_top = -77.0 +offset_right = 134.0 +offset_bottom = -5.0 +grow_vertical = 0 +scale = Vector2(0.5, 0.5) +icon = ExtResource("14_mioc4") + +[node name="CurrentProgress" type="HSlider" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 106.0 +offset_top = -88.0 +offset_right = -211.0 +offset_bottom = -24.0 +grow_horizontal = 2 +grow_vertical = 0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -105.0 +offset_top = -75.0 +offset_right = -65.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_qw6pv") +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -152.0 +offset_top = -75.0 +offset_right = -112.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vot6l") +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -157.0 +offset_top = -35.0 +offset_right = -117.0 +offset_bottom = 5.0 +grow_horizontal = 0 +grow_vertical = 0 +rotation = 3.14159 +focus_mode = 0 +shortcut = SubResource("Shortcut_xu6hm") +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -124.0 +offset_right = -158.0 +offset_bottom = -93.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="ArtistName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -103.0 +offset_right = -158.0 +offset_bottom = -72.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "John doe" +label_settings = SubResource("LabelSettings_jg5vn") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchToggle" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -318.0 +offset_top = 24.0 +offset_right = -246.0 +offset_bottom = 96.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_g3fcr") +icon = ExtResource("12_cv2gm") +script = ExtResource("13_5illk") +PressedIcon = ExtResource("14_mioc4") +NotPressedIcon = ExtResource("12_cv2gm") + +[node name="SearchBar" type="LineEdit" parent="."] +visible = false +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +focus_mode = 1 +placeholder_text = "Search" +alignment = 1 +caret_blink = true +script = ExtResource("12_mr42x") + +[node name="SongsMenu" type="MenuButton" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +text = "Select Songs" +flat = false + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(623, 300) +wrap_controls = false +max_size = Vector2i(625, 300) +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -58.0 +offset_top = -75.0 +offset_right = -18.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -46.0 +offset_top = -83.0 +offset_right = -30.0 +offset_bottom = -75.0 +grow_horizontal = 0 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="TimeListeningSong" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 109.0 +offset_top = -47.0 +offset_right = 221.0 +offset_bottom = -11.0 +grow_vertical = 0 + +[node name="DiscordMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 1042.0 +offset_top = 174.0 +offset_right = 1082.0 +offset_bottom = 214.0 + +[node name="YtTabButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -97.0 +offset_top = 109.0 +offset_right = 551.0 +offset_bottom = 560.0 +grow_horizontal = 0 +grow_vertical = 2 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -358.0 +offset_top = 107.0 +offset_right = -318.0 +offset_bottom = 147.0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -229.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_left = -29.0 +offset_top = 70.465 +offset_right = 58.0 +offset_bottom = 110.465 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(80, 90.165) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Label" type="Label" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 0 +offset_left = -27.795 +offset_top = 49.0 +offset_right = 197.205 +offset_bottom = 72.0 +text = "NOTE: speeds depend on your internet" +label_settings = SubResource("LabelSettings_fiiw4") + +[node name="Version" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -64.0 +offset_top = -23.0 +grow_horizontal = 0 +grow_vertical = 0 +text = "v1.1.0" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +initial_position = 4 +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="pressed" from="SettingsButton" to="SettingsButton" method="_on_pressed"] +[connection signal="toggled" from="SearchToggle" to="SearchToggle" method="_on_toggled"] +[connection signal="text_submitted" from="SearchBar" to="SearchBar" method="_on_text_submitted"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/MaiE368.tmp b/MaiE368.tmp new file mode 100644 index 0000000..99dbae4 --- /dev/null +++ b/MaiE368.tmp @@ -0,0 +1,474 @@ +[gd_scene load_steps=52 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Shader" path="res://Main.gdshader" id="10_20857"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Texture2D" uid="uid://0r1tx6l1lc6x" path="res://settingscog.png" id="11_esjel"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Script" path="res://settings_button.gd" id="12_073mb"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Texture2D" uid="uid://myq6n4bshduj" path="res://search.png" id="12_cv2gm"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Script" path="res://search_toggle.gd" id="13_5illk"] +[ext_resource type="PackedScene" uid="uid://dqg674t6kun4e" path="res://Settings.tscn" id="13_7atry"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="14_mioc4"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ku7tv"] +shader = ExtResource("10_20857") +shader_parameter/intensity = 1.0 + +[sub_resource type="Gradient" id="Gradient_7vgyc"] +offsets = PackedFloat32Array(0.00292398, 0.845029) +colors = PackedColorArray(0, 0, 0, 0, 1, 1, 1, 1) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_bhdch"] +gradient = SubResource("Gradient_7vgyc") +fill_to = Vector2(0, 1) + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_x0ps1"] +device = -1 +ctrl_pressed = true +keycode = 68 + +[sub_resource type="Shortcut" id="Shortcut_vp2fh"] +events = [SubResource("InputEventKey_x0ps1")] + +[sub_resource type="InputEventKey" id="InputEventKey_0jlka"] +device = -1 +ctrl_pressed = true +keycode = 82 + +[sub_resource type="Shortcut" id="Shortcut_axi6u"] +events = [SubResource("InputEventKey_0jlka")] + +[sub_resource type="InputEventKey" id="InputEventKey_117g0"] +device = -1 +ctrl_pressed = true +keycode = 83 + +[sub_resource type="Shortcut" id="Shortcut_8p5o4"] +events = [SubResource("InputEventKey_117g0")] + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="InputEventKey" id="InputEventKey_l1ahe"] +device = -1 +keycode = 4194321 + +[sub_resource type="Shortcut" id="Shortcut_qw6pv"] +events = [SubResource("InputEventKey_l1ahe")] + +[sub_resource type="InputEventKey" id="InputEventKey_c5qef"] +device = -1 +keycode = 76 +unicode = 108 + +[sub_resource type="Shortcut" id="Shortcut_vot6l"] +events = [SubResource("InputEventKey_c5qef")] + +[sub_resource type="InputEventKey" id="InputEventKey_y4cc2"] +device = -1 +keycode = 4194319 + +[sub_resource type="Shortcut" id="Shortcut_xu6hm"] +events = [SubResource("InputEventKey_y4cc2")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 3 +outline_color = Color(0.215902, 0.215902, 0.215902, 1) + +[sub_resource type="LabelSettings" id="LabelSettings_jg5vn"] +font_size = 20 +outline_size = 3 +outline_color = Color(0.393086, 0.393086, 0.393085, 1) + +[sub_resource type="InputEventKey" id="InputEventKey_puhgg"] +device = -1 +ctrl_pressed = true +keycode = 81 + +[sub_resource type="Shortcut" id="Shortcut_g3fcr"] +events = [SubResource("InputEventKey_puhgg")] + +[sub_resource type="LabelSettings" id="LabelSettings_fiiw4"] +font_size = 12 + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="Sprite2D" parent="."] +position = Vector2(576.949, 401) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="Evening" type="Sprite2D" parent="."] +visible = false +position = Vector2(582, 342) +scale = Vector2(1.00181, 1.00181) +texture = ExtResource("6_5vm0w") + +[node name="Nighttime" type="Sprite2D" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +position = Vector2(610, 326) +scale = Vector2(1.49056, 1.51111) +texture = ExtResource("6_8abnc") + +[node name="PausedIndicator" type="TextureRect" parent="."] +material = SubResource("ShaderMaterial_ku7tv") +offset_left = -10.0 +offset_top = 468.0 +offset_right = 1161.0 +offset_bottom = 657.0 +texture = SubResource("GradientTexture2D_bhdch") + +[node name="CoverHolder" type="Node2D" parent="."] +position = Vector2(-3, 649) + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +position = Vector2(200, -122.333) +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 20.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "select the directory +(playlist's folder)" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 897.0 +offset_top = 24.0 +offset_right = 1065.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_axi6u") +text = "Randomize" + +[node name="SettingsButton" type="Button" parent="."] +offset_left = 1073.0 +offset_top = 24.0 +offset_right = 1145.0 +offset_bottom = 96.0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +shortcut = SubResource("Shortcut_8p5o4") +icon = ExtResource("11_esjel") +script = ExtResource("12_073mb") + +[node name="SettingsPopup" type="Popup" parent="."] +position = Vector2i(259, 85) +size = Vector2i(576, 493) + +[node name="SettingsMenuChild" parent="SettingsPopup" instance=ExtResource("13_7atry")] +offset_left = -272.0 +offset_top = 8.0 +offset_right = 288.0 +offset_bottom = 458.0 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(576, 507) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] +bus = &"Music" + +[node name="playList" type="Button" parent="."] +offset_left = 20.0 +offset_top = 572.0 +offset_right = 92.0 +offset_bottom = 644.0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 64.0 +offset_top = 560.0 +offset_right = 944.0 +offset_bottom = 624.0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_qw6pv") +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +offset_left = 1000.0 +offset_top = 573.0 +offset_right = 1040.0 +offset_bottom = 613.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vot6l") +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +offset_left = 994.0 +offset_top = 613.0 +offset_right = 1034.0 +offset_bottom = 653.0 +rotation = 3.14159 +focus_mode = 0 +shortcut = SubResource("Shortcut_xu6hm") +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +offset_left = 66.0 +offset_top = 524.0 +offset_right = 994.0 +offset_bottom = 555.0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="ArtistName" type="Label" parent="."] +offset_left = 67.0 +offset_top = 547.0 +offset_right = 995.0 +offset_bottom = 578.0 +text = "John doe" +label_settings = SubResource("LabelSettings_jg5vn") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchToggle" type="Button" parent="."] +offset_left = 833.0 +offset_top = 24.0 +offset_right = 905.0 +offset_bottom = 96.0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_g3fcr") +icon = ExtResource("12_cv2gm") +script = ExtResource("13_5illk") +PressedIcon = ExtResource("14_mioc4") +NotPressedIcon = ExtResource("12_cv2gm") + +[node name="SearchBar" type="LineEdit" parent="."] +visible = false +offset_left = 265.0 +offset_top = 24.0 +offset_right = 825.0 +offset_bottom = 80.0 +focus_mode = 1 +placeholder_text = "Search" +alignment = 1 +caret_blink = true +script = ExtResource("12_mr42x") + +[node name="SongsMenu" type="MenuButton" parent="."] +offset_left = 265.0 +offset_top = 24.0 +offset_right = 825.0 +offset_bottom = 80.0 +text = "Select Songs" +flat = false + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(623, 300) +wrap_controls = false +max_size = Vector2i(625, 300) +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +offset_left = 1092.0 +offset_top = 573.0 +offset_right = 1132.0 +offset_bottom = 613.0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_direction = 3 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1121.0 +offset_top = 563.0 +offset_right = -1103.0 +offset_bottom = 571.0 +grow_horizontal = 2 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="Logo" type="Sprite2D" parent="."] +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="TimeListeningSong" type="Label" parent="."] +offset_left = 66.0 +offset_top = 597.0 +offset_right = 178.0 +offset_bottom = 633.0 + +[node name="DiscordMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 1042.0 +offset_top = 174.0 +offset_right = 1082.0 +offset_bottom = 214.0 + +[node name="YtTabButton" type="Button" parent="."] +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = 1065.0 +offset_top = 107.0 +offset_right = 1713.0 +offset_bottom = 558.0 +grow_horizontal = 0 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 794.0 +offset_top = 107.0 +offset_right = 834.0 +offset_bottom = 147.0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -229.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_left = -29.0 +offset_top = 70.465 +offset_right = 58.0 +offset_bottom = 110.465 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(80, 90.165) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Label" type="Label" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 0 +offset_left = -27.795 +offset_top = 49.0 +offset_right = 197.205 +offset_bottom = 72.0 +text = "NOTE: speeds depend on your internet" +label_settings = SubResource("LabelSettings_fiiw4") + +[node name="Version" type="Label" parent="."] +offset_left = 1083.0 +offset_top = 625.0 +offset_right = 1147.0 +offset_bottom = 648.0 +text = "v1.0.3" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +initial_position = 4 +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="pressed" from="SettingsButton" to="SettingsButton" method="_on_pressed"] +[connection signal="toggled" from="SearchToggle" to="SearchToggle" method="_on_toggled"] +[connection signal="text_submitted" from="SearchBar" to="SearchBar" method="_on_text_submitted"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/MaiEDBE.tmp b/MaiEDBE.tmp new file mode 100644 index 0000000..03e364b --- /dev/null +++ b/MaiEDBE.tmp @@ -0,0 +1,448 @@ +[gd_scene load_steps=50 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Shader" path="res://Main.gdshader" id="10_20857"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Texture2D" uid="uid://0r1tx6l1lc6x" path="res://settingscog.png" id="11_esjel"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Script" path="res://settings_button.gd" id="12_073mb"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Texture2D" uid="uid://myq6n4bshduj" path="res://search.png" id="12_cv2gm"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Script" path="res://search_toggle.gd" id="13_5illk"] +[ext_resource type="PackedScene" uid="uid://dqg674t6kun4e" path="res://Settings.tscn" id="13_7atry"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="14_mioc4"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ku7tv"] +shader = ExtResource("10_20857") +shader_parameter/intensity = 1.0 + +[sub_resource type="Gradient" id="Gradient_7vgyc"] +offsets = PackedFloat32Array(0.00292398, 0.845029) +colors = PackedColorArray(0, 0, 0, 0, 1, 1, 1, 1) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_bhdch"] +gradient = SubResource("Gradient_7vgyc") +fill_to = Vector2(0, 1) + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_x0ps1"] +device = -1 +ctrl_pressed = true +keycode = 68 + +[sub_resource type="Shortcut" id="Shortcut_vp2fh"] +events = [SubResource("InputEventKey_x0ps1")] + +[sub_resource type="InputEventKey" id="InputEventKey_0jlka"] +device = -1 +ctrl_pressed = true +keycode = 82 + +[sub_resource type="Shortcut" id="Shortcut_axi6u"] +events = [SubResource("InputEventKey_0jlka")] + +[sub_resource type="InputEventKey" id="InputEventKey_117g0"] +device = -1 +ctrl_pressed = true +keycode = 83 + +[sub_resource type="Shortcut" id="Shortcut_8p5o4"] +events = [SubResource("InputEventKey_117g0")] + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="InputEventKey" id="InputEventKey_l1ahe"] +device = -1 +keycode = 4194321 + +[sub_resource type="Shortcut" id="Shortcut_qw6pv"] +events = [SubResource("InputEventKey_l1ahe")] + +[sub_resource type="InputEventKey" id="InputEventKey_c5qef"] +device = -1 +keycode = 76 +unicode = 108 + +[sub_resource type="Shortcut" id="Shortcut_vot6l"] +events = [SubResource("InputEventKey_c5qef")] + +[sub_resource type="InputEventKey" id="InputEventKey_y4cc2"] +device = -1 +keycode = 4194319 + +[sub_resource type="Shortcut" id="Shortcut_xu6hm"] +events = [SubResource("InputEventKey_y4cc2")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 3 +outline_color = Color(0.215902, 0.215902, 0.215902, 1) + +[sub_resource type="InputEventKey" id="InputEventKey_puhgg"] +device = -1 +ctrl_pressed = true +keycode = 81 + +[sub_resource type="Shortcut" id="Shortcut_g3fcr"] +events = [SubResource("InputEventKey_puhgg")] + +[node name="Node2D" type="Node2D"] +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="Sprite2D" parent="."] +position = Vector2(576.949, 401) +scale = Vector2(1.27923, 1.25956) +texture = ExtResource("2_wf35v") + +[node name="Evening" type="Sprite2D" parent="."] +visible = false +position = Vector2(582, 342) +scale = Vector2(1.00181, 1.00181) +texture = ExtResource("6_5vm0w") + +[node name="Nighttime" type="Sprite2D" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +position = Vector2(610, 326) +scale = Vector2(1.49056, 1.51111) +texture = ExtResource("6_8abnc") + +[node name="PausedIndicator" type="TextureRect" parent="."] +material = SubResource("ShaderMaterial_ku7tv") +offset_left = -10.0 +offset_top = 468.0 +offset_right = 1161.0 +offset_bottom = 657.0 +texture = SubResource("GradientTexture2D_bhdch") + +[node name="CoverHolder" type="Node2D" parent="."] +position = Vector2(-3, 649) + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +position = Vector2(200, -122.333) +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectPlaylist" type="Button" parent="."] +offset_left = 20.0 +offset_top = 24.0 +offset_right = 255.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vp2fh") +text = "select the directory +(playlist's folder)" + +[node name="RandomizeList" type="Button" parent="."] +offset_left = 897.0 +offset_top = 24.0 +offset_right = 1065.0 +offset_bottom = 80.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_axi6u") +text = "Randomize" + +[node name="SettingsButton" type="Button" parent="."] +offset_left = 1073.0 +offset_top = 24.0 +offset_right = 1145.0 +offset_bottom = 96.0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +shortcut = SubResource("Shortcut_8p5o4") +icon = ExtResource("11_esjel") +script = ExtResource("12_073mb") + +[node name="SettingsPopup" type="Popup" parent="."] +position = Vector2i(265, 110) +size = Vector2i(575, 458) +visible = true + +[node name="SettingsMenuChild" parent="SettingsPopup" instance=ExtResource("13_7atry")] +offset_left = -272.0 +offset_top = 8.0 +offset_right = 288.0 +offset_bottom = 458.0 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(576, 507) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] +bus = &"Music" + +[node name="playList" type="Button" parent="."] +offset_left = 20.0 +offset_top = 572.0 +offset_right = 92.0 +offset_bottom = 644.0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="CurrentProgress" type="HSlider" parent="."] +offset_left = 64.0 +offset_top = 560.0 +offset_right = 944.0 +offset_bottom = 624.0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +offset_left = 1046.0 +offset_top = 573.0 +offset_right = 1086.0 +offset_bottom = 613.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_qw6pv") +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +offset_left = 1000.0 +offset_top = 573.0 +offset_right = 1040.0 +offset_bottom = 613.0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vot6l") +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +offset_left = 994.0 +offset_top = 613.0 +offset_right = 1034.0 +offset_bottom = 653.0 +rotation = 3.14159 +focus_mode = 0 +shortcut = SubResource("Shortcut_xu6hm") +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +offset_left = 66.0 +offset_top = 524.0 +offset_right = 994.0 +offset_bottom = 581.0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchToggle" type="Button" parent="."] +offset_left = 833.0 +offset_top = 24.0 +offset_right = 905.0 +offset_bottom = 96.0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_g3fcr") +icon = ExtResource("12_cv2gm") +script = ExtResource("13_5illk") +PressedIcon = ExtResource("14_mioc4") +NotPressedIcon = ExtResource("12_cv2gm") + +[node name="SearchBar" type="LineEdit" parent="."] +visible = false +offset_left = 265.0 +offset_top = 24.0 +offset_right = 825.0 +offset_bottom = 80.0 +focus_mode = 1 +placeholder_text = "Search" +alignment = 1 +caret_blink = true +script = ExtResource("12_mr42x") + +[node name="SongsMenu" type="MenuButton" parent="."] +offset_left = 265.0 +offset_top = 24.0 +offset_right = 825.0 +offset_bottom = 80.0 +text = "Select Songs" +flat = false + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(623, 300) +wrap_controls = false +max_size = Vector2i(625, 300) +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +offset_left = 1092.0 +offset_top = 573.0 +offset_right = 1132.0 +offset_bottom = 613.0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_direction = 3 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -1121.0 +offset_top = 563.0 +offset_right = -1103.0 +offset_bottom = 571.0 +grow_horizontal = 2 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="Logo" type="Sprite2D" parent="."] +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="TimeListeningSong" type="Label" parent="."] +offset_left = 66.0 +offset_top = 597.0 +offset_right = 178.0 +offset_bottom = 633.0 + +[node name="DiscordMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 1042.0 +offset_top = 174.0 +offset_right = 1082.0 +offset_bottom = 214.0 + +[node name="YtTabButton" type="Button" parent="."] +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = 1065.0 +offset_top = 107.0 +offset_right = 1713.0 +offset_bottom = 558.0 +grow_horizontal = 0 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 794.0 +offset_top = 107.0 +offset_right = 834.0 +offset_bottom = 147.0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 3 +anchors_preset = 0 +offset_right = 200.0 +offset_bottom = 363.0 + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -229.0 +offset_bottom = 47.0 +grow_horizontal = 0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_left = -29.0 +offset_top = 58.0 +offset_right = 58.0 +offset_bottom = 98.0 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(80, 78) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Version" type="Label" parent="."] +offset_left = 1083.0 +offset_top = 625.0 +offset_right = 1147.0 +offset_bottom = 648.0 +text = "v1.0.1" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +initial_position = 4 +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="pressed" from="SettingsButton" to="SettingsButton" method="_on_pressed"] +[connection signal="toggled" from="SearchToggle" to="SearchToggle" method="_on_toggled"] +[connection signal="text_submitted" from="SearchBar" to="SearchBar" method="_on_text_submitted"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/Main.gdshader b/Main.gdshader new file mode 100644 index 0000000..97782dd --- /dev/null +++ b/Main.gdshader @@ -0,0 +1,20 @@ +shader_type canvas_item; + +uniform float intensity; +uniform sampler2D screen_texture : hint_screen_texture, repeat_disable, filter_nearest; + +void vertex() { + // Called for every vertex the material is visible on. +} + +void fragment() { + vec4 as = texture(screen_texture,SCREEN_UV); + vec4 a2s = texture(TEXTURE,UV); + vec4 fart = a2s * (0.1 + as.bgra); + COLOR = fart * intensity; +} + +//void light() { + // Called for every pixel for every light affecting the CanvasItem. + // Uncomment to replace the default light processing function with this one. +//} diff --git a/Main.tscn b/Main.tscn new file mode 100644 index 0000000..d356ae7 --- /dev/null +++ b/Main.tscn @@ -0,0 +1,846 @@ +[gd_scene load_steps=59 format=3 uid="uid://b2sygl55s6fng"] + +[ext_resource type="Script" path="res://main.gd" id="1_ubs1p"] +[ext_resource type="Texture2D" uid="uid://b8on1case224h" path="res://LoopPressed.png" id="2_iolk5"] +[ext_resource type="Texture2D" uid="uid://cq8jj63iyu2cs" path="res://d7hftxdivxxvm.cloudfront.webp" id="2_wf35v"] +[ext_resource type="Texture2D" uid="uid://daq8wnhtscpjl" path="res://Skip.png" id="3_4vx67"] +[ext_resource type="Script" path="res://wallpaper_manager.gd" id="4_y372l"] +[ext_resource type="Texture2D" uid="uid://38c8dfym0svn" path="res://Loop.png" id="5_c2g63"] +[ext_resource type="Texture2D" uid="uid://cekkhyppj88xi" path="res://Headphones.png" id="6_3mi6c"] +[ext_resource type="Texture2D" uid="uid://snne8iiftksi" path="res://Evening_view_of_Munnar_1633.jpg" id="6_5vm0w"] +[ext_resource type="Texture2D" uid="uid://ba5wdmchyy50n" path="res://nighttime-in-the-hills-henry-porter.jpg" id="6_8abnc"] +[ext_resource type="Texture2D" uid="uid://ctb4s2nks73rx" path="res://Play.png" id="8_5v7u3"] +[ext_resource type="Shader" path="res://CoverShader.gdshader" id="8_4531v"] +[ext_resource type="Shader" path="res://Main.gdshader" id="10_20857"] +[ext_resource type="Texture2D" uid="uid://b00wlqid2jdvi" path="res://BigLogo.png" id="10_xnj6a"] +[ext_resource type="Texture2D" uid="uid://0r1tx6l1lc6x" path="res://settingscog.png" id="11_esjel"] +[ext_resource type="Script" path="res://cover.gd" id="12_3v50a"] +[ext_resource type="Script" path="res://playlists_panel.gd" id="12_8ie8y"] +[ext_resource type="Script" path="res://settings_button.gd" id="12_073mb"] +[ext_resource type="Texture2D" uid="uid://bdpat2sfflaxq" path="res://Youtube_logo.png" id="12_bc5ym"] +[ext_resource type="Texture2D" uid="uid://myq6n4bshduj" path="res://search.png" id="12_cv2gm"] +[ext_resource type="Script" path="res://search_bar.gd" id="12_mr42x"] +[ext_resource type="Script" path="res://select_playlist.gd" id="12_of5fe"] +[ext_resource type="Script" path="res://search_toggle.gd" id="13_5illk"] +[ext_resource type="PackedScene" uid="uid://dqg674t6kun4e" path="res://Settings.tscn" id="13_7atry"] +[ext_resource type="Script" path="res://create_playlists_menu.gd" id="13_asgvh"] +[ext_resource type="Texture2D" uid="uid://b5eims5ucn81r" path="res://Loding.png" id="13_de5ej"] +[ext_resource type="Script" path="res://volume_button.gd" id="14_7q3ja"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="14_mioc4"] +[ext_resource type="Script" path="res://Spinning.gd" id="14_rhw4k"] +[ext_resource type="Script" path="res://yt_tab_button.gd" id="16_2t15p"] + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ku7tv"] +shader = ExtResource("10_20857") +shader_parameter/intensity = 1.0 + +[sub_resource type="Gradient" id="Gradient_7vgyc"] +offsets = PackedFloat32Array(0.00292398, 0.845029) +colors = PackedColorArray(0, 0, 0, 0, 1, 1, 1, 1) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_bhdch"] +gradient = SubResource("Gradient_7vgyc") +fill_to = Vector2(0, 1) + +[sub_resource type="Gradient" id="Gradient_hqvtw"] +offsets = PackedFloat32Array(0.459016, 0.565574, 0.704918, 0.827869, 0.92623, 1) +colors = PackedColorArray(0, 0, 0, 1, 0.132947, 0.132947, 0.132947, 0.867053, 0.286885, 0.286885, 0.286885, 0.713115, 0.536475, 0.536475, 0.536475, 0.463525, 0.790666, 0.790666, 0.790666, 0.209334, 1, 1, 1, 0) + +[sub_resource type="GradientTexture2D" id="GradientTexture2D_50sv0"] +gradient = SubResource("Gradient_hqvtw") +fill = 1 +fill_from = Vector2(0, 1) +fill_to = Vector2(1, 1) + +[sub_resource type="ShaderMaterial" id="ShaderMaterial_3bw0j"] +shader = ExtResource("8_4531v") +shader_parameter/dissolve = SubResource("GradientTexture2D_50sv0") + +[sub_resource type="InputEventKey" id="InputEventKey_x0ps1"] +device = -1 +ctrl_pressed = true +keycode = 68 + +[sub_resource type="Shortcut" id="Shortcut_vp2fh"] +events = [SubResource("InputEventKey_x0ps1")] + +[sub_resource type="LabelSettings" id="LabelSettings_0fjy0"] +font_size = 21 + +[sub_resource type="LabelSettings" id="LabelSettings_fiiw4"] +font_size = 12 + +[sub_resource type="LabelSettings" id="LabelSettings_v1ivf"] +font_size = 24 + +[sub_resource type="LabelSettings" id="LabelSettings_4yehb"] +font_size = 17 + +[sub_resource type="InputEventKey" id="InputEventKey_0jlka"] +device = -1 +ctrl_pressed = true +keycode = 82 + +[sub_resource type="Shortcut" id="Shortcut_axi6u"] +events = [SubResource("InputEventKey_0jlka")] + +[sub_resource type="InputEventKey" id="InputEventKey_117g0"] +device = -1 +ctrl_pressed = true +keycode = 83 + +[sub_resource type="Shortcut" id="Shortcut_8p5o4"] +events = [SubResource("InputEventKey_117g0")] + +[sub_resource type="InputEventKey" id="InputEventKey_5af16"] +device = -1 +keycode = 32 +unicode = 32 + +[sub_resource type="Shortcut" id="Shortcut_0ov5v"] +events = [SubResource("InputEventKey_5af16")] + +[sub_resource type="InputEventKey" id="InputEventKey_l1ahe"] +device = -1 +keycode = 4194321 + +[sub_resource type="Shortcut" id="Shortcut_qw6pv"] +events = [SubResource("InputEventKey_l1ahe")] + +[sub_resource type="InputEventKey" id="InputEventKey_c5qef"] +device = -1 +keycode = 76 +unicode = 108 + +[sub_resource type="Shortcut" id="Shortcut_vot6l"] +events = [SubResource("InputEventKey_c5qef")] + +[sub_resource type="InputEventKey" id="InputEventKey_y4cc2"] +device = -1 +keycode = 4194319 + +[sub_resource type="Shortcut" id="Shortcut_xu6hm"] +events = [SubResource("InputEventKey_y4cc2")] + +[sub_resource type="LabelSettings" id="LabelSettings_6prit"] +font_size = 22 +outline_size = 3 +outline_color = Color(0.215902, 0.215902, 0.215902, 1) + +[sub_resource type="LabelSettings" id="LabelSettings_jg5vn"] +font_size = 15 +outline_size = 3 +outline_color = Color(0.393086, 0.393086, 0.393085, 1) + +[sub_resource type="LabelSettings" id="LabelSettings_6um0v"] +font_size = 15 +outline_size = 3 +outline_color = Color(0.393086, 0.393086, 0.393085, 1) + +[sub_resource type="InputEventKey" id="InputEventKey_puhgg"] +device = -1 +ctrl_pressed = true +keycode = 81 + +[sub_resource type="Shortcut" id="Shortcut_g3fcr"] +events = [SubResource("InputEventKey_puhgg")] + +[node name="Node2D" type="Control"] +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +script = ExtResource("1_ubs1p") +LoopPressed = ExtResource("2_iolk5") +LoopNotPressed = ExtResource("5_c2g63") + +[node name="WallpaperManager" type="Node2D" parent="." node_paths=PackedStringArray("Daytime", "Evening", "Nighttime")] +script = ExtResource("4_y372l") +Daytime = NodePath("../Daytime") +Evening = NodePath("../Evening") +Nighttime = NodePath("../Nighttime") + +[node name="Daytime" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("2_wf35v") +stretch_mode = 6 + +[node name="Evening" type="TextureRect" parent="."] +visible = false +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_5vm0w") +stretch_mode = 6 + +[node name="Nighttime" type="TextureRect" parent="."] +visible = false +modulate = Color(0.347817, 0.347817, 0.347817, 1) +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +texture = ExtResource("6_8abnc") +stretch_mode = 6 + +[node name="UserBG" type="TextureRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +expand_mode = 5 +stretch_mode = 6 + +[node name="Logo" type="Sprite2D" parent="."] +visible = false +modulate = Color(1, 1, 1, 0.686275) +position = Vector2(192, 162) +scale = Vector2(0.159259, 0.159259) +texture = ExtResource("10_xnj6a") + +[node name="PausedIndicator" type="TextureRect" parent="."] +material = SubResource("ShaderMaterial_ku7tv") +layout_mode = 1 +anchors_preset = 12 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_top = -164.0 +grow_horizontal = 2 +grow_vertical = 0 +texture = SubResource("GradientTexture2D_bhdch") + +[node name="CoverHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = -3.0 +offset_top = 1.0 +offset_right = -3.0 +offset_bottom = 1.0 +grow_vertical = 0 + +[node name="Cover" type="Sprite2D" parent="CoverHolder"] +modulate = Color(1, 1, 1, 0.592157) +material = SubResource("ShaderMaterial_3bw0j") +scale = Vector2(0.333333, 0.333333) +region_rect = Rect2(142.036, 106.625, 632.359, 516.605) +region_filter_clip_enabled = true +script = ExtResource("12_3v50a") + +[node name="SelectPlaylist" type="Button" parent="."] +layout_mode = 0 +offset_left = 20.0 +offset_top = 24.0 +offset_right = 257.0 +offset_bottom = 80.0 +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_vp2fh") +text = "Playlists" +script = ExtResource("12_of5fe") + +[node name="PlaylistsPanel" type="Control" parent="."] +visible = false +layout_mode = 2 +anchors_preset = 0 +anchor_bottom = 1.0 +offset_left = 19.0 +offset_top = 88.0 +offset_right = 393.0 +offset_bottom = -132.0 +grow_vertical = 2 +script = ExtResource("12_8ie8y") +metadata/_edit_use_anchors_ = true + +[node name="ColorRect" type="ColorRect" parent="PlaylistsPanel"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0.14902, 0.14902, 0.14902, 1) + +[node name="PlaylistsContainer" type="ScrollContainer" parent="PlaylistsPanel"] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.0174419 +anchor_top = 0.0162455 +anchor_right = 0.982558 +anchor_bottom = 0.987365 +grow_horizontal = 2 +grow_vertical = 2 +follow_focus = true +horizontal_scroll_mode = 0 + +[node name="VBoxContainer" type="VBoxContainer" parent="PlaylistsPanel/PlaylistsContainer"] +custom_minimum_size = Vector2(365.295, 0) +layout_mode = 2 +size_flags_horizontal = 6 +size_flags_vertical = 0 + +[node name="Label" type="Label" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 0 +text = "PLAYLISTS" +label_settings = SubResource("LabelSettings_0fjy0") + +[node name="HBoxContainer" type="HBoxContainer" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_vertical = 4 +size_flags_stretch_ratio = 0.0 +alignment = 1 + +[node name="CreatePlaylist" type="Button" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(155, 42.335) +layout_mode = 2 +focus_mode = 0 +text = "Create +Playlist" + +[node name="Control" type="Control" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(7.55, 0) +layout_mode = 2 + +[node name="PlayAll" type="Button" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(155, 42.335) +layout_mode = 2 +focus_mode = 0 +toggle_mode = true +text = "Play all" + +[node name="PlaylistsHolder" type="VBoxContainer" parent="PlaylistsPanel/PlaylistsContainer/VBoxContainer"] +layout_mode = 2 +size_flags_vertical = 4 +alignment = 1 + +[node name="YoutubeMenuHolder" type="Control" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -391.17 +offset_top = 107.0 +offset_right = -351.17 +offset_bottom = 147.0 +grow_horizontal = 0 + +[node name="Youtube menu" type="Control" parent="YoutubeMenuHolder"] +layout_mode = 1 +anchors_preset = 0 +offset_right = 230.0 +offset_bottom = 110.0 + +[node name="ColorRect" type="ColorRect" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -7.0 +offset_top = -5.0 +offset_right = 7.0 +offset_bottom = 5.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0.14902, 0.14902, 0.14902, 1) + +[node name="YTLink" type="LineEdit" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_right = 229.0 +offset_bottom = 47.0 +placeholder_text = "Youtube link(can be playlist)" + +[node name="YTDownload" type="Button" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 1 +offset_left = 1.0 +offset_top = 70.0 +offset_right = 88.0 +offset_bottom = 110.0 +focus_mode = 0 +text = "Download" + +[node name="LoadingIMG" type="Sprite2D" parent="YoutubeMenuHolder/Youtube menu"] +position = Vector2(108, 91) +rotation = 1.5708 +scale = Vector2(-0.5, 0.5) +texture = ExtResource("13_de5ej") +script = ExtResource("14_rhw4k") + +[node name="Label" type="Label" parent="YoutubeMenuHolder/Youtube menu"] +layout_mode = 0 +offset_left = 1.99998 +offset_top = 49.0 +offset_right = 227.0 +offset_bottom = 72.0 +text = "NOTE: speeds depend on your internet" +label_settings = SubResource("LabelSettings_fiiw4") + +[node name="CreatePlaylistsMenu" type="Control" parent="."] +visible = false +layout_mode = 1 +anchor_left = 0.300347 +anchor_top = 0.243827 +anchor_right = 0.671007 +anchor_bottom = 0.665123 +offset_top = -1.52588e-05 +script = ExtResource("13_asgvh") +metadata/_edit_use_anchors_ = true + +[node name="ColorRect" type="ColorRect" parent="CreatePlaylistsMenu"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0.14902, 0.14902, 0.14902, 1) + +[node name="FileDialog" type="FileDialog" parent="CreatePlaylistsMenu"] +title = "Open a Directory" +size = Vector2i(352, 180) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="ScrollContainer" type="ScrollContainer" parent="CreatePlaylistsMenu"] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 15.0 +offset_top = 13.0 +offset_right = -15.0 +offset_bottom = -13.0 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="VBoxContainer" type="VBoxContainer" parent="CreatePlaylistsMenu/ScrollContainer"] +layout_mode = 2 +size_flags_horizontal = 3 + +[node name="Title" type="Label" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +text = "CREATE PLAYLIST" +label_settings = SubResource("LabelSettings_v1ivf") + +[node name="PlaylistName" type="LineEdit" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(325.08, 0) +layout_mode = 2 +size_flags_horizontal = 4 +placeholder_text = "Playlist name" + +[node name="GoodIndicator" type="Label" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +label_settings = SubResource("LabelSettings_4yehb") + +[node name="Seperator" type="Control" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 6) +layout_mode = 2 + +[node name="SelectDirButton" type="Button" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +text = "Select directory" + +[node name="CurrentDirectory" type="Label" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +text = "No directory selected" + +[node name="Seperator2" type="Control" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 14.865) +layout_mode = 2 + +[node name="CreatePlaylistButton" type="Button" parent="CreatePlaylistsMenu/ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(142.22, 43.1) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +disabled = true +text = "Create Playlist" + +[node name="CloseButton" type="Button" parent="CreatePlaylistsMenu"] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -72.0 +offset_bottom = 72.0 +grow_horizontal = 0 +focus_mode = 0 +icon = ExtResource("14_mioc4") +flat = true + +[node name="RandomizeList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -254.0 +offset_top = 24.0 +offset_right = -86.0 +offset_bottom = 80.0 +grow_horizontal = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_axi6u") +text = "Randomize" + +[node name="SettingsButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -77.0 +offset_top = 23.0 +offset_right = -5.0 +offset_bottom = 95.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +shortcut = SubResource("Shortcut_8p5o4") +icon = ExtResource("11_esjel") +script = ExtResource("12_073mb") + +[node name="SettingsPopup" type="Popup" parent="."] +position = Vector2i(319, 85) +size = Vector2i(591, 501) + +[node name="SettingsMenuChild" parent="SettingsPopup" instance=ExtResource("13_7atry")] +offset_left = -272.0 +offset_top = 8.0 +offset_bottom = 458.0 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +position = Vector2i(28, 115) +size = Vector2i(576, 507) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="MusicPlayer" type="AudioStreamPlayer" parent="."] +volume_db = -4.0 +bus = &"Music" + +[node name="playList" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 20.0 +offset_top = -77.0 +offset_right = 92.0 +offset_bottom = -5.0 +grow_vertical = 0 +scale = Vector2(0.5, 0.5) +focus_mode = 0 +shortcut = SubResource("Shortcut_0ov5v") +icon = ExtResource("8_5v7u3") + +[node name="CurrentProgress" type="HSlider" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 64.0 +offset_top = -88.0 +offset_right = -211.0 +offset_bottom = -24.0 +grow_horizontal = 2 +grow_vertical = 0 +max_value = 1000.0 +ticks_on_borders = true + +[node name="Skip" type="Button" parent="."] +texture_filter = 1 +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -105.0 +offset_top = -75.0 +offset_right = -65.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_qw6pv") +icon = ExtResource("3_4vx67") + +[node name="Loop" type="Button" parent="."] +texture_filter = 1 +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -152.0 +offset_top = -75.0 +offset_right = -112.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +shortcut = SubResource("Shortcut_vot6l") +icon = ExtResource("5_c2g63") + +[node name="GoBack" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -157.0 +offset_top = -35.0 +offset_right = -117.0 +offset_bottom = 5.0 +grow_horizontal = 0 +grow_vertical = 0 +rotation = 3.14159 +focus_mode = 0 +shortcut = SubResource("Shortcut_xu6hm") +icon = ExtResource("3_4vx67") + +[node name="SongName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 67.0 +offset_top = -120.0 +offset_right = -200.0 +offset_bottom = -89.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "Please select a directory" +label_settings = SubResource("LabelSettings_6prit") +clip_text = true +text_overrun_behavior = 2 + +[node name="ArtistName" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 68.0 +offset_top = -99.0 +offset_right = -199.0 +offset_bottom = -68.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "Artist name" +label_settings = SubResource("LabelSettings_jg5vn") +clip_text = true +text_overrun_behavior = 2 + +[node name="Album" type="Label" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = 68.0 +offset_top = -84.0 +offset_right = -199.0 +offset_bottom = -53.0 +grow_horizontal = 2 +grow_vertical = 0 +text = "Album" +label_settings = SubResource("LabelSettings_6um0v") +clip_text = true +text_overrun_behavior = 2 + +[node name="SearchToggle" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -318.0 +offset_top = 24.0 +offset_right = -246.0 +offset_bottom = 96.0 +grow_horizontal = 0 +scale = Vector2(0.79, 0.79) +focus_mode = 0 +toggle_mode = true +shortcut = SubResource("Shortcut_g3fcr") +icon = ExtResource("12_cv2gm") +script = ExtResource("13_5illk") +PressedIcon = ExtResource("14_mioc4") +NotPressedIcon = ExtResource("12_cv2gm") + +[node name="SearchBar" type="LineEdit" parent="."] +visible = false +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +focus_mode = 1 +placeholder_text = "Search" +alignment = 1 +caret_blink = true +script = ExtResource("12_mr42x") + +[node name="SongsMenu" type="MenuButton" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_right = 1.0 +offset_left = 264.0 +offset_top = 24.0 +offset_right = -328.0 +offset_bottom = 80.0 +grow_horizontal = 2 +text = "Select Songs" +flat = false + +[node name="SearchResults" type="PopupMenu" parent="."] +handle_input_locally = false +position = Vector2i(265, 80) +size = Vector2i(623, 300) +wrap_controls = false +max_size = Vector2i(625, 300) +allow_search = false + +[node name="VolumeButton" type="Button" parent="."] +texture_filter = 1 +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -58.0 +offset_top = -75.0 +offset_right = -18.0 +offset_bottom = -35.0 +grow_horizontal = 0 +grow_vertical = 0 +focus_mode = 0 +toggle_mode = true +icon = ExtResource("6_3mi6c") +script = ExtResource("14_7q3ja") + +[node name="VolumeSlider" type="VSlider" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -46.0 +offset_top = -83.0 +offset_right = -30.0 +offset_bottom = -75.0 +grow_horizontal = 0 +grow_vertical = 0 +size_flags_horizontal = 1 +size_flags_vertical = 8 +value = 100.0 + +[node name="TimeListeningSong" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 2 +anchor_top = 1.0 +anchor_bottom = 1.0 +offset_left = 67.0 +offset_top = -47.0 +offset_right = 179.0 +offset_bottom = -11.0 +grow_vertical = 0 + +[node name="DiscordMenuHolder" type="Control" parent="."] +layout_mode = 3 +anchors_preset = 0 +offset_left = 1042.0 +offset_top = 174.0 +offset_right = 1082.0 +offset_bottom = 214.0 + +[node name="YtTabButton" type="Button" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -97.0 +offset_top = 109.0 +offset_right = 551.0 +offset_bottom = 560.0 +grow_horizontal = 0 +grow_vertical = 2 +scale = Vector2(0.105, 0.105) +focus_mode = 0 +toggle_mode = true +icon = ExtResource("12_bc5ym") +flat = true +script = ExtResource("16_2t15p") + +[node name="Version" type="Label" parent="."] +layout_mode = 1 +anchors_preset = 3 +anchor_left = 1.0 +anchor_top = 1.0 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_left = -64.0 +offset_top = -23.0 +grow_horizontal = 0 +grow_vertical = 0 +text = "v1.3.0" +horizontal_alignment = 2 + +[node name="WavDisclaimer" type="AcceptDialog" parent="."] +transparent_bg = true +title = "WAV disclaimer" +initial_position = 4 +size = Vector2i(256, 100) +transparent = true +popup_window = true +force_native = true +dialog_text = "wav files are not supported yet" + +[connection signal="toggled" from="SelectPlaylist" to="SelectPlaylist" method="_on_toggled"] +[connection signal="pressed" from="PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer/CreatePlaylist" to="PlaylistsPanel" method="_on_create_playlist_pressed"] +[connection signal="toggled" from="PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer/PlayAll" to="PlaylistsPanel" method="_on_play_all_toggled"] +[connection signal="dir_selected" from="CreatePlaylistsMenu/FileDialog" to="CreatePlaylistsMenu" method="_on_file_dialog_dir_selected"] +[connection signal="text_changed" from="CreatePlaylistsMenu/ScrollContainer/VBoxContainer/PlaylistName" to="CreatePlaylistsMenu" method="_on_playlist_name_text_changed"] +[connection signal="pressed" from="CreatePlaylistsMenu/ScrollContainer/VBoxContainer/SelectDirButton" to="CreatePlaylistsMenu" method="_on_select_dir_button_pressed"] +[connection signal="pressed" from="CreatePlaylistsMenu/ScrollContainer/VBoxContainer/CreatePlaylistButton" to="CreatePlaylistsMenu" method="_on_create_playlist_button_pressed"] +[connection signal="pressed" from="CreatePlaylistsMenu/CloseButton" to="CreatePlaylistsMenu" method="_on_close_button_pressed"] +[connection signal="pressed" from="SettingsButton" to="SettingsButton" method="_on_pressed"] +[connection signal="toggled" from="SearchToggle" to="SearchToggle" method="_on_toggled"] +[connection signal="text_submitted" from="SearchBar" to="SearchBar" method="_on_text_submitted"] +[connection signal="index_pressed" from="SearchResults" to="SearchBar" method="_on_search_results_index_pressed"] +[connection signal="toggled" from="VolumeButton" to="VolumeButton" method="_on_toggled"] +[connection signal="toggled" from="YtTabButton" to="YtTabButton" method="_on_toggled"] diff --git a/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMeta.gd b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMeta.gd new file mode 100644 index 0000000..216eb38 --- /dev/null +++ b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMeta.gd @@ -0,0 +1,144 @@ +extends Node +class_name MusicMeta + +class MusicMetadata: + var error: Error + var bpm: int + var title: String + var album: String + var comments: String + var year: int + var artist: String + var cover: ImageTexture + + func print_info(): + print("bpm: ", bpm) + print("title: ", title) + print("album: ", album) + print("comments: ", comments) + print("year: ", year) + print("cover: ", cover) + print("artist: ", artist) + +func get_mp3_metadata(stream: AudioStreamMP3) -> MusicMetadata: + var meta: MusicMetadata = MusicMetadata.new() + var data: PackedByteArray = stream.data + + meta.error = OK + + if data.size() < 10: + meta.error = FAILED + return meta + + var header = data.slice(0, 10) + var id = header.slice(0, 3).get_string_from_ascii() + if id != "ID3": + meta.error = FAILED + push_error("Error: Stream data's header '%s' is not ID3."%id) + return meta + + var v = "ID3v2.%d.%d" % [header[3], header[4]] + if v == "ID3v2.4.0" or v == "ID3v2.3.0": + var flags = header[5] + var _unsync = flags & 0x80 > 0 + var extended = flags & 0x40 > 0 + var _experimental = flags & 0x20 > 0 + var _has_footer = flags & 0x10 > 0 + var idx = 10 + var end = idx + bytes_to_int(header.slice(6, 10)) + if extended: + idx += bytes_to_int(data.slice(idx, idx + 4)) + + while idx < end: + if not data: + meta.error = FAILED + push_error("Error: Stream data is null.") + return meta + + var frame_id = data.slice(idx, idx + 4).get_string_from_ascii() + var size = bytes_to_int(data.slice(idx + 4, idx + 8), frame_id != "APIC") + + # if greater than byte, not sync safe number (0b0111_1111 -> 0x7f) + if size > 0x7f: + size = bytes_to_int(data.slice(idx + 4, idx + 8), false) + idx += 10 + + match frame_id: + "TBPM", 'TBP': + meta.bpm = int(get_string_from_data(data, idx, size)) + "TIT2": + print("a " + str(Array(data.slice(idx, idx + 3)).hash())) + print([1, 0xff, 0xfe].hash()) + meta.title = get_string_from_data(data, idx, size) + "TALB", 'TAL': + meta.album = get_string_from_data(data, idx, size) + "COMM": + meta.comments = get_string_from_data(data, idx, size) + "TYER": + meta.year = int(get_string_from_data(data, idx, size)) + "TPE1", 'TP1': + meta.artist = get_string_from_data(data, idx, size) + "APIC","PIC": + var pic_frame = data.slice(idx + 1, idx + size) + var zero1 = pic_frame.find(0) + if zero1 > 0: + var mime_type = pic_frame.slice(0, zero1).get_string_from_ascii() + zero1 += 1 # Picture type + if zero1 < pic_frame.size(): + zero1 += 1 + if zero1 < pic_frame.size(): + var zero2 = pic_frame.find(0, zero1) + var image_bytes = pic_frame.slice(zero2 + 1, pic_frame.size()) + var img = Image.new() + match mime_type: + "image/png": + img.load_png_from_buffer(image_bytes) + "image/jpeg", "image/jpg": + img.load_jpg_from_buffer(image_bytes) + _: + meta.error = FAILED + push_error("MusicMeta.get_metadata_mp3(): ERROR: mime type ", mime_type, " not yet supported...") + return meta + var t: ImageTexture = ImageTexture.new() + t.set_image(img) + meta.cover = t + idx += size + + return meta + else: + meta.error = FAILED + push_error("Error: Found version '%s' from streams data; must be 'ID3v2.4.0'."%v) + return meta + + + + +func get_string_from_data(data, idx, size): + var ret + if size > 3 and Array(data.slice(idx, idx + 3)).hash() == [1, 0xff, 0xfe].hash(): + # Null-terminated string of ucs2 chars + ret = get_string_from_ucs2(data.slice(idx + 3, idx + size)) + if data[idx] == 0: + # Simple utf8 string + ret = data.slice(idx + 1, idx + size).get_string_from_utf8() + if ret: + return ret + else: + return "" + +# Syncsafe uses 0x80 multiplier otherwise use 0x100 multiplier +func bytes_to_int(bytes: Array, is_syncsafe = true): + var mult = 0x80 if is_syncsafe else 0x100 + var n = 0 + for byte in bytes: + n *= mult + n += byte + return n + +func get_string_from_ucs2(bytes: Array): + var s = "" + var idx = 0 + while idx < (bytes.size() - 1): + s += char(bytes[idx] + 256 * bytes[idx + 1]) + idx += 2 + return s diff --git a/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMetaPlugin.gd b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMetaPlugin.gd new file mode 100644 index 0000000..070d503 --- /dev/null +++ b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMetaPlugin.gd @@ -0,0 +1,10 @@ +@tool +extends EditorPlugin + +const AUTOLOAD_NAME = "MusicMeta" + +func _enter_tree(): + add_autoload_singleton(AUTOLOAD_NAME, "res://addons/MusicMeta/MusicMeta.gd") + +func _exit_tree(): + remove_autoload_singleton(AUTOLOAD_NAME) diff --git a/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/README.md b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/README.md new file mode 100644 index 0000000..fbadc7f --- /dev/null +++ b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/README.md @@ -0,0 +1,3 @@ +# MusicMeta - Godot 4 Plugin + +A plugin for extracting mp3 file metadata. diff --git a/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/examples/get_mp3_metadata.gd b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/examples/get_mp3_metadata.gd new file mode 100644 index 0000000..56fe52c --- /dev/null +++ b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/examples/get_mp3_metadata.gd @@ -0,0 +1,9 @@ +extends Node + +@export var Stream: AudioStreamMP3 + +func _ready(): + var metadata := MusicMeta.new().get_mp3_metadata(Stream) + if metadata.error != OK: + return + metadata.print_info() diff --git a/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/plugin.cfg b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/plugin.cfg new file mode 100644 index 0000000..6c391a2 --- /dev/null +++ b/MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/plugin.cfg @@ -0,0 +1,7 @@ +[plugin] + +name="MusicMeta" +description="An extension that allows the extraction of ID3v2.3.0 MP3 metadata." +author="aineejames,wilcockj" +version="1.0" +script="MusicMetaPlugin.gd" diff --git a/Pause.png b/Pause.png new file mode 100644 index 0000000..eebb73e Binary files /dev/null and b/Pause.png differ diff --git a/Pause.png.import b/Pause.png.import new file mode 100644 index 0000000..477c1bc --- /dev/null +++ b/Pause.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ch8wymyxftkb3" +path="res://.godot/imported/Pause.png-99d81406ad159c03d8332d8485dcc99a.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Pause.png" +dest_files=["res://.godot/imported/Pause.png-99d81406ad159c03d8332d8485dcc99a.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Play.png b/Play.png new file mode 100644 index 0000000..88c7b8c Binary files /dev/null and b/Play.png differ diff --git a/Play.png.import b/Play.png.import new file mode 100644 index 0000000..70c0121 --- /dev/null +++ b/Play.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ctb4s2nks73rx" +path="res://.godot/imported/Play.png-6c190f94eded8f6a668bcf021d49d2ce.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Play.png" +dest_files=["res://.godot/imported/Play.png-6c190f94eded8f6a668bcf021d49d2ce.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/PlaylistDisplay.tscn b/PlaylistDisplay.tscn new file mode 100644 index 0000000..6af31ab --- /dev/null +++ b/PlaylistDisplay.tscn @@ -0,0 +1,94 @@ +[gd_scene load_steps=4 format=3 uid="uid://c33qaelwn46f4"] + +[ext_resource type="Script" path="res://playlist_display.gd" id="1_h0jh1"] +[ext_resource type="Texture2D" uid="uid://dwvy6crqhardn" path="res://Dropdown.png" id="2_im6ur"] + +[sub_resource type="LabelSettings" id="LabelSettings_ky8oc"] +font_size = 12 +font_color = Color(0.597176, 0.597176, 0.597176, 1) + +[node name="PlaylistDisplay" type="Control"] +custom_minimum_size = Vector2(0, 67.92) +layout_mode = 3 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +offset_right = -910.0 +offset_bottom = -727.0 +grow_horizontal = 2 +grow_vertical = 2 +script = ExtResource("1_h0jh1") + +[node name="ColorRect" type="ColorRect" parent="."] +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 +color = Color(0.439049, 0.439049, 0.439049, 0.298039) + +[node name="HSplitContainer" type="HSplitContainer" parent="."] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.0247678 +anchor_top = 0.0882353 +anchor_right = 0.981424 +anchor_bottom = 0.897059 +grow_horizontal = 2 +grow_vertical = 2 +split_offset = 310 +dragger_visibility = 2 +metadata/_edit_use_anchors_ = true + +[node name="VBoxContainer" type="VBoxContainer" parent="HSplitContainer"] +layout_mode = 2 + +[node name="Name" type="RichTextLabel" parent="HSplitContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 24.395) +layout_mode = 2 +bbcode_enabled = true +text = "Name" +autowrap_mode = 0 + +[node name="Directory" type="Label" parent="HSplitContainer/VBoxContainer"] +layout_mode = 2 +text = "directory not found" +label_settings = SubResource("LabelSettings_ky8oc") +clip_text = true + +[node name="HBoxContainer" type="HBoxContainer" parent="HSplitContainer"] +layout_mode = 2 + +[node name="PlayButton" type="Button" parent="HSplitContainer/HBoxContainer"] +custom_minimum_size = Vector2(80, 0) +layout_mode = 2 +focus_mode = 0 +text = "Play" + +[node name="OptionsDropdown" type="MenuButton" parent="HSplitContainer/HBoxContainer"] +custom_minimum_size = Vector2(20.505, 0) +layout_mode = 2 +icon = ExtResource("2_im6ur") +expand_icon = true +item_count = 2 +popup/item_0/text = "Change Directory" +popup/item_1/text = "Delete" +popup/item_1/id = 1 + +[node name="FileDialog" type="FileDialog" parent="."] +title = "Open a Directory" +size = Vector2i(303, 180) +ok_button_text = "Select Current Folder" +file_mode = 2 +access = 2 +use_native_dialog = true + +[node name="ConfirmationDialog" type="ConfirmationDialog" parent="."] +position = Vector2i(445, 275) +size = Vector2i(359, 100) +dialog_text = "Are you sure you want to delete the playlist?" + +[connection signal="pressed" from="HSplitContainer/HBoxContainer/PlayButton" to="." method="_on_play_button_pressed"] +[connection signal="dir_selected" from="FileDialog" to="." method="_on_file_dialog_dir_selected"] +[connection signal="confirmed" from="ConfirmationDialog" to="." method="_on_confirmation_dialog_confirmed"] diff --git a/Project_4.mp3 b/Project_4.mp3 new file mode 100644 index 0000000..efafe75 Binary files /dev/null and b/Project_4.mp3 differ diff --git a/Project_4.mp3.import b/Project_4.mp3.import new file mode 100644 index 0000000..6df2575 --- /dev/null +++ b/Project_4.mp3.import @@ -0,0 +1,19 @@ +[remap] + +importer="mp3" +type="AudioStreamMP3" +uid="uid://cvndnnx1mdvqp" +path="res://.godot/imported/Project_4.mp3-7c16bd7b00580091b3ef24ad137a239b.mp3str" + +[deps] + +source_file="res://Project_4.mp3" +dest_files=["res://.godot/imported/Project_4.mp3-7c16bd7b00580091b3ef24ad137a239b.mp3str"] + +[params] + +loop=false +loop_offset=0 +bpm=0 +beat_count=0 +bar_beats=4 diff --git a/Settings.tscn b/Settings.tscn new file mode 100644 index 0000000..a9213d2 --- /dev/null +++ b/Settings.tscn @@ -0,0 +1,548 @@ +[gd_scene load_steps=9 format=3 uid="uid://dqg674t6kun4e"] + +[ext_resource type="Script" path="res://settings.gd" id="1_uaa7d"] +[ext_resource type="Script" path="res://eq_settings.gd" id="2_1n4m6"] +[ext_resource type="Texture2D" uid="uid://1rstn6r2wisy" path="res://X.png" id="2_iuivb"] +[ext_resource type="Texture2D" uid="uid://pgij783wgbhn" path="res://File.png" id="2_jmen4"] + +[sub_resource type="LabelSettings" id="LabelSettings_ouq8m"] +font_size = 30 + +[sub_resource type="LabelSettings" id="LabelSettings_2bhor"] +font_size = 25 + +[sub_resource type="LabelSettings" id="LabelSettings_p55k3"] +font_size = 11 + +[sub_resource type="LabelSettings" id="LabelSettings_cwn10"] +font_size = 15 + +[node name="SettingsMenuChild" type="Control"] +custom_minimum_size = Vector2(576, 493) +layout_mode = 3 +anchors_preset = 5 +anchor_left = 0.5 +anchor_right = 0.5 +offset_left = -288.0 +offset_right = 288.0 +offset_bottom = 493.0 +grow_horizontal = 2 +size_flags_vertical = 0 +script = ExtResource("1_uaa7d") + +[node name="ScrollContainer" type="ScrollContainer" parent="."] +custom_minimum_size = Vector2(576, 493) +layout_mode = 1 +anchors_preset = 15 +anchor_right = 1.0 +anchor_bottom = 1.0 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="VBoxContainer" type="VBoxContainer" parent="ScrollContainer"] +custom_minimum_size = Vector2(576, 493) +layout_mode = 2 +size_flags_vertical = 0 + +[node name="SETTINGS" type="Label" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(68.49, 25.94) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 3 +text = "SETTINGS" +label_settings = SubResource("LabelSettings_ouq8m") +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="Seperator5" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="THIRDPARTYAPPS" type="Label" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(400, 26.975) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 3 +text = "THIRD PARTY APPS" +label_settings = SubResource("LabelSettings_2bhor") +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="DiscordRichPresenceButton" type="CheckBox" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 0 +focus_mode = 0 +text = "Discord Rich Presence" + +[node name="disclaimer" type="Label" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(229.895, 0) +layout_mode = 2 +size_flags_horizontal = 0 +text = "NOTE: After disableing a restart is needed" +label_settings = SubResource("LabelSettings_p55k3") +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="Seperator4" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="Looks" type="Label" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(400, 26.975) +layout_mode = 2 +size_flags_vertical = 3 +text = "LOOKs" +label_settings = SubResource("LabelSettings_2bhor") +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 +uppercase = true + +[node name="Seperator3" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="VBoxContainer" type="VBoxContainer" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 + +[node name="HBoxContainer2" type="HBoxContainer" parent="ScrollContainer/VBoxContainer/VBoxContainer"] +layout_mode = 2 + +[node name="TextureRect" type="TextureRect" parent="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer2"] +texture_filter = 1 +custom_minimum_size = Vector2(15, 15) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +texture = ExtResource("2_jmen4") +expand_mode = 3 + +[node name="BackroundDirLabel" type="Label" parent="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer2"] +layout_mode = 2 +size_flags_horizontal = 0 +label_settings = SubResource("LabelSettings_cwn10") + +[node name="HBoxContainer" type="HBoxContainer" parent="ScrollContainer/VBoxContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 0 + +[node name="SelectBG" type="Button" parent="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(0, 25.35) +layout_mode = 2 +size_flags_horizontal = 4 +text = "Select Background" + +[node name="ResetBG" type="Button" parent="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer"] +custom_minimum_size = Vector2(0, 25.35) +layout_mode = 2 +size_flags_horizontal = 4 +text = "Reset BG" + +[node name="SelectBGDialog" type="FileDialog" parent="ScrollContainer/VBoxContainer"] +title = "Open a File" +size = Vector2i(324, 180) +transient = false +ok_button_text = "Open" +file_mode = 0 +access = 2 +filters = PackedStringArray("*.png", "*.jpg", "*.jpeg", "*") +show_hidden_files = true +use_native_dialog = true + +[node name="Seperator2" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(400, 26.975) +layout_mode = 2 +size_flags_vertical = 3 +text = "SOUND SETTINGS" +label_settings = SubResource("LabelSettings_2bhor") +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="Seperator" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="PitchAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="PitchSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/PitchAdjustSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +min_value = 0.25 +max_value = 2.0 +step = 0.05 +value = 1.0 + +[node name="PitchAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/PitchAdjustSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="PitchValue" type="Label" parent="ScrollContainer/VBoxContainer/PitchAdjustSettings/PitchAdjustSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/PitchAdjustSettings/PitchAdjustSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "pitch/speed" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="ReverbCheck" type="CheckBox" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 0 +focus_mode = 0 +text = "Reverb" + +[node name="ReverbSettings" type="VBoxContainer" parent="ScrollContainer/VBoxContainer"] +visible = false +layout_mode = 2 + +[node name="SizeAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="RoomSizeSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +max_value = 0.95 +step = 0.05 +value = 0.8 + +[node name="PitchAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="RoomSizeValue" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings/PitchAdjustSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings/PitchAdjustSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Room size" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="DampeningAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="DampeningSizeSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +max_value = 0.95 +step = 0.05 +value = 0.8 + +[node name="DampaningAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="DampeningValue" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings/DampaningAdjustSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings/DampaningAdjustSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Damping" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="SpreadAdjustSettings2" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="SpreadSizeSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +max_value = 0.95 +step = 0.05 +value = 0.8 + +[node name="SpreadAdjustSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="SpreadValue" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2/SpreadAdjustSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2/SpreadAdjustSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Spread" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="EQCheckBox" type="CheckBox" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 0 +focus_mode = 0 +text = "EQ" + +[node name="EQSettings" type="VBoxContainer" parent="ScrollContainer/VBoxContainer"] +visible = false +layout_mode = 2 +script = ExtResource("2_1n4m6") + +[node name="CompressionCheck" type="CheckBox" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 0 +focus_mode = 0 +text = "Compression" + +[node name="CompressionContainer" type="VBoxContainer" parent="ScrollContainer/VBoxContainer"] +visible = false +layout_mode = 2 + +[node name="ThresholdSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="ThresholdSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +min_value = -60.0 +max_value = 0.0 +step = 0.5 +value = -9.0 + +[node name="ThresholdSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="ThresholdValue" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings/ThresholdSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings/ThresholdSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Threshold" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="RatioSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="RatioSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +min_value = 1.0 +max_value = 48.0 +value = 4.0 + +[node name="RatioSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="RatioValue" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings/RatioSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings/RatioSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Ratio +" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="GainSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer"] +custom_minimum_size = Vector2(328.985, 0) +layout_mode = 2 +size_flags_horizontal = 0 +split_offset = 200 +dragger_visibility = 2 + +[node name="GainSlider" type="HSlider" parent="ScrollContainer/VBoxContainer/CompressionContainer/GainSettings"] +layout_mode = 2 +size_flags_vertical = 4 +focus_mode = 0 +min_value = -10.0 +max_value = 8.0 +step = 0.5 + +[node name="GainSettings" type="HSplitContainer" parent="ScrollContainer/VBoxContainer/CompressionContainer/GainSettings"] +custom_minimum_size = Vector2(130.38, 0) +layout_mode = 2 +size_flags_horizontal = 4 +split_offset = 995 +dragger_visibility = 2 + +[node name="GainValue" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/GainSettings/GainSettings"] +custom_minimum_size = Vector2(23.9, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "1.0" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="FUN" type="Label" parent="ScrollContainer/VBoxContainer/CompressionContainer/GainSettings/GainSettings"] +custom_minimum_size = Vector2(94.52, 7.51) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 6 +text = "Gain +" +horizontal_alignment = 1 +vertical_alignment = 1 +autowrap_mode = 2 + +[node name="Seperator6" type="Control" parent="ScrollContainer/VBoxContainer"] +custom_minimum_size = Vector2(0, 16.07) +layout_mode = 2 + +[node name="TimeListening" type="Label" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 0 + +[node name="Reset" type="Button" parent="ScrollContainer/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +focus_mode = 0 +text = "RESET SETTINGS" + +[node name="Exit" type="Button" parent="."] +layout_mode = 1 +anchors_preset = 1 +anchor_left = 1.0 +anchor_right = 1.0 +offset_left = -72.0 +offset_bottom = 72.0 +grow_horizontal = 0 +size_flags_horizontal = 8 +size_flags_vertical = 0 +focus_mode = 0 +icon = ExtResource("2_iuivb") +flat = true + +[connection signal="toggled" from="ScrollContainer/VBoxContainer/DiscordRichPresenceButton" to="." method="_on_discord_rich_presence_button_toggled"] +[connection signal="pressed" from="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer/SelectBG" to="." method="_on_select_bg_pressed"] +[connection signal="pressed" from="ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer/ResetBG" to="." method="_on_reset_bg_pressed"] +[connection signal="file_selected" from="ScrollContainer/VBoxContainer/SelectBGDialog" to="." method="_on_select_bg_dialog_file_selected"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/PitchAdjustSettings/PitchSlider" to="." method="_on_h_slider_drag_ended"] +[connection signal="toggled" from="ScrollContainer/VBoxContainer/ReverbCheck" to="." method="_on_reverb_check_toggled"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings/RoomSizeSlider" to="." method="_on_room_size_slider_drag_ended"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings/DampeningSizeSlider" to="." method="_on_dampening_size_slider_drag_ended"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2/SpreadSizeSlider" to="." method="_on_spread_size_slider_drag_ended"] +[connection signal="toggled" from="ScrollContainer/VBoxContainer/EQCheckBox" to="." method="_on_eq_check_box_toggled"] +[connection signal="toggled" from="ScrollContainer/VBoxContainer/CompressionCheck" to="." method="_on_compression_check_toggled"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings/ThresholdSlider" to="." method="_on_threshold_slider_drag_ended"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings/RatioSlider" to="." method="_on_ratio_slider_drag_ended"] +[connection signal="drag_ended" from="ScrollContainer/VBoxContainer/CompressionContainer/GainSettings/GainSlider" to="." method="_on_gain_slider_drag_ended"] +[connection signal="pressed" from="ScrollContainer/VBoxContainer/Reset" to="." method="_on_reset_pressed"] +[connection signal="pressed" from="ScrollContainer/VBoxContainer/Reset" to="ScrollContainer/VBoxContainer/EQSettings" method="_on_reset_pressed"] +[connection signal="pressed" from="Exit" to="." method="_on_exit_pressed"] diff --git a/Skip.png b/Skip.png new file mode 100644 index 0000000..aa4d833 Binary files /dev/null and b/Skip.png differ diff --git a/Skip.png.import b/Skip.png.import new file mode 100644 index 0000000..59fd94a --- /dev/null +++ b/Skip.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://daq8wnhtscpjl" +path="res://.godot/imported/Skip.png-07c55752ee3a8c4e00f218deff844b62.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Skip.png" +dest_files=["res://.godot/imported/Skip.png-07c55752ee3a8c4e00f218deff844b62.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Spinning.gd b/Spinning.gd new file mode 100644 index 0000000..183777b --- /dev/null +++ b/Spinning.gd @@ -0,0 +1,11 @@ +extends Sprite2D + + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + rotation_degrees += 90 * delta * 2 diff --git a/Theme.tres b/Theme.tres new file mode 100644 index 0000000..ddc45b1 --- /dev/null +++ b/Theme.tres @@ -0,0 +1,3 @@ +[gd_resource type="Theme" format=3 uid="uid://cpd5cym1d4tde"] + +[resource] diff --git a/X.png b/X.png new file mode 100644 index 0000000..2881f6d Binary files /dev/null and b/X.png differ diff --git a/X.png.import b/X.png.import new file mode 100644 index 0000000..10802cd --- /dev/null +++ b/X.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://1rstn6r2wisy" +path="res://.godot/imported/X.png-bee569f28a73ace116a223ee2aee69ec.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://X.png" +dest_files=["res://.godot/imported/X.png-bee569f28a73ace116a223ee2aee69ec.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/Youtube_logo.png b/Youtube_logo.png new file mode 100644 index 0000000..a37389d Binary files /dev/null and b/Youtube_logo.png differ diff --git a/Youtube_logo.png.import b/Youtube_logo.png.import new file mode 100644 index 0000000..f380244 --- /dev/null +++ b/Youtube_logo.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bdpat2sfflaxq" +path="res://.godot/imported/Youtube_logo.png-22e44a6c4c4bd7a2da4492032ea62686.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://Youtube_logo.png" +dest_files=["res://.godot/imported/Youtube_logo.png-22e44a6c4c4bd7a2da4492032ea62686.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/addons/discord-rpc-gd/Debug.svg b/addons/discord-rpc-gd/Debug.svg new file mode 100644 index 0000000..7987166 --- /dev/null +++ b/addons/discord-rpc-gd/Debug.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/addons/discord-rpc-gd/Debug.svg.import b/addons/discord-rpc-gd/Debug.svg.import new file mode 100644 index 0000000..4596fbd --- /dev/null +++ b/addons/discord-rpc-gd/Debug.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ufh1hha1ehui" +path="res://.godot/imported/Debug.svg-d4cb8599fa7926b76a2d6e40d2efd949.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/Debug.svg" +dest_files=["res://.godot/imported/Debug.svg-d4cb8599fa7926b76a2d6e40d2efd949.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/addons/discord-rpc-gd/Logo_V2_No_Bg.png b/addons/discord-rpc-gd/Logo_V2_No_Bg.png new file mode 100644 index 0000000..fb6c700 Binary files /dev/null and b/addons/discord-rpc-gd/Logo_V2_No_Bg.png differ diff --git a/addons/discord-rpc-gd/Logo_V2_No_Bg.png.import b/addons/discord-rpc-gd/Logo_V2_No_Bg.png.import new file mode 100644 index 0000000..a1f1230 --- /dev/null +++ b/addons/discord-rpc-gd/Logo_V2_No_Bg.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://csl0e2px0cwc1" +path="res://.godot/imported/Logo_V2_No_Bg.png-ed667fb599fe1e17ebcfc361ff7c9c93.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/Logo_V2_No_Bg.png" +dest_files=["res://.godot/imported/Logo_V2_No_Bg.png-ed667fb599fe1e17ebcfc361ff7c9c93.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/addons/discord-rpc-gd/READ_ME_PLEASE.txt b/addons/discord-rpc-gd/READ_ME_PLEASE.txt new file mode 100644 index 0000000..a98427b --- /dev/null +++ b/addons/discord-rpc-gd/READ_ME_PLEASE.txt @@ -0,0 +1,7 @@ +MINIMUM GODOT VERSION: 4.2 + +PLEASE ACTIVATE THE PLUGIN UNDER Project -> Project Settings... -> Plugins -> DiscordRPC -> Status +IGNORE THE RED ERRORS ON THE FIRST 2 RESTARTS +READ THE TUTORIAL LINKED IN THE WINDOW THAT WILL OPEN ON PLUGIN ENABLE + +If nothing works, enable the plugin and delete /addons/discord-rpc-gd/bin/.gdignore diff --git a/addons/discord-rpc-gd/bin/discord-rpc-gd.gdextension b/addons/discord-rpc-gd/bin/discord-rpc-gd.gdextension new file mode 100644 index 0000000..27e2845 --- /dev/null +++ b/addons/discord-rpc-gd/bin/discord-rpc-gd.gdextension @@ -0,0 +1,29 @@ +[configuration] + +entry_symbol = "discordrpcgd_library_init" +compatibility_minimum = 4.1 + +[libraries] + +macos.debug = "macos/libdiscord_game_sdk_binding_debug.dylib" +macos.release = "macos/libdiscord_game_sdk_binding.dylib" +windows.debug.x86_64 = "windows/discord_game_sdk_binding_debug.dll" +windows.release.x86_64 = "windows/discord_game_sdk_binding.dll" +linux.debug.x86_64 = "linux/libdiscord_game_sdk_binding_debug.so" +linux.release.x86_64 = "linux/libdiscord_game_sdk_binding.so" +linux.debug.arm64 = "linux/libdiscord_game_sdk_binding_debug.so" +linux.release.arm64 = "linux/libdiscord_game_sdk_binding.so" +linux.debug.rv64 = "linux/libdiscord_game_sdk_binding_debug.so" +linux.release.rv64 = "linux/libdiscord_game_sdk_binding.so" + +[dependencies] + +macos = { "macos/libdiscord_game_sdk.dylib": "" } +windows.debug.x86_64 = { "windows/discord_game_sdk.dll": "" } +windows.release.x86_64 = { "windows/discord_game_sdk.dll": "" } +linux.debug.x86_64 = { "linux/libdiscord_game_sdk.so": "" } +linux.release.x86_64 = { "linux/libdiscord_game_sdk.so": "" } +linux.debug.arm64 = { "linux/libdiscord_game_sdk.so": "" } +linux.release.arm64 = { "linux/libdiscord_game_sdk.so": "" } +linux.debug.rv64 = { "linux/libdiscord_game_sdk.so": "" } +linux.release.rv64 = { "linux/libdiscord_game_sdk.so": "" } diff --git a/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk.so b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk.so new file mode 100644 index 0000000..9dacf94 Binary files /dev/null and b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk.so differ diff --git a/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding.so b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding.so new file mode 100644 index 0000000..f9863c4 Binary files /dev/null and b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding.so differ diff --git a/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding_debug.so b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding_debug.so new file mode 100644 index 0000000..89bf7da Binary files /dev/null and b/addons/discord-rpc-gd/bin/linux/libdiscord_game_sdk_binding_debug.so differ diff --git a/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk.dylib b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk.dylib new file mode 100644 index 0000000..2cc726d Binary files /dev/null and b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk.dylib differ diff --git a/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding.dylib b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding.dylib new file mode 100644 index 0000000..cfcd1a7 Binary files /dev/null and b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding.dylib differ diff --git a/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding_debug.dylib b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding_debug.dylib new file mode 100644 index 0000000..082e396 Binary files /dev/null and b/addons/discord-rpc-gd/bin/macos/libdiscord_game_sdk_binding_debug.dylib differ diff --git a/addons/discord-rpc-gd/bin/windows/discord_game_sdk.dll b/addons/discord-rpc-gd/bin/windows/discord_game_sdk.dll new file mode 100644 index 0000000..be946ea Binary files /dev/null and b/addons/discord-rpc-gd/bin/windows/discord_game_sdk.dll differ diff --git a/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding.dll b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding.dll new file mode 100644 index 0000000..77ffef2 Binary files /dev/null and b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding.dll differ diff --git a/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding_debug.dll b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding_debug.dll new file mode 100644 index 0000000..2b52a76 Binary files /dev/null and b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_binding_debug.dll differ diff --git a/addons/discord-rpc-gd/bin/windows/discord_game_sdk_x86.dll b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_x86.dll new file mode 100644 index 0000000..45b9bb1 Binary files /dev/null and b/addons/discord-rpc-gd/bin/windows/discord_game_sdk_x86.dll differ diff --git a/addons/discord-rpc-gd/bin/windows/~discord_game_sdk_binding_debug.dll b/addons/discord-rpc-gd/bin/windows/~discord_game_sdk_binding_debug.dll new file mode 100644 index 0000000..2b52a76 Binary files /dev/null and b/addons/discord-rpc-gd/bin/windows/~discord_game_sdk_binding_debug.dll differ diff --git a/addons/discord-rpc-gd/example.gd b/addons/discord-rpc-gd/example.gd new file mode 100644 index 0000000..95f2926 --- /dev/null +++ b/addons/discord-rpc-gd/example.gd @@ -0,0 +1,38 @@ +class_name DiscordRPCTutorial +extends Node + +## 1. Put the addons/ folder in your Godot project[br] +## 2. Enable the addon in your Project Settings under "Plugins" and "DiscordRPC". [br](if it doesn't show up restart your project and try again)[br] +## 3. Restart your project[br] +## 4. Create an Application under https://discord.com/developers/applications and get the Application ID br] +## 5. (optional) Set images under "Rich Presence" and "Art Assets" and remember the keys[br] +## +## This is your [code]_ready()[/code] function wich could be anywhere +## [codeblock] +## func _ready(): +## # Application ID +## DiscordRPC.app_id = 1099618430065324082 +## # this is boolean if everything worked +## print("Discord working: " + str(DiscordRPC.get_is_discord_working())) +## # Set the first custom text row of the activity here +## DiscordRPC.details = "A demo activity by vaporvee#1231" +## # Set the second custom text row of the activity here +## DiscordRPC.state = "Checkpoint 23/23" +## # Image key for small image from "Art Assets" from the Discord Developer website +## DiscordRPC.large_image = "game" +## # Tooltip text for the large image +## DiscordRPC.large_image_text = "Try it now!" +## # Image key for large image from "Art Assets" from the Discord Developer website +## DiscordRPC.small_image = "boss" +## # Tooltip text for the small image +## DiscordRPC.small_image_text = "Fighting the end boss! D:" +## # "02:41 elapsed" timestamp for the activity +## DiscordRPC.start_timestamp = int(Time.get_unix_time_from_system()) +## # "59:59 remaining" timestamp for the activity +## DiscordRPC.end_timestamp = int(Time.get_unix_time_from_system()) + 3600 +## # Always refresh after changing the values! +## DiscordRPC.refresh() +## [/codeblock] +## +## @tutorial(More information here): https://github.com/vaporvee/discord-rpc-godot/wiki/Quick-start +## @tutorial(Make your Application ID and else here): https://discord.com/developers/applications diff --git a/addons/discord-rpc-gd/logo.png b/addons/discord-rpc-gd/logo.png new file mode 100644 index 0000000..fb6c700 Binary files /dev/null and b/addons/discord-rpc-gd/logo.png differ diff --git a/addons/discord-rpc-gd/logo.png.import b/addons/discord-rpc-gd/logo.png.import new file mode 100644 index 0000000..1cce19a --- /dev/null +++ b/addons/discord-rpc-gd/logo.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://csl0e2px0cwc1" +path="res://.godot/imported/logo.png-bacb448eabae556bdb0659359ea4e4af.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/logo.png" +dest_files=["res://.godot/imported/logo.png-bacb448eabae556bdb0659359ea4e4af.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/addons/discord-rpc-gd/nodes/Debug.tscn b/addons/discord-rpc-gd/nodes/Debug.tscn new file mode 100644 index 0000000..9afc6d3 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/Debug.tscn @@ -0,0 +1,268 @@ +[gd_scene load_steps=9 format=3 uid="uid://c1slhdnlsv2qt"] + +[ext_resource type="Texture2D" uid="uid://dnfq6kug4x6o2" path="res://addons/discord-rpc-gd/nodes/assets/Checked.svg" id="2_q6tao"] +[ext_resource type="Texture2D" uid="uid://compmm3kviqqe" path="res://addons/discord-rpc-gd/nodes/assets/Unchecked.svg" id="3_5cyem"] +[ext_resource type="Texture2D" uid="uid://dtc6ckladq0td" path="res://addons/discord-rpc-gd/nodes/assets/circle.svg" id="3_goflf"] + +[sub_resource type="GDScript" id="GDScript_ak1tp"] +resource_name = "Debug" +script/source = "extends Node + +func _ready(): + DiscordRPC.app_id = 1276916292170809426 + DiscordRPC.connect(\"activity_join_request\",_on_activity_join_request) + +func _process(_delta): + if(DiscordRPC.get_is_discord_working()): + $Panel/TextureRect.self_modulate = Color(\"#3eff8d\") + $Panel/TextureRect/AnimationPlayer.play(\"pulsate\") + debug_text_update() + else: + $Panel/TextureRect.self_modulate = Color(\"#797979\") + $Panel/TextureRect/AnimationPlayer.stop() + debug_text_update() + + +func debug_text_update(): + $Panel/Info.text = \"Application ID : {id} +Details: {details} +State: {state} + +Large image key: {lkey} +Large image text: {ltext} +Small image key: {skey} +Small image text: {stext} + +Start timestamp: {stimestamp} +End timestamp: {etimestamp} + +Party ID: {partyid} +Current party size: {cpartysize} +Max party size: {mpartysize} +Match secret: {msecret} +Join secret: {jsecret} +Spectate secret: {ssecret} +Is party public: {ppublic} (needs to be activated in Discord client settings) + +Is instanced: {instanced} +\" + $Panel/Info.text = $Panel/Info.text.replace(\"{ppublic}\",str(DiscordRPC.is_public_party)).replace(\"{instanced}\",str(DiscordRPC.instanced)).replace(\"{ssecret}\",DiscordRPC.spectate_secret).replace(\"{jsecret}\",DiscordRPC.join_secret).replace(\"{msecret}\",DiscordRPC.match_secret).replace(\"{mpartysize}\",str(DiscordRPC.max_party_size)).replace(\"{cpartysize}\",str(DiscordRPC.current_party_size)).replace(\"{partyid}\",DiscordRPC.party_id).replace(\"{id}\",str(DiscordRPC.app_id)).replace(\"{details}\",DiscordRPC.details).replace(\"{state}\",DiscordRPC.state).replace(\"{lkey}\",DiscordRPC.large_image).replace(\"{ltext}\",DiscordRPC.large_image_text).replace(\"{skey}\",DiscordRPC.small_image).replace(\"{stext}\",DiscordRPC.small_image_text).replace(\"{stimestamp}\",str(DiscordRPC.start_timestamp)).replace(\"{etimestamp}\",str(DiscordRPC.end_timestamp)) + +var user_request = {}; + +func _on_activity_join_request(user_requesting): + print(user_requesting) + user_request = user_requesting + +func _on_accept_join_request_pressed(): + if(!user_request.is_empty()): + DiscordRPC.accept_join_request(user_request.id) + +func _on_invite_with_user_id_text_submitted(new_text): + DiscordRPC.send_invite(int(new_text),true,\"this is a test invite sent from godot\") + +func _on_accept_with_user_id_text_submitted(new_text): + DiscordRPC.accept_invite(int(new_text)) + +func _on_print_current_user_on_console_pressed(): + print(DiscordRPC.get_current_user()) + +func _on_toggle_sdk_toggled(button_pressed): + if(button_pressed): + DiscordRPC.unclear() + else: + DiscordRPC.clear(false) + +func _on_print_friends_pressed(): + print(DiscordRPC.get_all_relationships()) +" + +[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_8abo6"] + +[sub_resource type="Animation" id="Animation_mmtmn"] +length = 0.001 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath(".:scale") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0.4), +"transitions": PackedFloat32Array(1), +"update": 0, +"values": [Vector2(0.5, 0.5)] +} + +[sub_resource type="Animation" id="Animation_5u02v"] +resource_name = "pulsate" +loop_mode = 1 +tracks/0/type = "value" +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/path = NodePath(".:scale") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/keys = { +"times": PackedFloat32Array(0, 0.5, 1), +"transitions": PackedFloat32Array(1, 1, 1), +"update": 0, +"values": [Vector2(0.5, 0.5), Vector2(0.8, 0.8), Vector2(0.5, 0.5)] +} + +[sub_resource type="AnimationLibrary" id="AnimationLibrary_a7ofc"] +_data = { +"RESET": SubResource("Animation_mmtmn"), +"pulsate": SubResource("Animation_5u02v") +} + +[node name="DebugNodeGroup" type="Node"] +editor_description = "This is a Debug Node wich will show (only if the project runs) some usefull info and buttons/input" +script = SubResource("GDScript_ak1tp") + +[node name="Panel" type="Panel" parent="."] +anchors_preset = -1 +anchor_right = 0.373 +anchor_bottom = 1.0 +offset_left = -5.0 +offset_right = 0.303955 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="Info" type="RichTextLabel" parent="Panel"] +layout_mode = 0 +offset_left = 12.0 +offset_top = 21.0 +offset_right = 429.0 +offset_bottom = 461.0 +theme_override_font_sizes/normal_font_size = 14 +text = "Application ID : {id} +Details: {details} +State: {state} + +Large image key: {lkey} +Large image text: {ltext} +Small image key: {skey} +Small image text: {stext} + +Start timestamp: {stimestamp} +End timestamp: {etimestamp} + +Party ID: {partyid} +Current party size: {cpartysize} +Max party size: {mpartysize} +Match secret: {msecret} +Join secret: {jsecret} +Spectate secret: {ssecret} +Is party public: {ppublic} (needs to be activated in Discord client settings) + +Is instanced: {instanced} +" +fit_content = true + +[node name="PrintCurrentUserOnConsole" type="Button" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 12.0 +offset_top = 138.375 +offset_right = 245.0 +offset_bottom = 171.375 +grow_vertical = 2 +text = "Print current user on console" + +[node name="PrintFriends" type="Button" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 12.0 +offset_top = 176.5 +offset_right = 204.0 +offset_bottom = 207.5 +grow_vertical = 2 +text = "Print friends on console" + +[node name="AcceptJoinRequest" type="Button" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 12.0 +offset_top = 212.875 +offset_right = 154.0 +offset_bottom = 243.875 +grow_vertical = 2 +text = "ACCEPT REQUEST" + +[node name="InviteWithUserID" type="LineEdit" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 11.0 +offset_top = 250.375 +offset_right = 210.0 +offset_bottom = 281.375 +grow_vertical = 2 +size_flags_horizontal = 0 +placeholder_text = "Invite with user_id here" + +[node name="AcceptWithUserID" type="LineEdit" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 11.0 +offset_top = 286.875 +offset_right = 260.0 +offset_bottom = 317.875 +grow_vertical = 2 +placeholder_text = "Accept Invite with user_id here" + +[node name="ToggleSDK" type="CheckButton" parent="Panel"] +layout_mode = 1 +anchors_preset = 4 +anchor_top = 0.5 +anchor_bottom = 0.5 +offset_left = 298.0 +offset_top = 157.375 +offset_right = 1144.0 +offset_bottom = 665.375 +grow_vertical = 2 +scale = Vector2(0.05, 0.05) +theme_override_styles/focus = SubResource("StyleBoxEmpty_8abo6") +theme_override_icons/checked = ExtResource("2_q6tao") +theme_override_icons/unchecked = ExtResource("3_5cyem") +button_pressed = true + +[node name="TextureRect" type="TextureRect" parent="Panel"] +self_modulate = Color(0.47451, 0.47451, 0.47451, 1) +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.88 +anchor_top = 0.762 +anchor_right = 0.88 +anchor_bottom = 0.762 +offset_left = -28.8 +offset_top = -28.776 +offset_right = 28.0841 +offset_bottom = 28.1082 +grow_horizontal = 2 +grow_vertical = 2 +scale = Vector2(0.5, 0.5) +pivot_offset = Vector2(29.0693, 29.0693) +texture = ExtResource("3_goflf") + +[node name="AnimationPlayer" type="AnimationPlayer" parent="Panel/TextureRect"] +libraries = { +"": SubResource("AnimationLibrary_a7ofc") +} + +[connection signal="pressed" from="Panel/PrintCurrentUserOnConsole" to="." method="_on_print_current_user_on_console_pressed"] +[connection signal="pressed" from="Panel/PrintFriends" to="." method="_on_print_friends_pressed"] +[connection signal="pressed" from="Panel/AcceptJoinRequest" to="." method="_on_accept_join_request_pressed"] +[connection signal="text_submitted" from="Panel/InviteWithUserID" to="." method="_on_invite_with_user_id_text_submitted"] +[connection signal="text_submitted" from="Panel/AcceptWithUserID" to="." method="_on_accept_with_user_id_text_submitted"] +[connection signal="toggled" from="Panel/ToggleSDK" to="." method="_on_toggle_sdk_toggled"] diff --git a/addons/discord-rpc-gd/nodes/assets/Checked.svg b/addons/discord-rpc-gd/nodes/assets/Checked.svg new file mode 100644 index 0000000..d37a1c2 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/Checked.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/addons/discord-rpc-gd/nodes/assets/Checked.svg.import b/addons/discord-rpc-gd/nodes/assets/Checked.svg.import new file mode 100644 index 0000000..9913c3c --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/Checked.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dnfq6kug4x6o2" +path="res://.godot/imported/Checked.svg-80704e37f30c24e2ec3dfc0955f5f21c.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/nodes/assets/Checked.svg" +dest_files=["res://.godot/imported/Checked.svg-80704e37f30c24e2ec3dfc0955f5f21c.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/addons/discord-rpc-gd/nodes/assets/Unchecked.svg b/addons/discord-rpc-gd/nodes/assets/Unchecked.svg new file mode 100644 index 0000000..58cb234 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/Unchecked.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/addons/discord-rpc-gd/nodes/assets/Unchecked.svg.import b/addons/discord-rpc-gd/nodes/assets/Unchecked.svg.import new file mode 100644 index 0000000..7503ec8 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/Unchecked.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://compmm3kviqqe" +path="res://.godot/imported/Unchecked.svg-b526adfd78f7b1577fc3c10a8ea626ee.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/nodes/assets/Unchecked.svg" +dest_files=["res://.godot/imported/Unchecked.svg-b526adfd78f7b1577fc3c10a8ea626ee.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/addons/discord-rpc-gd/nodes/assets/circle.svg b/addons/discord-rpc-gd/nodes/assets/circle.svg new file mode 100644 index 0000000..acd3753 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/circle.svg @@ -0,0 +1,11 @@ + + + + + + + \ No newline at end of file diff --git a/addons/discord-rpc-gd/nodes/assets/circle.svg.import b/addons/discord-rpc-gd/nodes/assets/circle.svg.import new file mode 100644 index 0000000..509c745 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/assets/circle.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://dtc6ckladq0td" +path="res://.godot/imported/circle.svg-d0b0579c9433c6250a5869daf4f70024.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://addons/discord-rpc-gd/nodes/assets/circle.svg" +dest_files=["res://.godot/imported/circle.svg-d0b0579c9433c6250a5869daf4f70024.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/addons/discord-rpc-gd/nodes/debug.gd b/addons/discord-rpc-gd/nodes/debug.gd new file mode 100644 index 0000000..d960441 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/debug.gd @@ -0,0 +1,11 @@ +## This is a Debug Node wich will show some usefull info and buttons/input +## +## The DiscordRPC Debug Node will show info about the current values of its variables and some buttons to change them. +## +## @tutorial: https://github.com/vaporvee/discord-rpc-godot/wiki +@tool +extends Node + +func _ready() -> void: + const DebugNodeGroup: PackedScene = preload("res://addons/discord-rpc-gd/nodes/Debug.tscn") + add_child(DebugNodeGroup.instantiate()) diff --git a/addons/discord-rpc-gd/nodes/discord_autoload.gd b/addons/discord-rpc-gd/nodes/discord_autoload.gd new file mode 100644 index 0000000..cfc6e60 --- /dev/null +++ b/addons/discord-rpc-gd/nodes/discord_autoload.gd @@ -0,0 +1,13 @@ +## This is a GDscript Node wich gets automatically added as Autoload while installing the addon. +## +## It can run in the background to comunicate with Discord. +## You don't need to use it. If you remove it make sure to run [code]DiscordRPC.run_callbacks()[/code] in a [code]_process[/code] function. +## +## @tutorial: https://github.com/vaporvee/discord-rpc-godot/wiki +extends Node + +func _ready() -> void: + pass + +func _process(_delta) -> void: + DiscordRPC.run_callbacks() diff --git a/addons/discord-rpc-gd/plugin.cfg b/addons/discord-rpc-gd/plugin.cfg new file mode 100644 index 0000000..8eeeb16 --- /dev/null +++ b/addons/discord-rpc-gd/plugin.cfg @@ -0,0 +1,7 @@ +[plugin] + +name="DiscordRPC" +description="Discord RPC Plugin for GDScript in Godot" +author="vaporvee" +version="1.3.1" +script="plugin.gd" diff --git a/addons/discord-rpc-gd/plugin.gd b/addons/discord-rpc-gd/plugin.gd new file mode 100644 index 0000000..03985b6 --- /dev/null +++ b/addons/discord-rpc-gd/plugin.gd @@ -0,0 +1,56 @@ +@tool +extends EditorPlugin + +const DiscordRPCDebug = preload("res://addons/discord-rpc-gd/nodes/debug.gd") +const DiscordRPCDebug_icon = preload("res://addons/discord-rpc-gd/Debug.svg") +var loaded_DiscordRPCDebug = DiscordRPCDebug.new() +var restart_window: ConfirmationDialog = preload("res://addons/discord-rpc-gd/restart_window.tscn").instantiate() +var plugin_cfg: ConfigFile = ConfigFile.new() +const plugin_data_filename = "/plugin_data.cfg" + +func _enter_tree() -> void: + add_custom_type("DiscordRPCDebug","Node",DiscordRPCDebug,DiscordRPCDebug_icon) + get_editor_interface().get_editor_settings().settings_changed.connect(_on_editor_settings_changed) + +func _ready() -> void: + await get_tree().create_timer(0.5).timeout + plugin_cfg.load(get_editor_interface().get_editor_paths().get_data_dir() + plugin_data_filename) + if !get_editor_interface().get_editor_settings().has_setting("DiscordRPC/EditorPresence/enabled"): + get_editor_interface().get_editor_settings().set_setting("DiscordRPC/EditorPresence/enabled",plugin_cfg.get_value("Discord","editor_presence",false)) + +func _exit_tree(): + if get_editor_interface().get_editor_settings().has_setting("DiscordRPC/EditorPresence/enabled"): + get_editor_interface().get_editor_settings().erase("DiscordRPC/EditorPresence/enabled") + +func _enable_plugin() -> void: + if FileAccess.file_exists(ProjectSettings.globalize_path("res://") + "addons/discord-rpc-gd/bin/.gdignore"): + DirAccess.remove_absolute(ProjectSettings.globalize_path("res://") + "addons/discord-rpc-gd/bin/.gdignore") + add_autoload_singleton("DiscordRPCLoader","res://addons/discord-rpc-gd/nodes/discord_autoload.gd") + restart_window.connect("confirmed", save_no_restart) + restart_window.connect("canceled", save_and_restart) + get_editor_interface().popup_dialog_centered(restart_window) + print("IGNORE RED ERROR MESSAGES BEFORE THE SECOND RESTART!") + +func _disable_plugin() -> void: + remove_autoload_singleton("DiscordRPCLoader") + FileAccess.open("res://addons/discord-rpc-gd/bin/.gdignore",FileAccess.WRITE) + remove_custom_type("DiscordRPCDebug") + get_editor_interface().get_editor_settings().erase("DiscordRPC/EditorPresence/enabled") + push_warning("Please restart the editor to fully disable the DiscordRPC plugin") + +func save_and_restart() -> void: + get_editor_interface().restart_editor(true) + +func save_no_restart() -> void: + get_editor_interface().restart_editor(false) + +var editor_presence: Node +func _on_editor_settings_changed() -> void: + plugin_cfg.set_value("Discord","editor_presence",get_editor_interface().get_editor_settings().get_setting("DiscordRPC/EditorPresence/enabled")) + plugin_cfg.save(get_editor_interface().get_editor_paths().get_data_dir() + plugin_data_filename) + if ClassDB.class_exists("EditorPresence") && editor_presence == null: + editor_presence = ClassDB.instantiate("EditorPresence") + if get_editor_interface().get_editor_settings().has_setting("DiscordRPC/EditorPresence/enabled") && get_editor_interface().get_editor_settings().get_setting("DiscordRPC/EditorPresence/enabled"): + add_child(editor_presence) + else: + editor_presence.queue_free() diff --git a/addons/discord-rpc-gd/restart_window.tscn b/addons/discord-rpc-gd/restart_window.tscn new file mode 100644 index 0000000..fe229ba --- /dev/null +++ b/addons/discord-rpc-gd/restart_window.tscn @@ -0,0 +1,112 @@ +[gd_scene load_steps=8 format=3 uid="uid://byc4c6d5tpomq"] + +[ext_resource type="Texture2D" uid="uid://csl0e2px0cwc1" path="res://addons/discord-rpc-gd/Logo_V2_No_Bg.png" id="1_0svbg"] + +[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_1t7mm"] + +[sub_resource type="Theme" id="Theme_swwco"] +Button/styles/focus = SubResource("StyleBoxEmpty_1t7mm") + +[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_5vqdt"] + +[sub_resource type="Image" id="Image_qmqj5"] +data = { +"data": PackedByteArray(255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 168, 224, 224, 224, 233, 224, 224, 224, 236, 224, 224, 224, 170, 231, 231, 231, 31, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 234, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 239, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 168, 224, 224, 224, 255, 224, 224, 224, 186, 224, 224, 224, 32, 224, 224, 224, 33, 224, 224, 224, 187, 224, 224, 224, 255, 225, 225, 225, 167, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 255, 224, 224, 224, 234, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 229, 229, 229, 38, 224, 224, 224, 255, 224, 224, 224, 229, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 164, 224, 224, 224, 255, 224, 224, 224, 187, 225, 225, 225, 34, 227, 227, 227, 36, 224, 224, 224, 192, 224, 224, 224, 255, 224, 224, 224, 162, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 225, 225, 225, 215, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 229, 224, 224, 224, 32, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 224, 224, 224, 216, 224, 224, 224, 255, 224, 224, 224, 210, 224, 224, 224, 161, 224, 224, 224, 232, 224, 224, 224, 231, 225, 225, 225, 159, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 107, 224, 224, 224, 255, 224, 224, 224, 210, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 105, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 224, 224, 224, 130, 255, 255, 255, 1, 255, 255, 255, 1, 225, 225, 225, 134, 224, 224, 224, 224, 225, 225, 225, 223, 224, 224, 224, 132, 255, 255, 255, 1, 255, 255, 255, 6, 224, 224, 224, 137, 224, 224, 224, 231, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 130, 225, 225, 225, 133, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 129, 224, 224, 224, 137, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 220, 225, 225, 225, 223, 224, 224, 224, 255, 226, 226, 226, 61, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 222, 224, 224, 224, 231, 224, 224, 224, 255, 227, 227, 227, 62, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 222, 224, 224, 224, 255, 227, 227, 227, 63, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 230, 224, 224, 224, 255, 227, 227, 227, 63, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 127, 224, 224, 224, 129, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 126, 225, 225, 225, 135, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 1, 224, 224, 224, 128, 224, 224, 224, 220, 224, 224, 224, 219, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 5, 225, 225, 225, 134, 224, 224, 224, 229, 224, 224, 224, 255, 255, 255, 255, 0), +"format": "RGBA8", +"height": 16, +"mipmaps": false, +"width": 16 +} + +[sub_resource type="ImageTexture" id="ImageTexture_gdtpn"] +image = SubResource("Image_qmqj5") + +[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_7v0rg"] + +[node name="RestartWindow" type="ConfirmationDialog"] +title = "Restart required" +initial_position = 2 +size = Vector2i(430, 500) +visible = true +transient = false +unresizable = true +theme = SubResource("Theme_swwco") +ok_button_text = "Restart" +cancel_button_text = "Save and restart" + +[node name="Panel" type="Panel" parent="."] +anchors_preset = 5 +anchor_left = 0.5 +anchor_right = 0.5 +offset_left = 8.0 +offset_top = 8.0 +offset_right = 422.0 +offset_bottom = 451.0 +grow_horizontal = 2 +mouse_filter = 1 + +[node name="VBoxContainer" type="VBoxContainer" parent="Panel"] +custom_minimum_size = Vector2(400, 0) +layout_mode = 1 +anchors_preset = 5 +anchor_left = 0.5 +anchor_right = 0.5 +offset_left = -200.0 +offset_right = 200.0 +offset_bottom = 389.0 +grow_horizontal = 2 + +[node name="HSeparator" type="HSeparator" parent="Panel/VBoxContainer"] +layout_mode = 2 +mouse_filter = 1 +theme_override_constants/separation = 15 +theme_override_styles/separator = SubResource("StyleBoxEmpty_5vqdt") + +[node name="HBoxContainer" type="HBoxContainer" parent="Panel/VBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 4 +theme_override_constants/separation = 10 + +[node name="DocsIcon" type="TextureRect" parent="Panel/VBoxContainer/HBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 8 +size_flags_vertical = 4 +texture = SubResource("ImageTexture_gdtpn") +stretch_mode = 2 + +[node name="LinkButton" type="LinkButton" parent="Panel/VBoxContainer/HBoxContainer"] +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 8 +mouse_default_cursor_shape = 16 +theme_override_font_sizes/font_size = 20 +text = "HOW TO USE" +uri = "https://vaporvee.com/docs/discord-rpc-godot#quick-start" + +[node name="TextureRect" type="TextureRect" parent="Panel/VBoxContainer"] +custom_minimum_size = Vector2(128, 128) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 0 +texture = ExtResource("1_0svbg") +expand_mode = 1 + +[node name="RichTextLabel" type="RichTextLabel" parent="Panel/VBoxContainer"] +custom_minimum_size = Vector2(400, 250) +layout_mode = 2 +size_flags_horizontal = 4 +size_flags_vertical = 0 +mouse_filter = 1 +theme_override_font_sizes/normal_font_size = 16 +theme_override_styles/normal = SubResource("StyleBoxEmpty_7v0rg") +bbcode_enabled = true +text = "[center]Thanks for enabling the +[rainbow]Discord Game SDK Plugin[/rainbow] +made by vaporvee. ❤️ + + +You need to [wave]restart[/wave] the editor to fully enable this plugin! +Do you want to [wave]save[/wave] your project before restarting? + +Error messages after the first two restarts are normal. Please ignore them!" diff --git a/addons/godot-git-plugin/LICENSE b/addons/godot-git-plugin/LICENSE new file mode 100644 index 0000000..f153fb8 --- /dev/null +++ b/addons/godot-git-plugin/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2016-2023 The Godot Engine community + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/addons/godot-git-plugin/THIRDPARTY.md b/addons/godot-git-plugin/THIRDPARTY.md new file mode 100644 index 0000000..837488f --- /dev/null +++ b/addons/godot-git-plugin/THIRDPARTY.md @@ -0,0 +1,1349 @@ +# Third-Party Notices + +The Godot Git Plugin source code uses the following third-party source code: + +1. godotengine/godot-cpp - MIT License - https://github.com/godotengine/godot-cpp/tree/02336831735fd6affbe0a6fa252ec98d3e78120c +2. libgit2/libgit2 - GPLv2 with a special Linking Exception - https://github.com/libgit2/libgit2/tree/b7bad55e4bb0a285b073ba5e02b01d3f522fc95d +3. libssh2/libssh2 - BSD-3-Clause License - https://github.com/libssh2/libssh2/tree/635caa90787220ac3773c1d5ba11f1236c22eae8 + +We also link to these third-party libraries (only in the compiled binary form): + +1. OpenSSL - Only on Linux and MacOS - OpenSSL License - http://www.openssl.org/source/openssl-1.1.1s.tar.gz + +## License Texts + +### godotengine/godot-cpp + +``` +# MIT License + +Copyright (c) 2017-2022 Godot Engine contributors. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. +``` + +### libgit2/libgit2 + +``` + libgit2 is Copyright (C) the libgit2 contributors, + unless otherwise stated. See the AUTHORS file for details. + + Note that the only valid version of the GPL as far as this project + is concerned is _this_ particular version of the license (ie v2, not + v2.2 or v3.x or whatever), unless explicitly otherwise stated. + +---------------------------------------------------------------------- + + LINKING EXCEPTION + + In addition to the permissions in the GNU General Public License, + the authors give you unlimited permission to link the compiled + version of this library into combinations with other programs, + and to distribute those combinations without any restriction + coming from the use of this file. (The General Public License + restrictions do apply in other respects; for example, they cover + modification of the file, and distribution when not linked into + a combined executable.) + +---------------------------------------------------------------------- + + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) year name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. + +---------------------------------------------------------------------- + +The bundled ZLib code is licensed under the ZLib license: + +Copyright (C) 1995-2010 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +---------------------------------------------------------------------- + +The Clar framework is licensed under the ISC license: + +Copyright (c) 2011-2015 Vicent Marti + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + +---------------------------------------------------------------------- + +The regex library (deps/regex/) is licensed under the GNU LGPL +(available at the end of this file). + +Definitions for data structures and routines for the regular +expression library. + +Copyright (C) 1985,1989-93,1995-98,2000,2001,2002,2003,2005,2006,2008 +Free Software Foundation, Inc. +This file is part of the GNU C Library. + +The GNU C Library is free software; you can redistribute it and/or +modify it under the terms of the GNU Lesser General Public +License as published by the Free Software Foundation; either +version 2.1 of the License, or (at your option) any later version. + +The GNU C Library is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public +License along with the GNU C Library; if not, write to the Free +Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +02110-1301 USA. + +---------------------------------------------------------------------- + +The bundled winhttp definition files (deps/winhttp/) are licensed under +the GNU LGPL (available at the end of this file). + +Copyright (C) 2007 Francois Gouget + +This library is free software; you can redistribute it and/or +modify it under the terms of the GNU Lesser General Public +License as published by the Free Software Foundation; either +version 2.1 of the License, or (at your option) any later version. + +This library is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +Lesser General Public License for more details. + +You should have received a copy of the GNU Lesser General Public +License along with this library; if not, write to the Free Software +Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + +---------------------------------------------------------------------- + + GNU LESSER GENERAL PUBLIC LICENSE + Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + + Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software--to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages--typically libraries--of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + + GNU LESSER GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + + NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Libraries + + If you develop a new library, and you want it to be of the greatest +possible use to the public, we recommend making it free software that +everyone can redistribute and change. You can do so by permitting +redistribution under these terms (or, alternatively, under the terms of the +ordinary General Public License). + + To apply these terms, attach the following notices to the library. It is +safest to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least the +"copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library; if not, write to the Free Software + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + +Also add information on how to contact you by electronic and paper mail. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the library, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the + library `Frob' (a library for tweaking knobs) written by James Random Hacker. + + , 1 April 1990 + Ty Coon, President of Vice + +That's all there is to it! + +---------------------------------------------------------------------- + +The bundled SHA1 collision detection code is licensed under the MIT license: + +MIT License + +Copyright (c) 2017: + Marc Stevens + Cryptology Group + Centrum Wiskunde & Informatica + P.O. Box 94079, 1090 GB Amsterdam, Netherlands + marc@marc-stevens.nl + + Dan Shumow + Microsoft Research + danshu@microsoft.com + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +---------------------------------------------------------------------- + +The bundled wildmatch code is licensed under the BSD license: + +Copyright Rich Salz. +All rights reserved. + +Redistribution and use in any form are permitted provided that the +following restrictions are are met: + +1. Source distributions must retain this entire copyright notice + and comment. +2. Binary distributions must include the acknowledgement ``This + product includes software developed by Rich Salz'' in the + documentation or other materials provided with the + distribution. This must not be represented as an endorsement + or promotion without specific prior written permission. +3. The origin of this software must not be misrepresented, either + by explicit claim or by omission. Credits must appear in the + source and documentation. +4. Altered versions must be plainly marked as such in the source + and documentation and must not be misrepresented as being the + original software. + +THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED +WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. + +---------------------------------------------------------------------- + +Portions of the OpenSSL headers are included under the OpenSSL license: + +Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) +All rights reserved. + +This package is an SSL implementation written +by Eric Young (eay@cryptsoft.com). +The implementation was written so as to conform with Netscapes SSL. + +This library is free for commercial and non-commercial use as long as +the following conditions are aheared to. The following conditions +apply to all code found in this distribution, be it the RC4, RSA, +lhash, DES, etc., code; not just the SSL code. The SSL documentation +included with this distribution is covered by the same copyright terms +except that the holder is Tim Hudson (tjh@cryptsoft.com). + +Copyright remains Eric Young's, and as such any Copyright notices in +the code are not to be removed. +If this package is used in a product, Eric Young should be given attribution +as the author of the parts of the library used. +This can be in the form of a textual message at program startup or +in documentation (online or textual) provided with the package. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: +1. Redistributions of source code must retain the copyright + notice, this list of conditions and the following disclaimer. +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. +3. All advertising materials mentioning features or use of this software + must display the following acknowledgement: + "This product includes cryptographic software written by + Eric Young (eay@cryptsoft.com)" + The word 'cryptographic' can be left out if the rouines from the library + being used are not cryptographic related :-). +4. If you include any Windows specific code (or a derivative thereof) from + the apps directory (application code) you must include an acknowledgement: + "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" + +THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +SUCH DAMAGE. + +The licence and distribution terms for any publically available version or +derivative of this code cannot be changed. i.e. this code cannot simply be +copied and put under another distribution licence +[including the GNU Public Licence.] + +==================================================================== +Copyright (c) 1998-2007 The OpenSSL Project. All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in + the documentation and/or other materials provided with the + distribution. + +3. All advertising materials mentioning features or use of this + software must display the following acknowledgment: + "This product includes software developed by the OpenSSL Project + for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + +4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + endorse or promote products derived from this software without + prior written permission. For written permission, please contact + openssl-core@openssl.org. + +5. Products derived from this software may not be called "OpenSSL" + nor may "OpenSSL" appear in their names without prior written + permission of the OpenSSL Project. + +6. Redistributions of any form whatsoever must retain the following + acknowledgment: + "This product includes software developed by the OpenSSL Project + for use in the OpenSSL Toolkit (http://www.openssl.org/)" + +THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY +EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR +ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, +STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED +OF THE POSSIBILITY OF SUCH DAMAGE. +``` + +### libssh2/libssh2 + +``` +/* Copyright (c) 2004-2007 Sara Golemon + * Copyright (c) 2005,2006 Mikhail Gusarov + * Copyright (c) 2006-2007 The Written Word, Inc. + * Copyright (c) 2007 Eli Fant + * Copyright (c) 2009-2021 Daniel Stenberg + * Copyright (C) 2008, 2009 Simon Josefsson + * Copyright (c) 2000 Markus Friedl + * Copyright (c) 2015 Microsoft Corp. + * All rights reserved. + * + * Redistribution and use in source and binary forms, + * with or without modification, are permitted provided + * that the following conditions are met: + * + * Redistributions of source code must retain the above + * copyright notice, this list of conditions and the + * following disclaimer. + * + * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * Neither the name of the copyright holder nor the names + * of any other contributors may be used to endorse or + * promote products derived from this software without + * specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND + * CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, + * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE + * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY + * OF SUCH DAMAGE. + */ +``` + +### OpenSSL + +``` + + LICENSE ISSUES + ============== + + The OpenSSL toolkit stays under a double license, i.e. both the conditions of + the OpenSSL License and the original SSLeay license apply to the toolkit. + See below for the actual license texts. + + OpenSSL License + --------------- + +/* ==================================================================== + * Copyright (c) 1998-2019 The OpenSSL Project. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * + * 3. All advertising materials mentioning features or use of this + * software must display the following acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit. (http://www.openssl.org/)" + * + * 4. The names "OpenSSL Toolkit" and "OpenSSL Project" must not be used to + * endorse or promote products derived from this software without + * prior written permission. For written permission, please contact + * openssl-core@openssl.org. + * + * 5. Products derived from this software may not be called "OpenSSL" + * nor may "OpenSSL" appear in their names without prior written + * permission of the OpenSSL Project. + * + * 6. Redistributions of any form whatsoever must retain the following + * acknowledgment: + * "This product includes software developed by the OpenSSL Project + * for use in the OpenSSL Toolkit (http://www.openssl.org/)" + * + * THIS SOFTWARE IS PROVIDED BY THE OpenSSL PROJECT ``AS IS'' AND ANY + * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OpenSSL PROJECT OR + * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED + * OF THE POSSIBILITY OF SUCH DAMAGE. + * ==================================================================== + * + * This product includes cryptographic software written by Eric Young + * (eay@cryptsoft.com). This product includes software written by Tim + * Hudson (tjh@cryptsoft.com). + * + */ + + Original SSLeay License + ----------------------- + +/* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) + * All rights reserved. + * + * This package is an SSL implementation written + * by Eric Young (eay@cryptsoft.com). + * The implementation was written so as to conform with Netscapes SSL. + * + * This library is free for commercial and non-commercial use as long as + * the following conditions are aheared to. The following conditions + * apply to all code found in this distribution, be it the RC4, RSA, + * lhash, DES, etc., code; not just the SSL code. The SSL documentation + * included with this distribution is covered by the same copyright terms + * except that the holder is Tim Hudson (tjh@cryptsoft.com). + * + * Copyright remains Eric Young's, and as such any Copyright notices in + * the code are not to be removed. + * If this package is used in a product, Eric Young should be given attribution + * as the author of the parts of the library used. + * This can be in the form of a textual message at program startup or + * in documentation (online or textual) provided with the package. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * "This product includes cryptographic software written by + * Eric Young (eay@cryptsoft.com)" + * The word 'cryptographic' can be left out if the rouines from the library + * being used are not cryptographic related :-). + * 4. If you include any Windows specific code (or a derivative thereof) from + * the apps directory (application code) you must include an acknowledgement: + * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)" + * + * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * The licence and distribution terms for any publically available version or + * derivative of this code cannot be changed. i.e. this code cannot simply be + * copied and put under another distribution licence + * [including the GNU Public Licence.] + */ +``` diff --git a/addons/godot-git-plugin/git_plugin.gdextension b/addons/godot-git-plugin/git_plugin.gdextension new file mode 100644 index 0000000..49fffbf --- /dev/null +++ b/addons/godot-git-plugin/git_plugin.gdextension @@ -0,0 +1,12 @@ +[configuration] + +entry_symbol = "git_plugin_init" +compatibility_minimum = "4.1.0" + +[libraries] + +macos.editor = "macos/libgit_plugin.macos.editor.universal.dylib" +windows.editor.x86_64 = "win64/libgit_plugin.windows.editor.x86_64.dll" +linux.editor.x86_64 = "linux/libgit_plugin.linux.editor.x86_64.so" +linux.editor.arm64 = "linux/libgit_plugin.linux.editor.arm64.so" +linux.editor.rv64 = "" diff --git a/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so b/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so new file mode 100644 index 0000000..8dab6db Binary files /dev/null and b/addons/godot-git-plugin/linux/libgit_plugin.linux.editor.x86_64.so differ diff --git a/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib b/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib new file mode 100644 index 0000000..644aa2a Binary files /dev/null and b/addons/godot-git-plugin/macos/libgit_plugin.macos.editor.universal.dylib differ diff --git a/addons/godot-git-plugin/plugin.cfg b/addons/godot-git-plugin/plugin.cfg new file mode 100644 index 0000000..9c4e36f --- /dev/null +++ b/addons/godot-git-plugin/plugin.cfg @@ -0,0 +1,7 @@ +[plugin] + +name="Godot Git Plugin" +description="This plugin lets you interact with Git without leaving the Godot editor. More information can be found at https://github.com/godotengine/godot-git-plugin/wiki" +author="twaritwaikar" +version="v3.1.1" +script="godot-git-plugin.gd" diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll new file mode 100644 index 0000000..47bbb1d Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.dll differ diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp new file mode 100644 index 0000000..6c68d89 Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.exp differ diff --git a/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib new file mode 100644 index 0000000..4537929 Binary files /dev/null and b/addons/godot-git-plugin/win64/libgit_plugin.windows.editor.x86_64.lib differ diff --git a/addons/godot-git-plugin/win64/~libgit_plugin.windows.editor.x86_64.dll b/addons/godot-git-plugin/win64/~libgit_plugin.windows.editor.x86_64.dll new file mode 100644 index 0000000..47bbb1d Binary files /dev/null and b/addons/godot-git-plugin/win64/~libgit_plugin.windows.editor.x86_64.dll differ diff --git a/addons/godot-yt-dlp/LICENSE b/addons/godot-yt-dlp/LICENSE new file mode 100644 index 0000000..404a77d --- /dev/null +++ b/addons/godot-yt-dlp/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018 Noé Le Cam + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/addons/godot-yt-dlp/godot_yt_dlp.gd b/addons/godot-yt-dlp/godot_yt_dlp.gd new file mode 100644 index 0000000..ff3798d --- /dev/null +++ b/addons/godot-yt-dlp/godot_yt_dlp.gd @@ -0,0 +1,13 @@ +@tool +extends EditorPlugin + + +const AUTOLOAD_NAME = "YtDlp" + + +func _enter_tree(): + add_autoload_singleton(AUTOLOAD_NAME, "res://addons/godot-yt-dlp/src/yt_dlp.gd") + + +func _exit_tree(): + remove_autoload_singleton(AUTOLOAD_NAME) diff --git a/addons/godot-yt-dlp/plugin.cfg b/addons/godot-yt-dlp/plugin.cfg new file mode 100644 index 0000000..3637aa8 --- /dev/null +++ b/addons/godot-yt-dlp/plugin.cfg @@ -0,0 +1,7 @@ +[plugin] + +name="Godot yt-dlp" +description="A simple API for downloading videos from YouTube (and other websites)." +author="Nolkaloid" +version="3.0" +script="godot_yt_dlp.gd" diff --git a/addons/godot-yt-dlp/src/downloader.gd b/addons/godot-yt-dlp/src/downloader.gd new file mode 100644 index 0000000..15a8e19 --- /dev/null +++ b/addons/godot-yt-dlp/src/downloader.gd @@ -0,0 +1,90 @@ +extends RefCounted + +signal download_completed +signal download_failed +signal download_progressed(percentage) + +var _is_downloading: bool = false +var _headers = PackedStringArray([ + "User-Agent: Pirulo/1.0 (Godot)", + "Accept: */*" +]) + +func download(url: String, file_path: String) -> void: + if _is_downloading: + push_error(self, "A download is already in progress.") + + _is_downloading = true + + var url_regex = RegEx.new() + url_regex.compile("^(?((?https?):\\/\\/)?[^\\/]+\\.[a-z]{2,})(?(?>\\/.*)*)$") + + var host: String + var path: String + var protocol: String + + # Validate the URL + match url_regex.search(url) as RegExMatch: + null: + download_failed.emit() + return + + var result: + protocol = result.get_string("protocol") + host = result.get_string("host") + path = result.get_string("path") + + var http_client := HTTPClient.new() + http_client.connect_to_host(host, 80 if protocol == "http" else 443) + + while http_client.get_status() in [HTTPClient.STATUS_CONNECTING, HTTPClient.STATUS_RESOLVING]: + http_client.poll() + await (Engine.get_main_loop() as SceneTree).process_frame + + # Handle connection failure + if http_client.get_status() != HTTPClient.STATUS_CONNECTED: + download_failed.emit() + return + + http_client.request(HTTPClient.METHOD_GET, path, _headers) + + while not http_client.has_response(): + http_client.poll() + await (Engine.get_main_loop() as SceneTree).process_frame + + # Handle the response + match http_client.get_response_code(): + HTTPClient.RESPONSE_FOUND, HTTPClient.RESPONSE_MOVED_PERMANENTLY: + var response_headers := http_client.get_response_headers_as_dictionary() + _is_downloading = false + download(response_headers["Location"], file_path) + return + + HTTPClient.RESPONSE_OK: + await _store_body_to_file(http_client, file_path) + + _: + download_failed.emit() + return + + _is_downloading = false + download_completed.emit() + + +func _store_body_to_file(http_client: HTTPClient, file_path: String) -> void: + var file: FileAccess = FileAccess.open(file_path, FileAccess.WRITE) + var percentage_loaded: float = 0.0 + + while http_client.get_status() == HTTPClient.STATUS_BODY: + http_client.poll() + file.store_buffer(http_client.read_response_body_chunk()) + + var new_percentage = file.get_length() * 100 / http_client.get_response_body_length() + + if percentage_loaded < new_percentage: + percentage_loaded = new_percentage + download_progressed.emit(percentage_loaded) + + await (Engine.get_main_loop() as SceneTree).process_frame + + file.close() diff --git a/addons/godot-yt-dlp/src/favicon2.ico b/addons/godot-yt-dlp/src/favicon2.ico new file mode 100644 index 0000000..ff290da Binary files /dev/null and b/addons/godot-yt-dlp/src/favicon2.ico differ diff --git a/addons/godot-yt-dlp/src/yt_dlp.gd b/addons/godot-yt-dlp/src/yt_dlp.gd new file mode 100644 index 0000000..0745b63 --- /dev/null +++ b/addons/godot-yt-dlp/src/yt_dlp.gd @@ -0,0 +1,201 @@ +extends Node + +signal setup_completed +signal _update_completed + +enum Video {MP4, WEBM} +enum Audio {AAC, FLAC, MP3, M4A, OPUS, VORBIS, WAV} + +const Downloader = preload("res://addons/godot-yt-dlp/src/downloader.gd") +const yt_dlp_sources: Dictionary = { + "Linux": "https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp", + "Windows": "https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp.exe", + "macOS": "https://github.com/yt-dlp/yt-dlp/releases/latest/download/yt-dlp_macos", +} +const ffmpeg_sources: Dictionary = { + "ffmpeg": "https://github.com/Nolkaloid/godot-youtube-dl/releases/latest/download/ffmpeg.exe", + "ffprobe": "https://github.com/Nolkaloid/godot-youtube-dl/releases/latest/download/ffprobe.exe", +} + +var _downloader: Downloader +var _thread: Thread = Thread.new() +var _is_setup: bool = false + + +func is_setup() -> bool: + return _is_setup + + +func download(url: String) -> Download: + if not _is_setup: + push_error(self, "Not set up.") + return null + + return Download.new(url) + +func FilesMissing() -> bool: + var executable_name: String = "yt-dlp.exe" if OS.get_name() == "Windows" else "yt-dlp" + + if not FileAccess.file_exists("user://%s" % executable_name): + return true + if not FileAccess.file_exists("user://ffmpeg.exe"): + return true + if not FileAccess.file_exists("user://ffprobe.exe"): + return true + + return false + +func setup() -> void: + _downloader = Downloader.new() + var executable_name: String = "yt-dlp.exe" if OS.get_name() == "Windows" else "yt-dlp" + + if not FileAccess.file_exists("user://%s" % executable_name): + _downloader.download(yt_dlp_sources[OS.get_name()], "user://%s" % executable_name) + await _downloader.download_completed + else: + _thread.start(_update_yt_dlp.bind(executable_name)) + await _update_completed + # Wait for the next idle frame to join thread + await (Engine.get_main_loop() as SceneTree).process_frame + _thread.wait_to_finish() + + if OS.get_name() == "Windows": + await _setup_ffmpeg() + else: + OS.execute("chmod", PackedStringArray(["+x", OS.get_user_data_dir() + "/yt-dlp"])) + + _is_setup = true + setup_completed.emit() + + +func _setup_ffmpeg() -> void: + if not FileAccess.file_exists("user://ffmpeg.exe"): + _downloader.download(ffmpeg_sources["ffmpeg"], "user://ffmpeg.exe") + await _downloader.download_completed + + if not FileAccess.file_exists("user://ffprobe.exe"): + _downloader.download(ffmpeg_sources["ffprobe"], "user://ffprobe.exe") + await _downloader.download_completed + + +func _update_yt_dlp(filename: String) -> void: + OS.execute("%s/%s" % [OS.get_user_data_dir(), filename], ["--update"]) + _thread_finished.call_deferred(_update_completed) + + +func _thread_finished(name: Signal) -> void: + if name != null: + name.emit() + + +class Download extends RefCounted: + signal download_completed + signal completely_finished + + enum Status { + READY, + DOWNLOADING, + COMPLETED, + } + + var _status: Status = Status.READY + var _thread: Thread = null + + # Fields + var _url: String + var _destination: String = "user://" + var _file_name: String = "YOUTUBEDOWNLAOD" + var _convert_to_audio: bool = false + var _renameAudioToDiffName:bool = false + var _video_format: Video = Video.WEBM + var _audio_format: Audio = Audio.MP3 + + + func _init(url: String): + _url = url + _file_name += Time.get_datetime_string_from_system(); + + + func set_destination(destination: String) -> Download: + _destination = destination + print("destination set: " + destination) + return self + + + func set_file_name(file_name: String) -> Download: + _file_name = file_name + _renameAudioToDiffName = true + return self + + + func set_video_format(format: Video) -> Download: + _video_format = format + return self + + + func convert_to_audio(format: Audio) -> Download: + _audio_format = format + _convert_to_audio = true + return self + + + func get_status() -> Status: + return _status + + + func start() -> Download: + if not _status == Status.READY: + push_error(self, "Download previously started.") + return self + + _status = Status.DOWNLOADING + + _destination = ProjectSettings.globalize_path(_destination) + _thread = Thread.new() + _thread.start(_execute_on_thread) + reference() + return self + + + func _execute_on_thread() -> void: + var executable: String = OS.get_user_data_dir() + \ + ("/yt-dlp.exe" if OS.get_name() == "Windows" else "/yt-dlp") + + var options_and_arguments: Array = [] + + if _convert_to_audio: + var format: String = (Audio.keys()[_audio_format] as String).to_lower() + options_and_arguments.append_array(["-x", "--audio-format", format]) + else: + var format: String + + match _video_format: + Video.WEBM: + format = "bestvideo[ext=webm]+bestaudio" + Video.MP4: + format = "bestvideo[ext=mp4]+m4a" + + options_and_arguments.append_array(["--format", format]) + + + var file_path: String = "{destination}" \ + .format({ + "destination": _destination + }) + + options_and_arguments.append_array(["--yes-playlist","--embed-metadata","--embed-thumbnail",str("-o" + "%(title)s.%(ext)s")]) + options_and_arguments.append_array(["--no-continue", "-P", file_path, _url]) + + var output: Array = [] + OS.execute(executable, PackedStringArray(options_and_arguments), output) + + print(options_and_arguments) + self._thread_finished.call_deferred() + + + func _thread_finished(): + _status = Status.COMPLETED + self.download_completed.emit() + self.completely_finished.emit() + _thread.wait_to_finish() + unreference() diff --git a/cover.gd b/cover.gd new file mode 100644 index 0000000..efeafcc --- /dev/null +++ b/cover.gd @@ -0,0 +1,28 @@ +extends Sprite2D +class_name Cover +@onready var MusiMet : MusicMeta = MusicMeta.new() +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + if texture != null: + var relation:float = (float(texture.get_width()) / texture.get_height()) + print(" relation " + str(texture.get_width()) + " " + str(texture.get_height())) + print(relation) + scale.x = 400.0 / float(texture.get_width()) + scale.y = 400.0 / float(texture.get_height() * relation) + position.x = float(texture.get_width() * scale.x) / 2 + position.y = -float(texture.get_height() * scale.y) / 2 + +func ChangeCover(AudioFile:AudioStreamMP3): + texture = MusiMet.get_mp3_metadata(AudioFile).cover + if texture != null: + var relation:float = (float(texture.get_width()) / texture.get_height()) + print(" relation " + str(texture.get_width()) + " " + str(texture.get_height())) + print(relation) + scale.x = 400.0 / float(texture.get_width()) + scale.y = 400.0 / float(texture.get_height() * relation) + position.x = float(texture.get_width() * scale.x) / 2 + position.y = -float(texture.get_height() * scale.y) / 2 + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass diff --git a/create_playlists_menu.gd b/create_playlists_menu.gd new file mode 100644 index 0000000..0e7eeab --- /dev/null +++ b/create_playlists_menu.gd @@ -0,0 +1,94 @@ +extends Control +@onready var good_indicator: Label = $ScrollContainer/VBoxContainer/GoodIndicator +@onready var create_playlist_button: Button = $ScrollContainer/VBoxContainer/CreatePlaylistButton +@onready var file_dialog: FileDialog = $FileDialog +@onready var current_directory: Label = $ScrollContainer/VBoxContainer/CurrentDirectory +@onready var playlist_name: LineEdit = $ScrollContainer/VBoxContainer/PlaylistName +@onready var playlists_holder: VBoxContainer = $"../PlaylistsPanel/PlaylistsContainer/VBoxContainer/PlaylistsHolder" + +const PLAYLIST_DISPLAY = preload("res://PlaylistDisplay.tscn") + +@onready var Parent:MainScene = owner +var NameValid:bool +var DirValid:bool +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + +func IsValid(): + if NameValid: + if DirValid: + create_playlist_button.disabled = false + else: + create_playlist_button.disabled = true + else: + create_playlist_button.disabled = true + +func _on_playlist_name_text_changed(new_text: String) -> void: + #elif new_text.unicode_at() + if !Parent.Playlists.has(new_text): + if new_text != "": + good_indicator.text = "Name Valid" + good_indicator.label_settings.font_color = Color(0,1,0,1) + NameValid =true + else: + good_indicator.text = "Name needs to be something" + good_indicator.label_settings.font_color = Color(1,0,0,1) + NameValid = false + else: + good_indicator.text = "Name Already used" + good_indicator.label_settings.font_color = Color(1,0,0,1) + NameValid = false + IsValid() + + +func _on_select_dir_button_pressed() -> void: + file_dialog.show() + print(get_stack()) + + +func _on_file_dialog_dir_selected(dir: String) -> void: + if dir != "": + DirValid = true + else: + DirValid = false + current_directory.text = dir + IsValid() + +func ResetToDefault(): + playlist_name.clear() + good_indicator.text = "" + good_indicator.label_settings.font_color = Color(1,1,1,1) + NameValid = false + create_playlist_button.disabled = true + +func _on_create_playlist_button_pressed() -> void: + Parent.PlaylistsLocation[playlist_name.text] = current_directory.text + var Access = DirAccess.open(current_directory.text) + if Access != null: + @warning_ignore("static_called_on_instance") + var Read:Array = Access.get_files_at(current_directory.text) + var songs:Array + var WavDisclaimer:bool + for song:String in Read: + if song.contains(".mp3"): + songs.append(song) + Parent.Playlists[playlist_name.text] = songs + else: + Parent.Playlists[playlist_name.text] = [] + var child = PLAYLIST_DISPLAY.instantiate() + child.PlaylistName = playlist_name.text + child.PlaylistLocation = Parent.PlaylistsLocation[playlist_name.text] + child.PlaylistSongs = Parent.Playlists[playlist_name.text] + playlists_holder.add_child(child) + hide() + ResetToDefault() + + +func _on_close_button_pressed() -> void: + hide() diff --git a/d7hftxdivxxvm.cloudfront.webp b/d7hftxdivxxvm.cloudfront.webp new file mode 100644 index 0000000..ca4b40a Binary files /dev/null and b/d7hftxdivxxvm.cloudfront.webp differ diff --git a/d7hftxdivxxvm.cloudfront.webp.import b/d7hftxdivxxvm.cloudfront.webp.import new file mode 100644 index 0000000..34bf9f0 --- /dev/null +++ b/d7hftxdivxxvm.cloudfront.webp.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://cq8jj63iyu2cs" +path="res://.godot/imported/d7hftxdivxxvm.cloudfront.webp-60676cf4a861430f402d71b3c1ae3803.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://d7hftxdivxxvm.cloudfront.webp" +dest_files=["res://.godot/imported/d7hftxdivxxvm.cloudfront.webp-60676cf4a861430f402d71b3c1ae3803.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/default_bus_layout.tres b/default_bus_layout.tres new file mode 100644 index 0000000..e04bc93 --- /dev/null +++ b/default_bus_layout.tres @@ -0,0 +1,36 @@ +[gd_resource type="AudioBusLayout" load_steps=5 format=3 uid="uid://dgumj6pq4qfw7"] + +[sub_resource type="AudioEffectReverb" id="AudioEffectReverb_tqf74"] +resource_name = "Reverb" +damping = 0.42 +spread = 0.81 +dry = 0.5 + +[sub_resource type="AudioEffectEQ6" id="AudioEffectEQ6_k28ks"] +resource_name = "EQ6" + +[sub_resource type="AudioEffectCompressor" id="AudioEffectCompressor_boc1b"] +resource_name = "Compressor" +ratio = 1.0 +gain = -10.9 + +[sub_resource type="AudioEffectHardLimiter" id="AudioEffectHardLimiter_o5vtn"] +resource_name = "HardLimiter" +pre_gain_db = 4.35 +ceiling_db = -12.3 + +[resource] +bus/1/name = &"Music" +bus/1/solo = false +bus/1/mute = false +bus/1/bypass_fx = false +bus/1/volume_db = 0.0 +bus/1/send = &"Master" +bus/1/effect/0/effect = SubResource("AudioEffectReverb_tqf74") +bus/1/effect/0/enabled = false +bus/1/effect/1/effect = SubResource("AudioEffectEQ6_k28ks") +bus/1/effect/1/enabled = false +bus/1/effect/2/effect = SubResource("AudioEffectCompressor_boc1b") +bus/1/effect/2/enabled = false +bus/1/effect/3/effect = SubResource("AudioEffectHardLimiter_o5vtn") +bus/1/effect/3/enabled = false diff --git a/discord_menu.gd b/discord_menu.gd new file mode 100644 index 0000000..f1dfce6 --- /dev/null +++ b/discord_menu.gd @@ -0,0 +1,17 @@ +extends Button + + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + #await get_tree().create_timer(0.3).timeout + pass + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_toggled(toggled_on: bool) -> void: + owner.DiscordRichPresenceEnabled = toggled_on + owner.Parent.SaveEverything() diff --git a/eq_settings.gd b/eq_settings.gd new file mode 100644 index 0000000..9d05a23 --- /dev/null +++ b/eq_settings.gd @@ -0,0 +1,70 @@ +extends VBoxContainer + +var HzDec = {0:"32 Hz", + 1:"100 Hz", + 2:"320 Hz", + 3:"1000 Hz", + 4:"3200 Hz", + 5:"3200 Hz", + 6:"10000 Hz"} + +var gainValueLabels:Array = [] +var gainValueSlider:Array = [] +@onready var eq_check_box: CheckBox = $"../EQCheckBox" + +@onready var EQA:AudioEffectEQ6 = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),1) +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + for band in EQA.get_band_count(): + + var slider:HSlider = HSlider.new() + slider.min_value = -100 + slider.max_value = 20 + slider.custom_minimum_size = Vector2(200,0) + slider.name = str(band) + slider.value_changed.connect(valueChanged.bind(slider)) + + var label:Label = Label.new() + label.text = HzDec.get(band) + + var label2:Label = Label.new() + label2.text = " 0 " + + var seperator:HSplitContainer = HSplitContainer.new() + var seperator2:HSplitContainer = HSplitContainer.new() + seperator.dragger_visibility = SplitContainer.DRAGGER_HIDDEN_COLLAPSED + seperator2.dragger_visibility = SplitContainer.DRAGGER_HIDDEN_COLLAPSED + add_child(seperator) + seperator.size_flags_horizontal = Control.SIZE_SHRINK_BEGIN + + seperator.split_offset = 200 + seperator.clamp_split_offset() + + seperator.add_child(slider) + gainValueSlider.append(slider) + + seperator.add_child(seperator2) + + seperator2.add_child(label2) + gainValueLabels.append(label2) + seperator2.add_child(label) + +func valueChanged(value,slider): + var idx = slider.name.to_int() + print(idx) + print(gainValueLabels) + EQA.set_band_gain_db(idx,value) + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + for band in EQA.get_band_count(): + gainValueLabels[band].text = str(" " + str(EQA.get_band_gain_db(band)) + " db ") + + +func _on_reset_pressed() -> void: + for band in EQA.get_band_count(): + EQA.set_band_gain_db(band,0) + gainValueSlider[band].value = 0 + eq_check_box.button_pressed = false + gainValueLabels[band].text = str(" " + str(EQA.get_band_gain_db(band)) + " db ") + diff --git a/export_presets.cfg b/export_presets.cfg new file mode 100644 index 0000000..8a34eda --- /dev/null +++ b/export_presets.cfg @@ -0,0 +1,320 @@ +[preset.0] + +name="Windows Desktop" +platform="Windows Desktop" +runnable=true +advanced_options=false +dedicated_server=false +custom_features="" +export_filter="all_resources" +include_filter="" +exclude_filter="" +export_path="../MusicPlayerExports/MusicPlayer.exe" +encryption_include_filters="" +encryption_exclude_filters="" +encrypt_pck=false +encrypt_directory=false +script_export_mode=2 + +[preset.0.options] + +custom_template/debug="" +custom_template/release="" +debug/export_console_wrapper=0 +binary_format/embed_pck=false +texture_format/s3tc_bptc=true +texture_format/etc2_astc=false +binary_format/architecture="x86_64" +codesign/enable=false +codesign/timestamp=true +codesign/timestamp_server_url="" +codesign/digest_algorithm=1 +codesign/description="" +codesign/custom_options=PackedStringArray() +application/modify_resources=true +application/icon="res://addons/godot-yt-dlp/src/favicon2.ico" +application/console_wrapper_icon="res://addons/godot-yt-dlp/src/favicon2.ico" +application/icon_interpolation=4 +application/file_version="" +application/product_version="" +application/company_name="" +application/product_name="" +application/file_description="" +application/copyright="" +application/trademarks="" +application/export_angle=0 +application/export_d3d12=0 +application/d3d12_agility_sdk_multiarch=true +ssh_remote_deploy/enabled=false +ssh_remote_deploy/host="user@host_ip" +ssh_remote_deploy/port="22" +ssh_remote_deploy/extra_args_ssh="" +ssh_remote_deploy/extra_args_scp="" +ssh_remote_deploy/run_script="Expand-Archive -LiteralPath '{temp_dir}\\{archive_name}' -DestinationPath '{temp_dir}' +$action = New-ScheduledTaskAction -Execute '{temp_dir}\\{exe_name}' -Argument '{cmd_args}' +$trigger = New-ScheduledTaskTrigger -Once -At 00:00 +$settings = New-ScheduledTaskSettingsSet +$task = New-ScheduledTask -Action $action -Trigger $trigger -Settings $settings +Register-ScheduledTask godot_remote_debug -InputObject $task -Force:$true +Start-ScheduledTask -TaskName godot_remote_debug +while (Get-ScheduledTask -TaskName godot_remote_debug | ? State -eq running) { Start-Sleep -Milliseconds 100 } +Unregister-ScheduledTask -TaskName godot_remote_debug -Confirm:$false -ErrorAction:SilentlyContinue" +ssh_remote_deploy/cleanup_script="Stop-ScheduledTask -TaskName godot_remote_debug -ErrorAction:SilentlyContinue +Unregister-ScheduledTask -TaskName godot_remote_debug -Confirm:$false -ErrorAction:SilentlyContinue +Remove-Item -Recurse -Force '{temp_dir}'" +dotnet/include_scripts_content=false +dotnet/include_debug_symbols=true +dotnet/embed_build_outputs=false + +[preset.1] + +name="macOS" +platform="macOS" +runnable=true +advanced_options=false +dedicated_server=false +custom_features="" +export_filter="all_resources" +include_filter="" +exclude_filter="" +export_path="../MusicPlayerMACExports/MusicPlayer.zip" +encryption_include_filters="" +encryption_exclude_filters="" +encrypt_pck=false +encrypt_directory=false +script_export_mode=2 + +[preset.1.options] + +export/distribution_type=1 +binary_format/architecture="universal" +custom_template/debug="" +custom_template/release="" +debug/export_console_wrapper=2 +application/icon="" +application/icon_interpolation=4 +application/bundle_identifier="com.bucket.simplaudio" +application/signature="" +application/app_category="Music" +application/short_version="" +application/version="" +application/copyright="" +application/copyright_localized={} +application/min_macos_version="10.12" +application/export_angle=0 +display/high_res=true +application/additional_plist_content="" +xcode/platform_build="14C18" +xcode/sdk_version="13.1" +xcode/sdk_build="22C55" +xcode/sdk_name="macosx13.1" +xcode/xcode_version="1420" +xcode/xcode_build="14C18" +codesign/codesign=1 +codesign/installer_identity="" +codesign/apple_team_id="" +codesign/identity="" +codesign/entitlements/custom_file="" +codesign/entitlements/allow_jit_code_execution=false +codesign/entitlements/allow_unsigned_executable_memory=false +codesign/entitlements/allow_dyld_environment_variables=false +codesign/entitlements/disable_library_validation=false +codesign/entitlements/audio_input=false +codesign/entitlements/camera=false +codesign/entitlements/location=false +codesign/entitlements/address_book=false +codesign/entitlements/calendars=false +codesign/entitlements/photos_library=false +codesign/entitlements/apple_events=false +codesign/entitlements/debugging=false +codesign/entitlements/app_sandbox/enabled=false +codesign/entitlements/app_sandbox/network_server=false +codesign/entitlements/app_sandbox/network_client=false +codesign/entitlements/app_sandbox/device_usb=false +codesign/entitlements/app_sandbox/device_bluetooth=false +codesign/entitlements/app_sandbox/files_downloads=0 +codesign/entitlements/app_sandbox/files_pictures=0 +codesign/entitlements/app_sandbox/files_music=0 +codesign/entitlements/app_sandbox/files_movies=0 +codesign/entitlements/app_sandbox/files_user_selected=0 +codesign/entitlements/app_sandbox/helper_executables=[] +codesign/custom_options=PackedStringArray() +notarization/notarization=0 +privacy/microphone_usage_description="" +privacy/microphone_usage_description_localized={} +privacy/camera_usage_description="" +privacy/camera_usage_description_localized={} +privacy/location_usage_description="" +privacy/location_usage_description_localized={} +privacy/address_book_usage_description="" +privacy/address_book_usage_description_localized={} +privacy/calendar_usage_description="" +privacy/calendar_usage_description_localized={} +privacy/photos_library_usage_description="" +privacy/photos_library_usage_description_localized={} +privacy/desktop_folder_usage_description="" +privacy/desktop_folder_usage_description_localized={} +privacy/documents_folder_usage_description="" +privacy/documents_folder_usage_description_localized={} +privacy/downloads_folder_usage_description="" +privacy/downloads_folder_usage_description_localized={} +privacy/network_volumes_usage_description="" +privacy/network_volumes_usage_description_localized={} +privacy/removable_volumes_usage_description="" +privacy/removable_volumes_usage_description_localized={} +privacy/tracking_enabled=false +privacy/tracking_domains=PackedStringArray() +privacy/collected_data/name/collected=false +privacy/collected_data/name/linked_to_user=false +privacy/collected_data/name/used_for_tracking=false +privacy/collected_data/name/collection_purposes=0 +privacy/collected_data/email_address/collected=false +privacy/collected_data/email_address/linked_to_user=false +privacy/collected_data/email_address/used_for_tracking=false +privacy/collected_data/email_address/collection_purposes=0 +privacy/collected_data/phone_number/collected=false +privacy/collected_data/phone_number/linked_to_user=false +privacy/collected_data/phone_number/used_for_tracking=false +privacy/collected_data/phone_number/collection_purposes=0 +privacy/collected_data/physical_address/collected=false +privacy/collected_data/physical_address/linked_to_user=false +privacy/collected_data/physical_address/used_for_tracking=false +privacy/collected_data/physical_address/collection_purposes=0 +privacy/collected_data/other_contact_info/collected=false +privacy/collected_data/other_contact_info/linked_to_user=false +privacy/collected_data/other_contact_info/used_for_tracking=false +privacy/collected_data/other_contact_info/collection_purposes=0 +privacy/collected_data/health/collected=false +privacy/collected_data/health/linked_to_user=false +privacy/collected_data/health/used_for_tracking=false +privacy/collected_data/health/collection_purposes=0 +privacy/collected_data/fitness/collected=false +privacy/collected_data/fitness/linked_to_user=false +privacy/collected_data/fitness/used_for_tracking=false +privacy/collected_data/fitness/collection_purposes=0 +privacy/collected_data/payment_info/collected=false +privacy/collected_data/payment_info/linked_to_user=false +privacy/collected_data/payment_info/used_for_tracking=false +privacy/collected_data/payment_info/collection_purposes=0 +privacy/collected_data/credit_info/collected=false +privacy/collected_data/credit_info/linked_to_user=false +privacy/collected_data/credit_info/used_for_tracking=false +privacy/collected_data/credit_info/collection_purposes=0 +privacy/collected_data/other_financial_info/collected=false +privacy/collected_data/other_financial_info/linked_to_user=false +privacy/collected_data/other_financial_info/used_for_tracking=false +privacy/collected_data/other_financial_info/collection_purposes=0 +privacy/collected_data/precise_location/collected=false +privacy/collected_data/precise_location/linked_to_user=false +privacy/collected_data/precise_location/used_for_tracking=false +privacy/collected_data/precise_location/collection_purposes=0 +privacy/collected_data/coarse_location/collected=false +privacy/collected_data/coarse_location/linked_to_user=false +privacy/collected_data/coarse_location/used_for_tracking=false +privacy/collected_data/coarse_location/collection_purposes=0 +privacy/collected_data/sensitive_info/collected=false +privacy/collected_data/sensitive_info/linked_to_user=false +privacy/collected_data/sensitive_info/used_for_tracking=false +privacy/collected_data/sensitive_info/collection_purposes=0 +privacy/collected_data/contacts/collected=false +privacy/collected_data/contacts/linked_to_user=false +privacy/collected_data/contacts/used_for_tracking=false +privacy/collected_data/contacts/collection_purposes=0 +privacy/collected_data/emails_or_text_messages/collected=false +privacy/collected_data/emails_or_text_messages/linked_to_user=false +privacy/collected_data/emails_or_text_messages/used_for_tracking=false +privacy/collected_data/emails_or_text_messages/collection_purposes=0 +privacy/collected_data/photos_or_videos/collected=false +privacy/collected_data/photos_or_videos/linked_to_user=false +privacy/collected_data/photos_or_videos/used_for_tracking=false +privacy/collected_data/photos_or_videos/collection_purposes=0 +privacy/collected_data/audio_data/collected=false +privacy/collected_data/audio_data/linked_to_user=false +privacy/collected_data/audio_data/used_for_tracking=false +privacy/collected_data/audio_data/collection_purposes=0 +privacy/collected_data/gameplay_content/collected=false +privacy/collected_data/gameplay_content/linked_to_user=false +privacy/collected_data/gameplay_content/used_for_tracking=false +privacy/collected_data/gameplay_content/collection_purposes=0 +privacy/collected_data/customer_support/collected=false +privacy/collected_data/customer_support/linked_to_user=false +privacy/collected_data/customer_support/used_for_tracking=false +privacy/collected_data/customer_support/collection_purposes=0 +privacy/collected_data/other_user_content/collected=false +privacy/collected_data/other_user_content/linked_to_user=false +privacy/collected_data/other_user_content/used_for_tracking=false +privacy/collected_data/other_user_content/collection_purposes=0 +privacy/collected_data/browsing_history/collected=false +privacy/collected_data/browsing_history/linked_to_user=false +privacy/collected_data/browsing_history/used_for_tracking=false +privacy/collected_data/browsing_history/collection_purposes=0 +privacy/collected_data/search_hhistory/collected=false +privacy/collected_data/search_hhistory/linked_to_user=false +privacy/collected_data/search_hhistory/used_for_tracking=false +privacy/collected_data/search_hhistory/collection_purposes=0 +privacy/collected_data/user_id/collected=false +privacy/collected_data/user_id/linked_to_user=false +privacy/collected_data/user_id/used_for_tracking=false +privacy/collected_data/user_id/collection_purposes=0 +privacy/collected_data/device_id/collected=false +privacy/collected_data/device_id/linked_to_user=false +privacy/collected_data/device_id/used_for_tracking=false +privacy/collected_data/device_id/collection_purposes=0 +privacy/collected_data/purchase_history/collected=false +privacy/collected_data/purchase_history/linked_to_user=false +privacy/collected_data/purchase_history/used_for_tracking=false +privacy/collected_data/purchase_history/collection_purposes=0 +privacy/collected_data/product_interaction/collected=false +privacy/collected_data/product_interaction/linked_to_user=false +privacy/collected_data/product_interaction/used_for_tracking=false +privacy/collected_data/product_interaction/collection_purposes=0 +privacy/collected_data/advertising_data/collected=false +privacy/collected_data/advertising_data/linked_to_user=false +privacy/collected_data/advertising_data/used_for_tracking=false +privacy/collected_data/advertising_data/collection_purposes=0 +privacy/collected_data/other_usage_data/collected=false +privacy/collected_data/other_usage_data/linked_to_user=false +privacy/collected_data/other_usage_data/used_for_tracking=false +privacy/collected_data/other_usage_data/collection_purposes=0 +privacy/collected_data/crash_data/collected=false +privacy/collected_data/crash_data/linked_to_user=false +privacy/collected_data/crash_data/used_for_tracking=false +privacy/collected_data/crash_data/collection_purposes=0 +privacy/collected_data/performance_data/collected=false +privacy/collected_data/performance_data/linked_to_user=false +privacy/collected_data/performance_data/used_for_tracking=false +privacy/collected_data/performance_data/collection_purposes=0 +privacy/collected_data/other_diagnostic_data/collected=false +privacy/collected_data/other_diagnostic_data/linked_to_user=false +privacy/collected_data/other_diagnostic_data/used_for_tracking=false +privacy/collected_data/other_diagnostic_data/collection_purposes=0 +privacy/collected_data/environment_scanning/collected=false +privacy/collected_data/environment_scanning/linked_to_user=false +privacy/collected_data/environment_scanning/used_for_tracking=false +privacy/collected_data/environment_scanning/collection_purposes=0 +privacy/collected_data/hands/collected=false +privacy/collected_data/hands/linked_to_user=false +privacy/collected_data/hands/used_for_tracking=false +privacy/collected_data/hands/collection_purposes=0 +privacy/collected_data/head/collected=false +privacy/collected_data/head/linked_to_user=false +privacy/collected_data/head/used_for_tracking=false +privacy/collected_data/head/collection_purposes=0 +privacy/collected_data/other_data_types/collected=false +privacy/collected_data/other_data_types/linked_to_user=false +privacy/collected_data/other_data_types/used_for_tracking=false +privacy/collected_data/other_data_types/collection_purposes=0 +ssh_remote_deploy/enabled=false +ssh_remote_deploy/host="user@host_ip" +ssh_remote_deploy/port="22" +ssh_remote_deploy/extra_args_ssh="" +ssh_remote_deploy/extra_args_scp="" +ssh_remote_deploy/run_script="#!/usr/bin/env bash +unzip -o -q \"{temp_dir}/{archive_name}\" -d \"{temp_dir}\" +open \"{temp_dir}/{exe_name}.app\" --args {cmd_args}" +ssh_remote_deploy/cleanup_script="#!/usr/bin/env bash +kill $(pgrep -x -f \"{temp_dir}/{exe_name}.app/Contents/MacOS/{exe_name} {cmd_args}\") +rm -rf \"{temp_dir}\"" +dotnet/include_scripts_content=false +dotnet/include_debug_symbols=false +dotnet/embed_build_outputs=false diff --git a/favicon.ico b/favicon.ico new file mode 100644 index 0000000..345a61a Binary files /dev/null and b/favicon.ico differ diff --git a/gear.png b/gear.png new file mode 100644 index 0000000..743b760 Binary files /dev/null and b/gear.png differ diff --git a/gear.png.import b/gear.png.import new file mode 100644 index 0000000..3d1588a --- /dev/null +++ b/gear.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://bmew5rehygj3c" +path="res://.godot/imported/gear.png-f6667604f1a4cbb2c335db12d132f85e.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://gear.png" +dest_files=["res://.godot/imported/gear.png-f6667604f1a4cbb2c335db12d132f85e.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/icon.svg b/icon.svg new file mode 100644 index 0000000..9d8b7fa --- /dev/null +++ b/icon.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/icon.svg.import b/icon.svg.import new file mode 100644 index 0000000..ba3fe4a --- /dev/null +++ b/icon.svg.import @@ -0,0 +1,37 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ul0ylr6ec8vv" +path="res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://icon.svg" +dest_files=["res://.godot/imported/icon.svg-218a8f2b3041327d8a5756f3a245f83b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 +svg/scale=1.0 +editor/scale_with_editor_scale=false +editor/convert_colors_with_editor_theme=false diff --git a/main.gd b/main.gd new file mode 100644 index 0000000..ad9e4d1 --- /dev/null +++ b/main.gd @@ -0,0 +1,554 @@ +class_name MainScene +extends Control +@onready var file_dialog: FileDialog = $FileDialog +@onready var music_player: AudioStreamPlayer = $MusicPlayer +@onready var randomize_list: Button = $RandomizeList +@onready var play_list: Button = $playList +@onready var current_progress: HSlider = $CurrentProgress +@onready var volume_slider: VSlider = $VolumeSlider +@onready var skip: Button = $Skip +@onready var go_back: Button = $GoBack +@onready var song_name: Label = $SongName +@onready var loop: Button = $Loop +@onready var time_listening_song: Label = $TimeListeningSong +@onready var cover: Cover = $CoverHolder/Cover +@onready var wav_disclaimer: AcceptDialog = $WavDisclaimer +@onready var youtube_menu_holder: Control = $YoutubeMenuHolder +@onready var youtube_menu: Control = $"YoutubeMenuHolder/Youtube menu" +@onready var yt_link: LineEdit = $"YoutubeMenuHolder/Youtube menu/YTLink" +@onready var yt_download: Button = $"YoutubeMenuHolder/Youtube menu/YTDownload" +@onready var loading_img: Sprite2D = $"YoutubeMenuHolder/Youtube menu/LoadingIMG" +@onready var songs_menu: MenuButton = $SongsMenu +@onready var version: Label = $Version +@onready var paused_indicator: TextureRect = $PausedIndicator +@onready var settings_popup: Popup = $SettingsPopup +@onready var settings_menu_child: Settings = $SettingsPopup/SettingsMenuChild +@onready var artist_name: Label = $ArtistName +@onready var user_bg: TextureRect = $UserBG +@onready var playlists_panel: Control = $PlaylistsPanel +@onready var playlists_holder: VBoxContainer = $PlaylistsPanel/PlaylistsContainer/VBoxContainer/PlaylistsHolder +@onready var play_all: Button = $PlaylistsPanel/PlaylistsContainer/VBoxContainer/HBoxContainer/PlayAll +@onready var album_name: Label = $Album + + + +const PLAYLIST_DISPLAY = preload("res://PlaylistDisplay.tscn") +const PAUSE = preload("res://Pause.png") +const PLAY = preload("res://Play.png") + +var OpenedSong:String = "" +var CurrentIDX:int +var CurrentSongLenth:float +var CurrentDir:String +var textSongs:Array +var Randomized:bool +var LoopingSong:bool +var Paused:bool +var UpdateProgressSlider:bool = true +var ShowInstallAlerts:bool = false +var ReactivateLoop:bool +var SeenWAVDisclaimer:bool +var TimeSpentListening:float +var DiscordRichPresenceEnabled:bool = false +var SplashStrings:Array +var SaveInterval:float = 23.6 +var currentSaveTime:float = 0.4 +var CurrentPausedIndicatorShaderIntensity:float +var CurrentCustomBackroundImageDirectory:String +var Playlists:Dictionary = {} +var PlaylistsLocation:Dictionary +var BackroundSetup:bool +var CurrentPlaylist:String +var PlayAllLists:bool + +@export var LoopPressed:Texture2D +@export var LoopNotPressed:Texture2D + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + current_progress.drag_ended.connect(SongDragStopped) + current_progress.drag_started.connect(SongDragStarted) + loop.pressed.connect(LoopSong) + file_dialog.dir_selected.connect(DirectorySelected) + randomize_list.pressed.connect(Randomize) + play_list.pressed.connect(PlaySongs) + volume_slider.value_changed.connect(SetVolume) + skip.pressed.connect(Skip) + go_back.pressed.connect(GoBack) + songs_menu.get_popup().index_pressed.connect(SetSong) + var Strin:String + for Arg in OS.get_cmdline_args(): + if Arg.to_lower().ends_with(".mp3") or Arg.to_lower().ends_with(".wav"): + OS.alert("opening files like this\nis no longer supported") + var data:Dictionary + if loadUserdata() != null: + data = loadUserdata() + if Strin.is_empty(): + loadPlaylists() + if Playlists.size() != 0: + CurrentPlaylist = Playlists.keys()[0] + CurrentDir = PlaylistsLocation[Playlists.keys()[0]] + for Playlist in Playlists.keys(): + var child = PLAYLIST_DISPLAY.instantiate(PackedScene.GEN_EDIT_STATE_DISABLED) + if PlaylistsLocation.has(Playlist): + if PlaylistsLocation[Playlist] is String: + child.PlaylistLocation = PlaylistsLocation[Playlist] + else: + print("PLAYLIST LOCATION: " + str(PlaylistsLocation[Playlist])) + child.PlaylistName = Playlist + if Playlists.has(Playlist): + if Playlists[Playlist] is String: + child.PlaylistSongs = Playlists[Playlist] + playlists_holder.add_child(child) + if data != null: + if data.has("Volume"): + print(data["Volume"]) + SetVolume(data["Volume"]) + if data.has("Directory"): + if data["Directory"] != "": + DirectorySelected(data["Directory"]) + if data.has("CurrIDX"): + CurrentIDX = data["CurrIDX"] + if data.has("Randomized"): + Randomize() + if data.has("Playing"): + PlaySongs() + if data.has("SeenWAVDisclaimer"): + SeenWAVDisclaimer = data["SeenWAVDisclaimer"] + if data.has("TimeSpentListening"): + TimeSpentListening = data["TimeSpentListening"] + print("Listening time: " + str(TimeSpentListening)) + if data.has("DiscordRichPresenceEnabled"): + settings_menu_child.discord_rich_presence_button.set_pressed_no_signal(data["DiscordRichPresenceEnabled"]) + DiscordRichPresenceEnabled = data["DiscordRichPresenceEnabled"] + if data.has("ReverbEnabled") : + settings_menu_child.reverb_check.button_pressed = data["ReverbEnabled"] + if data.has("ReverbRoomSize") : + settings_menu_child.room_size_slider.value = data["ReverbRoomSize"] + if data.has("ReverbDampening") : + settings_menu_child.dampening_size_slider.value = data["ReverbDampening"] + if data.has("ReverbSpread") : + settings_menu_child.spread_size_slider.value = data["ReverbSpread"] + if data.has("CompressionEnabled") : + settings_menu_child.compression_check.button_pressed = data["CompressionEnabled"] + if data.has("CompressionThreshold") : + settings_menu_child.threshold_slider.value = data["CompressionThreshold"] + if data.has("CompressionRatio") : + settings_menu_child.ratio_slider.value = data["CompressionRatio"] + if data.has("CompressionGain") : + settings_menu_child.gain_slider.value = data["CompressionGain"] + if data.has("CurrentCustomBackroundImageDirectory"): + CurrentCustomBackroundImageDirectory = data["CurrentCustomBackroundImageDirectory"] + print("CurrentCustomBackroundImageDirectory " + CurrentCustomBackroundImageDirectory) + if data.has("PlayAllLists"): + PlayAllLists = data["PlayAllLists"] + if PlayAllLists: + play_all.button_pressed = true + else: + if data != null: + print(data["Volume"]) + SetVolume(data["Volume"]) + var TrueDir + var TheSongName = Strin + var lenght = Strin.length() + var AmoutOfSwag:int = 0 + for skibidi in lenght: + if Strin.ends_with("\\"): + AmoutOfSwag += 1 + if AmoutOfSwag ==2: + TheSongName = TheSongName.erase(0,lenght) + print(TheSongName) + break + else: + lenght -= 1 + Strin = Strin.erase(lenght) + OpenedSong = TheSongName + DirectorySelected(Strin) + PlaySongs() + #PlaySongs() + DiscordRPC.app_id = 1276916292170809426 + + DiscordRPC.refresh() + # this is boolean if everything worked + print("Discord working: " + str(DiscordRPC.get_is_discord_working())) + # Set the first custom text row of the activity here + if textSongs.has(CurrentIDX): + DiscordRPC.details = textSongs[CurrentIDX] + # Set the second custom text row of the activity here + DiscordRPC.state = "" + # Image key for small image from "Art Assets" from the Discord Developer website + DiscordRPC.large_image = "logo" + # Tooltip text for the large image + SplashStrings = ["the party just started!"] + var LText = SplashStrings.pick_random() + print(LText) + DiscordRPC.large_image_text = LText + # Image key for large image from "Art Assets" from the Discord Developer website + DiscordRPC.small_image = "" + # Tooltip text for the small image + DiscordRPC.small_image_text = "Nothing" + # "02:41 elapsed" timestamp for the activity + # Always refresh after changing the values! + DiscordRPC.refresh() + + +func SongDragStopped(Changed:bool): + if Changed: + music_player.play(current_progress.value * CurrentSongLenth / current_progress.max_value) + if Paused: + pausePlay() + UpdateProgressSlider = true + DiscordRPC.start_timestamp = int(Time.get_unix_time_from_system() - (current_progress.value * CurrentSongLenth / current_progress.max_value)) + DiscordRPC.refresh() + +func SongDragStarted(): + UpdateProgressSlider = false + + +func LoopSong(): + if LoopingSong == true: + LoopingSong = false + loop.icon = LoopNotPressed + else: + LoopingSong = true + loop.icon = LoopPressed + +func SetSong(IDX:int): + if LoopingSong: + LoopingSong = false + ReactivateLoop = true + loop.icon = LoopNotPressed + CurrentIDX = IDX -1 + PlaySongs() + music_player.stop() + SaveEverything() + print("SetSong") + +func pausePlay(): + if music_player.stream_paused == true: + music_player.stream_paused = false + else: + music_player.stream_paused = true + +func Skip(): + if LoopingSong: + LoopingSong = false + ReactivateLoop = true + loop.icon = LoopNotPressed + music_player.stop() + +func GoBack(): + if LoopingSong: + LoopingSong = false + ReactivateLoop = true + loop.icon = LoopNotPressed + CurrentIDX -=2 + music_player.stop() + +func SetVolume(Volume:float): + + var volume = (-50 + (Volume/2)) + if Volume >= 2: + AudioServer.set_bus_volume_db(0,volume) + else: + AudioServer.set_bus_volume_db(0,-1000) + print("Chnaged Volume") + SaveEverything() + volume_slider.value = Volume + +func SelectPlaylistDir(): + file_dialog.show() + SaveEverything() + print("Select Playtlist dir") + +func DirectorySelected(dir:String): + Randomized = false + print(dir) + CurrentDir = dir + GetSongs(dir) + +func PlaySongs(): + + if music_player.playing: + Paused = true + DiscordRPC.state = "Paused" + music_player.stream_paused = true + play_list.icon = PLAY + print(DiscordRPC.get_current_user()) + else: + DiscordRPC.start_timestamp = int(Time.get_unix_time_from_system() - (current_progress.value * CurrentSongLenth / current_progress.max_value)) + print(DiscordRPC.get_current_user()) + if DiscordRPC.get_current_user().get("username") == "_bucketofchicken": + DiscordRPC.state = "i made the music player btw" + else: + DiscordRPC.state = "Listening To Music" + Paused = false + music_player.stream_paused = false + play_list.icon = PAUSE + + if music_player.get_playback_position() == 0.0: + if LoopingSong: + music_player.play() + elif textSongs.size() != 0: + var index + if OpenedSong.is_empty(): + if PlayAllLists: + if CurrentIDX >= (textSongs.size()): + CurrentPlaylist = Playlists.keys()[(Playlists.keys().find(CurrentPlaylist)+1) % Playlists.keys().size()] + print("ASSS") + print(CurrentPlaylist) + index = CurrentIDX % textSongs.size() + else: + if PlayAllLists: + if CurrentIDX+1 >= (textSongs.size()-1): + CurrentPlaylist = Playlists.keys()[(Playlists.keys().find(CurrentPlaylist)+1) % Playlists.keys().size()] + print("AS") + index = textSongs.find(OpenedSong) % textSongs.size() + if PlayAllLists: + if !CurrentDir.ends_with(CurrentPlaylist): + GetSongs(PlaylistsLocation[CurrentPlaylist]) + var CurrentSongDir:String = PlaylistsLocation[CurrentPlaylist] + "/" + textSongs[index] + DiscordRPC.details = textSongs[index].replace(".mp3","") + print(CurrentSongDir) + var sonnname:String = textSongs[index] + sonnname = sonnname.replace(".mp3", "") + song_name.text = sonnname + var dat = FileAccess.get_file_as_bytes(CurrentSongDir) + var song:AudioStreamMP3 + if CurrentSongDir.to_lower().ends_with(".mp3"): + song = AudioStreamMP3.new() + cover.ChangeCover(song) + song.data = dat + if CurrentSongDir.to_lower().ends_with(".mp3"): + cover.ChangeCover(song) + print(MusicMetadataAutoload.get_mp3_metadata(song).print_info()) + if MusicMetadataAutoload.get_mp3_metadata(song).title != "": + song_name.text = MusicMetadataAutoload.get_mp3_metadata(song).title + if MusicMetadataAutoload.get_mp3_metadata(song).artist != "": + artist_name.text = MusicMetadataAutoload.get_mp3_metadata(song).artist + else: artist_name.text = "" + if MusicMetadataAutoload.get_mp3_metadata(song).album != "": + album_name.text = MusicMetadataAutoload.get_mp3_metadata(song).album + else: album_name.text = "" + if song != null: + CurrentSongLenth = song.get_length() + music_player.stream = song + music_player.play() + SaveEverything() + print("set stream") + + +func GetSongs(dir:String): + print("Selected dir: " + dir) + var Access = DirAccess.open(dir) + if Access != null: + CurrentDir = dir + @warning_ignore("static_called_on_instance") + var Read:Array = Access.get_files_at(dir) + var songs:Array + var WavDisclaimer:bool + for song:String in Read: + if song.contains(".mp3"): + songs.append(song) + elif song.contains(".wav"): + WavDisclaimer = true + + if WavDisclaimer: + if !SeenWAVDisclaimer: + wav_disclaimer.show() + SeenWAVDisclaimer = true + #print(songs) + songs_menu.get_popup().clear(true) + textSongs = songs + for song in textSongs: + var nam = song.replace(".mp3", "") + songs_menu.get_popup().add_item(nam) + +func Randomize(): + if textSongs.size() != 0: + var Access = DirAccess.open(CurrentDir) + var Read:Array = Access.get_files_at(CurrentDir) + var Ssong:String + for read:String in Read: + if textSongs.size() > CurrentIDX: + if read.contains(textSongs[CurrentIDX]): + Ssong = read + print("Ssong = " + str(read)) + textSongs.shuffle() + if Ssong != null: + CurrentIDX = textSongs.find(Ssong) # % textSongs.size() + print(CurrentIDX) + + + Randomized = true + songs_menu.get_popup().clear(true) + for song in textSongs: + var nam = song.replace(".mp3", "") + songs_menu.get_popup().add_item(nam) + #print(textSongs) + +func PlaylistSelected(Playlist:String,PlaylistLocation:String): + print(PlaylistLocation) + if Playlists.get(Playlist) == null: + printerr("PlaylistSelected(Playlist:String):: you FUCKED, no playlist found") + return + else: + CurrentPlaylist = Playlist + PlaylistsLocation[Playlist] = PlaylistLocation + print(PlaylistsLocation[Playlist]) + GetSongs(PlaylistsLocation[Playlist]) + CurrentIDX = -1 + music_player.stop() + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(_delta: float) -> void: + currentSaveTime -= _delta + if !BackroundSetup: + if CurrentCustomBackroundImageDirectory != null and CurrentCustomBackroundImageDirectory != "": + settings_menu_child._on_select_bg_dialog_file_selected(CurrentCustomBackroundImageDirectory) + BackroundSetup = true + if currentSaveTime < 0: + currentSaveTime = SaveInterval + SaveEverything() + print("yoo") + @warning_ignore("integer_division") + SplashStrings = ["Total listening time: %s!" % str(str(int(TimeSpentListening/60)/60 ) + + "h : " + str((int(TimeSpentListening) / 60) % 60) + "m : " + + str(int(TimeSpentListening) % 60) + "s"), + "Version: %s" % version.text,"🤷‍♂️","This Changes every ~20 seconds", + "hello everybody my name is %s" % DiscordRPC.get_current_user()["username"], + "wash your dishes, i know you got some","Running on %s" % OS.get_distribution_name(), + "%s is cooking" % DiscordRPC.get_current_user()["username"], "debugging" if OS.has_feature("editor") else "Release build", + "this user chose to show you all this info","Playing a Banger", + ":steamhappy:","This is a sign that crocodiles live in water", + "Space? SPACE?! SPAAAAAAAAAAAAACE!!!", + "i love gd colonge", + "listening with reverb" if settings_menu_child.reverb_check.button_pressed else + "not listening with reverb","the cake is edible", + "what a great song!","this message is useless", + "stop reading these","why are you reading these", + "hello from mars", "hello to mars","there is a fly in my room", + "yippee!","What, are they allergic to bathtubs or something"] + print(DiscordRPC.get_current_user()["username"]) + print(TimeSpentListening) + var LText = SplashStrings.pick_random() + DiscordRPC.large_image_text = LText + DiscordRPC.refresh() + # "59:59 remaining" timestamp for the activity + if music_player.playing: + TimeSpentListening += _delta + if DiscordRPC.get_current_user().get("username") == "_bucketofchicken": + DiscordRPC.state = "i made the music player btw" + else: + DiscordRPC.state = "Listening To Music" + CurrentPausedIndicatorShaderIntensity = lerp(CurrentPausedIndicatorShaderIntensity,0.0,0.1) + else: + DiscordRPC.start_timestamp = int(0) + DiscordRPC.state = "Paused" + DiscordRPC.refresh() + CurrentPausedIndicatorShaderIntensity = lerp(CurrentPausedIndicatorShaderIntensity,1.0,0.1) + if DiscordRichPresenceEnabled: + DiscordRPC.run_callbacks() + var mat:ShaderMaterial = paused_indicator.material + mat.set_shader_parameter("intensity",CurrentPausedIndicatorShaderIntensity) + var CurrentLenght:float = music_player.get_playback_position() / CurrentSongLenth * current_progress.max_value + if UpdateProgressSlider == true: + current_progress.value = CurrentLenght + #print(CurrentLenght) + @warning_ignore("integer_division") + var mins = int(music_player.get_playback_position()) / 60 + @warning_ignore("integer_division") + var Hours:String = str(mins/60) + if music_player.stream != null: + var Minutes:String = (str("0" + str(mins%60)) if !int(music_player.stream.get_length() / 60) < 10 else str(mins%60)) if (mins%60) < 10 else str(mins%60) + var Seconds:String = "0" + str(int(music_player.get_playback_position()) % 60) if int(music_player.get_playback_position()) % 60 < 10 else str(int(music_player.get_playback_position()) % 60) + time_listening_song.text = Hours + ":" + Minutes + ":" + Seconds if int(music_player.stream.get_length() /60 / 60) != 0 else Minutes + ":" + Seconds + else: + time_listening_song.text = "0:00" + #time_listening_song.text = str(music_player.get_playback_position()) + + if CurrentLenght == 0: + if LoopingSong == false: + CurrentIDX +=1 + PlaySongs() + if ReactivateLoop: + LoopingSong = true + ReactivateLoop = false + loop.icon = LoopPressed + DiscordRPC.refresh() + + + + + +func SaveEverything(): + var Data:Dictionary = { + "Version" : version.text, + "Volume" : volume_slider.value, + "Directory" : CurrentDir, + "CurrIDX" : CurrentIDX, + "Randomized" : Randomized, + "Playing" : music_player.playing, + "SeenWAVDisclaimer" : SeenWAVDisclaimer, + "TimeSpentListening" : TimeSpentListening, + "DiscordRichPresenceEnabled" : DiscordRichPresenceEnabled, + "ReverbEnabled" : settings_menu_child.reverb_check.button_pressed, + "ReverbRoomSize" : settings_menu_child.room_size_slider.value, + "ReverbDampening" : settings_menu_child.dampening_size_slider.value, + "ReverbSpread" : settings_menu_child.spread_size_slider.value, + "CompressionEnabled" : settings_menu_child.compression_check.button_pressed, + "CompressionThreshold" : settings_menu_child.threshold_slider.value , + "CompressionRatio" : settings_menu_child.ratio_slider.value , + "CompressionGain" : settings_menu_child.gain_slider.value, + "CurrentCustomBackroundImageDirectory" : CurrentCustomBackroundImageDirectory, + "PlayAllLists" : PlayAllLists + } + saveUserdata(Data) + savePlaylists() + +func savePlaylists(): + var json = JSON.new() + var file = FileAccess.open("user://playlists.dat", FileAccess.WRITE) + var file2 = FileAccess.open("user://playlistsLocation.dat", FileAccess.WRITE) + @warning_ignore("static_called_on_instance") + if !Playlists == null or !Playlists == {}: + file.store_string(str(json.stringify(Playlists))) + if !PlaylistsLocation == null or !PlaylistsLocation == {}: + file2.store_string(str(json.stringify(PlaylistsLocation))) + + +func saveUserdata(content): + var json = JSON.new() + var file = FileAccess.open("user://data.dat", FileAccess.WRITE) + @warning_ignore("static_called_on_instance") + file.store_string(Marshalls.utf8_to_base64(json.stringify(content))) + +func loadUserdata(): + var json = JSON.new() + var file = FileAccess.open("user://data.dat", FileAccess.READ) + var filetext = file.get_as_text() if file != null else null + if file != null: + var content + if json.parse_string(file.get_as_text()) != null: + content = json.parse_string(filetext) + else: + @warning_ignore("static_called_on_instance") + content = json.parse_string(Marshalls.base64_to_utf8(file.get_as_text())) + return content + else: + return null + +func loadPlaylists(): + var json = JSON.new() + var file = FileAccess.open("user://playlistsLocation.dat", FileAccess.READ) + var file2 = FileAccess.open("user://playlists.dat", FileAccess.READ) + var filetext = file.get_as_text() + print("Playlists") + print(filetext) + #print("shit " + json.parse_string(filetext)) + if file.get_as_text() != "" and file2.get_as_text() != "": + PlaylistsLocation = json.parse_string(file.get_as_text()) + Playlists = {} if json.parse_string(file2.get_as_text()) == null else json.parse_string(file2.get_as_text()) + print(PlaylistsLocation) + print(Playlists.keys()) + print("Playlists") diff --git a/new_shader.tres b/new_shader.tres new file mode 100644 index 0000000..7166e3f --- /dev/null +++ b/new_shader.tres @@ -0,0 +1,13 @@ +[gd_resource type="VisualShader" format=3 uid="uid://b1lo8i4plpumb"] + +[resource] +code = "shader_type canvas_item; +render_mode blend_mix; + + + +" +graph_offset = Vector2(-407.855, 21.2834) +mode = 1 +flags/light_only = false +nodes/fragment/0/position = Vector2(400, 160) diff --git a/nighttime-in-the-hills-henry-porter.jpg b/nighttime-in-the-hills-henry-porter.jpg new file mode 100644 index 0000000..9acdbd6 Binary files /dev/null and b/nighttime-in-the-hills-henry-porter.jpg differ diff --git a/nighttime-in-the-hills-henry-porter.jpg.import b/nighttime-in-the-hills-henry-porter.jpg.import new file mode 100644 index 0000000..cb29670 --- /dev/null +++ b/nighttime-in-the-hills-henry-porter.jpg.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://ba5wdmchyy50n" +path="res://.godot/imported/nighttime-in-the-hills-henry-porter.jpg-12f49efa0d8a6b82d27283e3b73a89fa.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://nighttime-in-the-hills-henry-porter.jpg" +dest_files=["res://.godot/imported/nighttime-in-the-hills-henry-porter.jpg-12f49efa0d8a6b82d27283e3b73a89fa.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/playlist_display.gd b/playlist_display.gd new file mode 100644 index 0000000..64a182f --- /dev/null +++ b/playlist_display.gd @@ -0,0 +1,76 @@ +extends Control +@onready var nameLabel: RichTextLabel = $HSplitContainer/VBoxContainer/Name +@onready var directory: Label = $HSplitContainer/VBoxContainer/Directory +@onready var play_button: Button = $HSplitContainer/HBoxContainer/PlayButton +@onready var file_dialog: FileDialog = $FileDialog +@onready var options_dropdown: MenuButton = $HSplitContainer/HBoxContainer/OptionsDropdown +@onready var confirmation: ConfirmationDialog = $ConfirmationDialog + +@onready var Parent:MainScene = get_tree().root.get_child(2) + +@export var Current:bool +var PlaylistLocation:String = "" +var PlaylistName:String = "" +var PlaylistSongs:Array = [] + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + CorrectlyName() + options_dropdown.get_popup().id_pressed.connect(dropdown_pressed) + +func dropdown_pressed(Idx:int): + match options_dropdown.get_popup().get_item_text(Idx): + "Change Directory": + _on_select_directory_pressed() + "Delete": + confirmation.show() + "Rename": + pass + Parent.SaveEverything() + +func Delete(): + Parent.PlaylistsLocation.erase(nameLabel.text) + Parent.Playlists.erase(nameLabel.text) + queue_free() + Parent.SaveEverything() + +func CorrectlyName(): + nameLabel.text = PlaylistName + if !PlaylistLocation == "": + directory.text = PlaylistLocation + else: + directory.text = "directory not found" + push_error("Directory not found!") + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + if Parent == null: + push_error("MisMatched REF PLAYLIST DISPLAY") + Parent = owner + if Current: + play_button.disabled = true + play_button.text = "Playing" + else: + play_button.disabled = false + play_button.text = "Play" + if Parent.CurrentPlaylist == PlaylistName: + + play_button.disabled = true + + +func _on_play_button_pressed() -> void: + Parent.PlaylistSelected(PlaylistName,PlaylistLocation) + +func _on_select_directory_pressed() -> void: + file_dialog.show() + +func _on_file_dialog_dir_selected(dir: String) -> void: + PlaylistLocation = dir + + Parent.PlaylistsLocation[PlaylistName] = PlaylistLocation + CorrectlyName() + + +func _on_confirmation_dialog_confirmed() -> void: + Delete() diff --git a/playlists_panel.gd b/playlists_panel.gd new file mode 100644 index 0000000..2141841 --- /dev/null +++ b/playlists_panel.gd @@ -0,0 +1,25 @@ +extends Control +@onready var create_playlist: Button = $PlaylistsContainer/VBoxContainer/HBoxContainer/CreatePlaylist +@onready var create_playlists_menu: Control = $"../CreatePlaylistsMenu" +@onready var play_all: Button = $PlaylistsContainer/VBoxContainer/HBoxContainer/PlayAll + + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_create_playlist_pressed() -> void: + create_playlists_menu.show() + + +func _on_play_all_toggled(toggled_on: bool) -> void: + if toggled_on: + owner.PlayAllLists = true + else: + owner.PlayAllLists = false diff --git a/project.godot b/project.godot new file mode 100644 index 0000000..f11910c --- /dev/null +++ b/project.godot @@ -0,0 +1,56 @@ +; Engine configuration file. +; It's best edited using the editor UI and not directly, +; since the parameters that go here are not all obvious. +; +; Format: +; [section] ; section goes between [] +; param=value ; assign values to parameters + +config_version=5 + +[application] + +config/name="Simplaudio" +run/main_scene="res://Main.tscn" +config/features=PackedStringArray("4.3", "Forward Plus") +run/low_processor_mode=true +boot_splash/bg_color=Color(0, 0, 0, 1) +boot_splash/image="res://BigLogo.png" +config/icon="res://Logo2.png" +config/windows_native_icon="res://addons/godot-yt-dlp/src/favicon2.ico" + +[autoload] + +YtDlp="*res://addons/godot-yt-dlp/src/yt_dlp.gd" +MusicMetadataAutoload="*res://MusicMeta-f98d7384de3e2e658dcba3f5b06fb5b57ac2c73c/MusicMeta.gd" + +[display] + +window/size/initial_position_type=3 +window/size/extend_to_title=true +window/energy_saving/keep_screen_on=false +window/stretch/mode="viewport" +window/stretch/aspect="expand" + +[dotnet] + +project/assembly_name="Simplaudio" + +[editor] + +version_control/plugin_name="GitPlugin" +version_control/autoload_on_startup=true + +[editor_plugins] + +enabled=PackedStringArray("res://addons/discord-rpc-gd/plugin.cfg", "res://addons/godot-yt-dlp/plugin.cfg") + +[rendering] + +renderer/rendering_method="gl_compatibility" +renderer/rendering_method.mobile="gl_compatibility" +textures/vram_compression/import_etc2_astc=true +environment/defaults/default_clear_color=Color(0.147672, 0.147672, 0.147672, 1) +anti_aliasing/quality/msaa_2d=2 +2d/snap/snap_2d_vertices_to_pixel=true +2d/sdf/scale=0 diff --git a/search.png b/search.png new file mode 100644 index 0000000..51cd876 Binary files /dev/null and b/search.png differ diff --git a/search.png.import b/search.png.import new file mode 100644 index 0000000..55f6b20 --- /dev/null +++ b/search.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://myq6n4bshduj" +path="res://.godot/imported/search.png-301e59f4bb897260563d2d55313ab049.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://search.png" +dest_files=["res://.godot/imported/search.png-301e59f4bb897260563d2d55313ab049.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/search_bar.gd b/search_bar.gd new file mode 100644 index 0000000..2cf081f --- /dev/null +++ b/search_bar.gd @@ -0,0 +1,63 @@ +extends LineEdit +@onready var search_results: PopupMenu = $"../SearchResults" + +var values:Dictionary = {} +var ErrorMargin:float = 0.9 +var updatetime:float = 0.5 +var currentTime:float +var TextChanged:bool +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + search_results.popup_window = false + search_results.unfocusable = true + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + currentTime -= delta + if TextChanged: + if currentTime < 0: + release_focus() + TextChanged = false + search_results.clear(true) + values.clear() + currentTime = updatetime + var _i:int = 0 + var _s:int = 0 + for song:String in owner.textSongs: + var margin:float + var fragments:Array + #print(int((text.length() / 2.0) + 0.5)) + for num in range(int((text.length() / 2.0) + 0.5)): + if text.to_lower().substr(int(num*2),2): + fragments.append(text.to_lower().substr(int(num*2),2)) + elif text.to_lower().substr(int(num*2),1): + fragments.append(text.to_lower().substr(int(num*2),1)) + var amountOfFrags:int + for fragment:String in fragments: + + if song.to_lower().containsn(fragment): + amountOfFrags +=1 + + margin = float(amountOfFrags) / fragments.size() + if margin > ErrorMargin: + search_results.add_item(song.replace(".mp3","") ) + values[_i] = _s + _i += 1 + _s += 1 + +func _on_search_results_index_pressed(index: int) -> void: + print("index " + str(index)) + owner.SetSong(values[index]) + + +func _input(event): + if (event is InputEventMouseButton) and event.pressed: + var evLocal = make_input_local(event) + if !Rect2(Vector2(0,0),Vector2(search_results.size.y+ size.y,size.x)).has_point(evLocal.position): + search_results.hide() + +func _on_text_submitted(new_text: String) -> void: + TextChanged = true + if !search_results.visible: + search_results.show() diff --git a/search_toggle.gd b/search_toggle.gd new file mode 100644 index 0000000..9e292ed --- /dev/null +++ b/search_toggle.gd @@ -0,0 +1,28 @@ +extends Button + +@onready var search_bar: LineEdit = $"../SearchBar" +@onready var songs_menu: MenuButton = $"../SongsMenu" + +@export var PressedIcon:Texture2D +@export var NotPressedIcon:Texture2D + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + search_bar.hide() + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_toggled(toggled_on: bool) -> void: + if toggled_on: + search_bar.clear() + search_bar.show() + songs_menu.hide() + icon = PressedIcon + else: + search_bar.hide() + songs_menu.show() + icon = NotPressedIcon diff --git a/select_playlist.gd b/select_playlist.gd new file mode 100644 index 0000000..b12c8b6 --- /dev/null +++ b/select_playlist.gd @@ -0,0 +1,10 @@ +extends Button +@onready var playlists_panel: Control = $"../PlaylistsPanel" + + + +func _on_toggled(toggled_on: bool) -> void: + if toggled_on: + playlists_panel.show() + else: + playlists_panel.hide() diff --git a/settings.gd b/settings.gd new file mode 100644 index 0000000..46da5e5 --- /dev/null +++ b/settings.gd @@ -0,0 +1,180 @@ +class_name Settings +extends Control +@onready var exit: Button = $Exit + +@onready var discord_rich_presence_button: CheckBox = $ScrollContainer/VBoxContainer/DiscordRichPresenceButton + +@onready var pitch_slider: HSlider = $ScrollContainer/VBoxContainer/PitchAdjustSettings/PitchSlider +@onready var pitch_value: Label = $ScrollContainer/VBoxContainer/PitchAdjustSettings/PitchAdjustSettings/PitchValue + +@onready var reverb_check: CheckBox = $ScrollContainer/VBoxContainer/ReverbCheck +@onready var room_size_slider: HSlider = $ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings/RoomSizeSlider +@onready var room_size_value: Label = $ScrollContainer/VBoxContainer/ReverbSettings/SizeAdjustSettings/PitchAdjustSettings/RoomSizeValue +@onready var dampening_size_slider: HSlider = $ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings/DampeningSizeSlider +@onready var dampening_value: Label = $ScrollContainer/VBoxContainer/ReverbSettings/DampeningAdjustSettings/DampaningAdjustSettings/DampeningValue +@onready var spread_size_slider: HSlider = $ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2/SpreadSizeSlider +@onready var spread_value: Label = $ScrollContainer/VBoxContainer/ReverbSettings/SpreadAdjustSettings2/SpreadAdjustSettings/SpreadValue + +@onready var compression_check: CheckBox = $ScrollContainer/VBoxContainer/CompressionCheck +@onready var threshold_slider: HSlider = $ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings/ThresholdSlider +@onready var threshold_value: Label = $ScrollContainer/VBoxContainer/CompressionContainer/ThresholdSettings/ThresholdSettings/ThresholdValue +@onready var ratio_slider: HSlider = $ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings/RatioSlider +@onready var ratio_value: Label = $ScrollContainer/VBoxContainer/CompressionContainer/RatioSettings/RatioSettings/RatioValue +@onready var gain_slider: HSlider = $ScrollContainer/VBoxContainer/CompressionContainer/GainSettings/GainSlider +@onready var gain_value: Label = $ScrollContainer/VBoxContainer/CompressionContainer/GainSettings/GainSettings/GainValue + +@onready var eq_settings: VBoxContainer = $ScrollContainer/VBoxContainer/EQSettings + + +@onready var Parent:MainScene = get_parent().owner + + +@onready var reverb_settings: VBoxContainer = $ScrollContainer/VBoxContainer/ReverbSettings +@onready var compression_container: VBoxContainer = $ScrollContainer/VBoxContainer/CompressionContainer + +@onready var time_listening_label: Label = $ScrollContainer/VBoxContainer/TimeListening +@onready var scroll_container: ScrollContainer = $ScrollContainer + +@onready var select_bg_dialog: FileDialog = $ScrollContainer/VBoxContainer/SelectBGDialog +@onready var backround_dir_label: Label = $ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer2/BackroundDirLabel +@onready var select_bg: Button = $ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer/SelectBG +@onready var reset_bg: Button = $ScrollContainer/VBoxContainer/VBoxContainer/HBoxContainer/ResetBG + +var CurrentBGImagePath:String + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pitch_value.text = str(pitch_slider.value) + room_size_value.text = str(room_size_slider.value) + dampening_value.text = str(dampening_size_slider.value) + spread_value.text = str(spread_size_slider.value) + ratio_value.text ="1:" + str(ratio_slider.value) + gain_value.text = str(gain_slider.value) + threshold_value.text = str(threshold_slider.value) + if reverb_check.button_pressed: + reverb_settings.show() + else: + reverb_settings.hide() + if compression_check.button_pressed: + compression_container.show() + else: + compression_container.hide() + time_listening_label.text = "Total listening time: %s!" % str(str(int(Parent.TimeSpentListening/60)/60 ) + + "h : " + str((int(Parent.TimeSpentListening) / 60) % 60) + "m : " + + str(int(Parent.TimeSpentListening) % 60) + "s") + +# VOLUME +func _on_h_slider_drag_ended(value_changed: bool) -> void: + get_parent().owner.music_player.pitch_scale = pitch_slider.value + Parent.SaveEverything() + +func _on_exit_pressed() -> void: + get_parent().hide() + Parent.SaveEverything() + +#region Reverb + +func _on_reverb_check_toggled(toggled_on: bool) -> void: + if toggled_on: + AudioServer.set_bus_effect_enabled(AudioServer.get_bus_index("Music"),0,true) + else: + AudioServer.set_bus_effect_enabled(AudioServer.get_bus_index("Music"),0,false) + Parent.SaveEverything() + + +func _on_room_size_slider_drag_ended(value_changed: bool) -> void: + var Reverb:AudioEffectReverb = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),0) + Reverb.room_size = room_size_slider.value + Parent.SaveEverything() + + +func _on_dampening_size_slider_drag_ended(value_changed: bool) -> void: + var Reverb:AudioEffectReverb = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),0) + Reverb.damping = room_size_slider.value + Parent.SaveEverything() + + +func _on_spread_size_slider_drag_ended(value_changed: bool) -> void: + var Reverb:AudioEffectReverb = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),0) + Reverb.spread = room_size_slider.value + Parent.SaveEverything() +#endregion + +#region Compression +func _on_compression_check_toggled(toggled_on: bool) -> void: + if toggled_on: + AudioServer.set_bus_effect_enabled(AudioServer.get_bus_index("Music"),2,true) + else: + AudioServer.set_bus_effect_enabled(AudioServer.get_bus_index("Music"),2,false) + Parent.SaveEverything() + +func _on_gain_slider_drag_ended(value_changed: bool) -> void: + var Compression:AudioEffectCompressor = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),2) + Compression.gain = gain_slider.value + Parent.SaveEverything() + + +func _on_ratio_slider_drag_ended(value_changed: bool) -> void: + var Compression:AudioEffectCompressor = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),2) + Compression.ratio = ratio_slider.value + Parent.SaveEverything() + + +func _on_threshold_slider_drag_ended(value_changed: bool) -> void: + var Compression:AudioEffectCompressor = AudioServer.get_bus_effect(AudioServer.get_bus_index("Music"),2) + Compression.threshold = threshold_slider.value + Parent.SaveEverything() +#endregion + +func _on_eq_check_box_toggled(toggled_on: bool) -> void: + eq_settings.visible = toggled_on + AudioServer.set_bus_effect_enabled(AudioServer.get_bus_index("Music"),1,toggled_on) + + + + +func _on_discord_rich_presence_button_toggled(toggled_on: bool) -> void: + if toggled_on: + Parent.DiscordRichPresenceEnabled = true + else: + Parent.DiscordRichPresenceEnabled = false + Parent.SaveEverything() + + +func _on_reset_pressed() -> void: + gain_slider.value = 0 + reverb_check.button_pressed = false + room_size_slider.value = 0.8 + dampening_size_slider.value = 0.8 + spread_size_slider.value = 0.8 + compression_check.button_pressed = false + threshold_slider.value = -9.15 + ratio_slider.value = 4 + gain_slider.value = 0 + pitch_slider.value = 1 + get_parent().owner.music_player.pitch_scale = 1 + + +func _on_select_bg_pressed() -> void: + select_bg_dialog.show() + Parent.SaveEverything() + + +func _on_select_bg_dialog_file_selected(path: String) -> void: + CurrentBGImagePath = path + Parent.CurrentCustomBackroundImageDirectory = path + backround_dir_label.text = path + #print(path) + Parent.user_bg.texture = ImageTexture.create_from_image(Image.load_from_file(CurrentBGImagePath)) + Parent.SaveEverything() + +func _on_reset_bg_pressed() -> void: + backround_dir_label.text = "" + Parent.user_bg.texture = null + Parent.CurrentCustomBackroundImageDirectory = "" + Parent.SaveEverything() diff --git a/settings_button.gd b/settings_button.gd new file mode 100644 index 0000000..3d11c9d --- /dev/null +++ b/settings_button.gd @@ -0,0 +1,16 @@ +extends Button + +@onready var settings_popup: Popup = $"../SettingsPopup" + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass + + +func _on_pressed() -> void: + settings_popup.show() diff --git a/settingscog.png b/settingscog.png new file mode 100644 index 0000000..7d513e0 Binary files /dev/null and b/settingscog.png differ diff --git a/settingscog.png.import b/settingscog.png.import new file mode 100644 index 0000000..2eeb65d --- /dev/null +++ b/settingscog.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://0r1tx6l1lc6x" +path="res://.godot/imported/settingscog.png-0d0e18060063e5e6c653aa68e833402b.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://settingscog.png" +dest_files=["res://.godot/imported/settingscog.png-0d0e18060063e5e6c653aa68e833402b.ctex"] + +[params] + +compress/mode=0 +compress/high_quality=false +compress/lossy_quality=0.7 +compress/hdr_compression=1 +compress/normal_map=0 +compress/channel_pack=0 +mipmaps/generate=false +mipmaps/limit=-1 +roughness/mode=0 +roughness/src_normal="" +process/fix_alpha_border=true +process/premult_alpha=false +process/normal_map_invert_y=false +process/hdr_as_srgb=false +process/hdr_clamp_exposure=false +process/size_limit=0 +detect_3d/compress_to=1 diff --git a/smallLogo.ico b/smallLogo.ico new file mode 100644 index 0000000..548749c Binary files /dev/null and b/smallLogo.ico differ diff --git a/volume_button.gd b/volume_button.gd new file mode 100644 index 0000000..16b0816 --- /dev/null +++ b/volume_button.gd @@ -0,0 +1,33 @@ +extends Button +@onready var volume_slider: VSlider = $"../VolumeSlider" +var BaseOffsetPX:int = 4 +var Target:float = 200 +var currentlyExtending:bool +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + volume_slider.hide() + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + if currentlyExtending: + volume_slider.size.y = lerp(volume_slider.size.y,Target,0.25) + else: + volume_slider.size.y -=3 + volume_slider.size.y = lerp(Target,volume_slider.size.y,1.25) + volume_slider.position.y = (BaseOffsetPX- 90) - volume_slider.size.y + (owner.size.y) + volume_slider.self_modulate.a = volume_slider.size.y / 200 + if volume_slider.size.y > 15: + volume_slider.show() + else: + volume_slider.hide() + + + +func _on_toggled(toggled_on: bool) -> void: + if toggled_on: + volume_slider.show() + currentlyExtending = true + else: + currentlyExtending = false + volume_slider.size.y = 192 diff --git a/wallpaper_manager.gd b/wallpaper_manager.gd new file mode 100644 index 0000000..e9c205d --- /dev/null +++ b/wallpaper_manager.gd @@ -0,0 +1,36 @@ +extends Node2D +@export var Daytime:Control#1 +@export var Evening:Control#2 +@export var Nighttime:Control#3 +var currentBG:int + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + pass # Replace with function body. + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + var timeInHours = Time.get_datetime_dict_from_system()["hour"] + if timeInHours < 6: + currentBG = 3 + elif timeInHours >= 6 and timeInHours <= 9: + currentBG = 2 + elif timeInHours >= 9 and timeInHours <= 17: + currentBG = 1 + elif timeInHours >= 17 and timeInHours <= 21: + currentBG = 2 + elif timeInHours > 21: + currentBG = 3 + if currentBG == 1: + Daytime.show() + Nighttime.hide() + Evening.hide() + elif currentBG == 2: + Daytime.hide() + Nighttime.hide() + Evening.show() + elif currentBG == 3: + Daytime.hide() + Nighttime.show() + Evening.hide() diff --git a/window.gd b/window.gd new file mode 100644 index 0000000..2f06cb4 --- /dev/null +++ b/window.gd @@ -0,0 +1,11 @@ +extends Window + + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + show() + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + pass diff --git a/yt_tab_button.gd b/yt_tab_button.gd new file mode 100644 index 0000000..38b3097 --- /dev/null +++ b/yt_tab_button.gd @@ -0,0 +1,72 @@ +extends Button + +@onready var youtube_menu_holder: Control = $"../YoutubeMenuHolder" +@onready var youtube_menu: Control = $"../YoutubeMenuHolder/Youtube menu" +@onready var yt_link: LineEdit = $"../YoutubeMenuHolder/Youtube menu/YTLink" +@onready var yt_download: Button = $"../YoutubeMenuHolder/Youtube menu/YTDownload" +@onready var loading_img: Sprite2D = $"../YoutubeMenuHolder/Youtube menu/LoadingIMG" +var currentlyExtending:bool +var Target:float = 50 + +# Called when the node enters the scene tree for the first time. +func _ready() -> void: + YtDlp.setup_completed.connect(YTSetupCompleted) + yt_download.pressed.connect(DownloadYTVidFromLink) + + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta: float) -> void: + if currentlyExtending: + youtube_menu.position.x = clamp(lerp(youtube_menu.position.x,Target,0.25),0,100) + else: + youtube_menu.position.x -=1 + youtube_menu.position.x = clamp(lerp(Target,youtube_menu.position.x,1.25),0,100) + youtube_menu.modulate.a = youtube_menu.position.x / Target + if youtube_menu.position.x > 1: + youtube_menu.show() + else: + youtube_menu.hide() + +func YTSetupCompleted(): + if owner.ShowInstallAlerts: + OS.alert("Youtube setup completed, from now on its safe to close the app","youtube setup") + loading_img.hide() + yt_download.disabled = false + +func DownloadYTVidFromLink(): + if yt_link.text.is_empty(): + OS.alert("please gimme a link") + return + var download:YtDlp.Download = YtDlp.download(yt_link.text) + if download == null: + OS.alert("youtube setup has not finished, please wait for the finish notification") + return + loading_img.show() + yt_link.clear() + download.set_destination(owner.PlaylistsLocation[owner.CurrentPlaylist]) + print(owner.PlaylistsLocation[owner.CurrentPlaylist]) + download.convert_to_audio(YtDlp.Audio.MP3) + download.start() + yt_download.disabled = true + download.completely_finished.connect(DownloadCompleted) + +func DownloadCompleted(): + yt_download.disabled = false + owner.GetSongs(owner.PlaylistsLocation[owner.CurrentPlaylist]) + loading_img.hide() + + +func _on_toggled(toggled_on: bool) -> void: + if !YtDlp.is_setup(): + yt_download.disabled = true + if YtDlp.FilesMissing(): + print("Need to install") + owner.ShowInstallAlerts = true + OS.alert("ONE TIME SETUP, PLEASE DONT CLOSE THE MUSIC PLAYER","yt-dl and ffmpeg setup") + YtDlp.setup() + loading_img.show() + if toggled_on: + currentlyExtending = true + youtube_menu.position.x = 1 + else: + currentlyExtending = false