diff --git a/.gdignore b/.gdignore index d8f8d46..2c49341 100644 --- a/.gdignore +++ b/.gdignore @@ -1 +1,3 @@ docs +*.md +.idea \ No newline at end of file diff --git a/README.md b/README.md index 1d62d06..23b5fbf 100644 --- a/README.md +++ b/README.md @@ -1,35 +1,9 @@ +# Dress Up Zack -# Tony's Dress Up +![](screenshot.gif)Tony's Dress Up is a re-imagining of my first (and only) Flash game series, ZC's Dress Up that was developed back in 2007. Both this and the originals are heavily inspired by The Sims 2: Body Shop in their own unique ways. -[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-v2.0%20adopted-ff69b4.svg)](CODE_OF_CONDUCT.md) - -![](screenshot.gif) - -Tony's Dress Up is a re-imagining of my first (and only) Flash game series, ZC's Dress Up , developed back in 2007. Both this and the originals are heavily inspired by The Sims 2: Body Shop in their own unique ways. - -I've included the original Flash releases in the ``/archive`` directory. They can be played using [Ruffle](https://ruffle.rs/)'s demo page. -​ - -## Getting Started - -### Prerequisites - -- Godot Engine 3.2 LTS or later - -## Authors - -* **Tony Bark** - *Initial work* - [tonytins](https://github.com/tonytins) -* **Kenney** - *UI* - [kenny.nl](https://www.kenney.nl/) -* **Twemoji** - *Emojis* - [twemoji.twitter.com](https://twemoji.twitter.com/) -* **Font Awesome** - *Icons* - [FortAwesome](https://github.com/FortAwesome) - ​ - ## License -The source and assets are licensed under the Artistic-2.0 License and CC-BY, respectfully - see the [LICENSE](LICENSE) and [ASSET-LICENSE](ASSET-LICENSE) for more details. +The source and assets are licensed under the GPL-3.0 License and CC-BY, respectfully - see the [LICENSE](LICENSE) and [ASSET-LICENSE](ASSET-LICENSE) for more details. -The Flash games included are closed source, but considered abandonware. Feel free to share them on archives. - -## Code of Conduct - -Please note that this project is released with a [Contributor Code of Conduct](CODE_OF_CONDUCT.md). By participating in this project you agree to abide by its terms. \ No newline at end of file +The Flash games located in the `/archive` directory are proprietary, but considered abandonware. Any extracted assets are under the same license. Feel free to share them on archives. diff --git a/godot.png b/godot.png new file mode 100644 index 0000000..c98fbb6 Binary files /dev/null and b/godot.png differ diff --git a/godot.png.import b/godot.png.import new file mode 100644 index 0000000..ca63310 --- /dev/null +++ b/godot.png.import @@ -0,0 +1,34 @@ +[remap] + +importer="texture" +type="CompressedTexture2D" +uid="uid://d1hpnolu3m1ho" +path="res://.godot/imported/godot.png-5e0da45ed3d6786d5794553e04f58a8c.ctex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://godot.png" +dest_files=["res://.godot/imported/godot.png-5e0da45ed3d6786d5794553e04f58a8c.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/lang/local.csv b/lang/local.csv deleted file mode 100644 index b6e6f0c..0000000 --- a/lang/local.csv +++ /dev/null @@ -1,20 +0,0 @@ -,en,sv -KENG,English,Engelsk -KSWD,Swedish,Svenska -KBOT,Pants,Byxor -KTOP,Shirts,Skjorta -KCLS,Classic,Klassisk -KUND,Underwear,Underkläder -KRUS,Resume,Återuppta -KPUS,Paused,Pausad -KMUS,Music,Musik -KGMO,Game Mode,Spelläge -KCRE,Credits,Eftertexter -KABO,About,Handla om -KLIC,License,Licens -KSOO,Coming Soon,Kommer snart -KPLY,Play,Spela -KEXT,Exit,Utgång -KHELP,Help,Hjälp -KSET,Settings,Inställningar -KLANG,Languages,Språk \ No newline at end of file diff --git a/lang/local.csv.import b/lang/local.csv.import deleted file mode 100644 index 93edbc0..0000000 --- a/lang/local.csv.import +++ /dev/null @@ -1,17 +0,0 @@ -[remap] - -importer="csv_translation" -type="Translation" -uid="uid://bdu3ytca7lxbp" - -[deps] - -files=["res://lang/local.en.translation", "res://lang/local.sv.translation"] - -source_file="res://lang/local.csv" -dest_files=["res://lang/local.en.translation", "res://lang/local.sv.translation"] - -[params] - -compress=true -delimiter=0 diff --git a/lang/local.en.translation b/lang/local.en.translation deleted file mode 100644 index 4126200..0000000 Binary files a/lang/local.en.translation and /dev/null differ diff --git a/lang/local.sv.translation b/lang/local.sv.translation deleted file mode 100644 index 280579b..0000000 Binary files a/lang/local.sv.translation and /dev/null differ diff --git a/project.godot b/project.godot index fc580d5..892762c 100644 --- a/project.godot +++ b/project.godot @@ -10,7 +10,7 @@ config_version=5 [application] -config/name="Zack's Dress Up" +config/name="Dress Up Zack" config/version="1.3.100a" run/main_scene="res://scenes/game.tscn" config/use_custom_user_dir=true @@ -22,6 +22,10 @@ config/macos_native_icon="res://icon.icns" config/windows_native_icon="res://icon.ico" name_sv="Tonys klä upp" +[autoload] + +Global="*res://scripts/global.gd" + [debug] gdscript/completion/autocomplete_setters_and_getters=true @@ -37,6 +41,17 @@ window/energy_saving/keep_screen_on=false enabled=PackedStringArray("res://addons/SpritesheetGenerator/plugin.cfg", "res://addons/fontawesome/plugin.cfg") +[file_customization] + +folder_colors={ +"res://addons/": "blue", +"res://resources/": "orange", +"res://scenes/": "purple", +"res://scripts/": "green", +"res://sounds/": "pink", +"res://sprites/": "yellow" +} + [importer_defaults] texture={ @@ -71,6 +86,11 @@ ui_pause={ "events": [Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":11,"pressure":0.0,"pressed":false,"script":null) ] } +click={ +"deadzone": 0.5, +"events": [Object(InputEventMouseButton,"resource_local_to_scene":false,"resource_name":"","device":-1,"window_id":0,"alt_pressed":false,"shift_pressed":false,"ctrl_pressed":false,"meta_pressed":false,"button_mask":0,"position":Vector2(0, 0),"global_position":Vector2(0, 0),"factor":1.0,"button_index":1,"canceled":false,"pressed":false,"double_click":false,"script":null) +] +} [locale] @@ -79,6 +99,7 @@ translations=PackedStringArray("res://lang/local.en.translation", "res://lang/lo [rendering] +renderer/rendering_method="mobile" environment/defaults/default_environment="res://default_env.tres" quality/driver/driver_name="GLES2" quality/intended_usage/framebuffer_allocation=0 diff --git a/scenes/character.tscn b/scenes/character.tscn index 29fee6c..2d8cc3e 100644 --- a/scenes/character.tscn +++ b/scenes/character.tscn @@ -1,13 +1,12 @@ -[gd_scene load_steps=33 format=3 uid="uid://detf8uwimqp3v"] +[gd_scene load_steps=32 format=3 uid="uid://detf8uwimqp3v"] -[ext_resource type="Texture2D" uid="uid://dkch263ayirr7" path="res://sprites/character/shadow.svg" id="1"] [ext_resource type="Texture2D" uid="uid://cddou4chwo8h2" path="res://sprites/character/tail/tail0.svg" id="2"] [ext_resource type="Texture2D" uid="uid://cnd3v8cerplqq" path="res://sprites/character/tail/tail1.svg" id="3"] [ext_resource type="Texture2D" uid="uid://djv0p7rxujbd4" path="res://sprites/character/tail/tail2.svg" id="4"] [ext_resource type="Texture2D" uid="uid://cardxswmgbmbv" path="res://sprites/clothes/owo_censor.svg" id="5"] [ext_resource type="Texture2D" uid="uid://dnwdyi2d46hsm" path="res://sprites/character/eyes/eyes1.png" id="6"] [ext_resource type="Texture2D" uid="uid://cbr37emgh11is" path="res://sprites/character/eyes/eyes2.png" id="7"] -[ext_resource type="Script" path="res://scripts/clothing/clothing.gd" id="7_58p8d"] +[ext_resource type="Script" path="res://scripts/clothing.gd" id="7_58p8d"] [ext_resource type="Texture2D" uid="uid://ceifal0sxn0r7" path="res://sprites/character/eyes/eyes3.png" id="8"] [ext_resource type="Texture2D" uid="uid://dujbine82hf7h" path="res://sprites/character/eyes/eyes4.png" id="9"] [ext_resource type="Texture2D" uid="uid://cbptix4hhenyv" path="res://sprites/character/eyes/eyes5.png" id="10"] @@ -126,11 +125,6 @@ position = Vector2(-19, -92) [node name="Click" type="AudioStreamPlayer" parent="."] stream = ExtResource("24") -[node name="Shadow" type="Sprite2D" parent="."] -position = Vector2(4.84271, 244.714) -texture = ExtResource("1") -metadata/_edit_lock_ = true - [node name="Body" type="Node2D" parent="."] [node name="Tail" type="AnimatedSprite2D" parent="Body"] diff --git a/scenes/demo.tscn b/scenes/demo.tscn new file mode 100644 index 0000000..b748110 --- /dev/null +++ b/scenes/demo.tscn @@ -0,0 +1,15 @@ +[gd_scene load_steps=3 format=3 uid="uid://bguec0ft5ygk4"] + +[ext_resource type="PackedScene" uid="uid://bvbelmb6rvy4f" path="res://scenes/platform.tscn" id="1_31w52"] +[ext_resource type="PackedScene" uid="uid://dn152ouc7l21p" path="res://scenes/object.tscn" id="2_cgl4f"] + +[node name="Demo" type="Node2D"] + +[node name="Platform" parent="." instance=ExtResource("1_31w52")] +position = Vector2(94, 117) + +[node name="Platform2" parent="." instance=ExtResource("1_31w52")] +position = Vector2(419, 84) + +[node name="Object" parent="." instance=ExtResource("2_cgl4f")] +position = Vector2(96, 117) diff --git a/scenes/game.tscn b/scenes/game.tscn index 424452e..2ef578d 100644 --- a/scenes/game.tscn +++ b/scenes/game.tscn @@ -1,29 +1,35 @@ -[gd_scene load_steps=7 format=3 uid="uid://cvr2aries2lhr"] +[gd_scene load_steps=8 format=3 uid="uid://cvr2aries2lhr"] [ext_resource type="Texture2D" uid="uid://33g80p0qnfw4" path="res://sprites/world/background.svg" id="1_uee2i"] [ext_resource type="Texture2D" uid="uid://bi7ayrxnn7hex" path="res://sprites/clothes/icrazy_frame.svg" id="2_n1kmf"] +[ext_resource type="Texture2D" uid="uid://cmv58t1dfgsov" path="res://sprites/world/stand.svg" id="2_q0w7j"] [ext_resource type="Texture2D" uid="uid://dteiup73cqn4o" path="res://sprites/clothes/lights.png" id="3_bbsyl"] -[ext_resource type="Script" path="res://scripts/interface.gd" id="4_pqv2p"] +[ext_resource type="Script" path="res://scripts/gui.gd" id="4_pqv2p"] [ext_resource type="PackedScene" uid="uid://crwoe1shep3qn" path="res://scenes/wardrobe.tscn" id="5_4le6a"] [ext_resource type="PackedScene" uid="uid://detf8uwimqp3v" path="res://scenes/character.tscn" id="6_tdil0"] [node name="Game" type="Node"] [node name="Background" type="Sprite2D" parent="."] -position = Vector2(504.046, 202.426) +position = Vector2(400, 240) texture = ExtResource("1_uee2i") metadata/_edit_lock_ = true +[node name="Stand" type="Sprite2D" parent="."] +position = Vector2(125, 461) +scale = Vector2(1.28991, 1.3328) +texture = ExtResource("2_q0w7j") + [node name="PictureFrame" type="Sprite2D" parent="."] -position = Vector2(127.602, 111.895) +position = Vector2(107.454, 127.574) texture = ExtResource("2_n1kmf") -metadata/_edit_lock_ = true [node name="Light3D" type="PointLight2D" parent="PictureFrame"] position = Vector2(35.118, -14.56) texture = ExtResource("3_bbsyl") +metadata/_edit_lock_ = true -[node name="Container" type="Control" parent="."] +[node name="GUI" type="Control" parent="."] layout_mode = 3 anchors_preset = 15 anchor_right = 1.0 @@ -33,24 +39,31 @@ grow_vertical = 2 script = ExtResource("4_pqv2p") metadata/_edit_lock_ = true -[node name="Wardrobe" parent="Container" instance=ExtResource("5_4le6a")] -layout_mode = 0 -anchors_preset = 0 -anchor_left = 0.33875 -anchor_top = 0.054 -anchor_right = 1.05 -anchor_bottom = 0.9 -offset_right = 6.10352e-05 +[node name="Wardrobe" parent="GUI" instance=ExtResource("5_4le6a")] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.30125 +anchor_top = 0.086 +anchor_right = 1.0125 +anchor_bottom = 0.932 +offset_right = 3.8147e-05 +offset_bottom = 1.19209e-05 grow_horizontal = 1 grow_vertical = 1 +metadata/_edit_use_anchors_ = true -[node name="VersionLbl" type="Label" parent="Container"] -layout_mode = 0 -anchor_left = 0.88125 -anchor_top = 0.944 -anchor_right = 0.9825 -anchor_bottom = 0.984 +[node name="VersionLbl" type="Label" parent="GUI"] +layout_mode = 1 +anchors_preset = -1 +anchor_left = 0.89 +anchor_top = 0.942 +anchor_right = 0.99125 +anchor_bottom = 0.994 +offset_left = -1.90735e-05 +offset_right = -1.33514e-05 +offset_bottom = -3.0 text = "0.0.0" +metadata/_edit_use_anchors_ = true [node name="Character" parent="." instance=ExtResource("6_tdil0")] -position = Vector2(120, 213) +position = Vector2(127, 218) diff --git a/scenes/object.tscn b/scenes/object.tscn new file mode 100644 index 0000000..ba1d9e2 --- /dev/null +++ b/scenes/object.tscn @@ -0,0 +1,24 @@ +[gd_scene load_steps=4 format=3 uid="uid://dn152ouc7l21p"] + +[ext_resource type="Texture2D" uid="uid://d1hpnolu3m1ho" path="res://godot.png" id="1_jjr7w"] +[ext_resource type="Script" path="res://scripts/object.gd" id="1_tyfcj"] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_py2o1"] +size = Vector2(59, 59) + +[node name="Object" type="Node2D"] +script = ExtResource("1_tyfcj") + +[node name="Sprite2D" type="Sprite2D" parent="."] +texture = ExtResource("1_jjr7w") + +[node name="Area2D" type="Area2D" parent="."] + +[node name="CollisionShape2D" type="CollisionShape2D" parent="Area2D"] +position = Vector2(0.5, -0.5) +shape = SubResource("RectangleShape2D_py2o1") + +[connection signal="body_entered" from="Area2D" to="." method="_on_area_2d_body_entered"] +[connection signal="body_exited" from="Area2D" to="." method="_on_area_2d_body_exited"] +[connection signal="mouse_entered" from="Area2D" to="." method="_on_area_2d_mouse_entered"] +[connection signal="mouse_exited" from="Area2D" to="." method="_on_area_2d_mouse_exited"] diff --git a/scenes/platform.tscn b/scenes/platform.tscn new file mode 100644 index 0000000..6a35e5b --- /dev/null +++ b/scenes/platform.tscn @@ -0,0 +1,26 @@ +[gd_scene load_steps=3 format=3 uid="uid://bvbelmb6rvy4f"] + +[ext_resource type="Script" path="res://scripts/platform.gd" id="1_xgdk6"] + +[sub_resource type="RectangleShape2D" id="RectangleShape2D_ieyrm"] +size = Vector2(62, 61) + +[node name="Platform" type="StaticBody2D"] +script = ExtResource("1_xgdk6") + +[node name="ColorRect" type="ColorRect" parent="."] +anchors_preset = 8 +anchor_left = 0.5 +anchor_top = 0.5 +anchor_right = 0.5 +anchor_bottom = 0.5 +offset_left = -31.0 +offset_top = -31.0 +offset_right = 31.0 +offset_bottom = 30.0 +grow_horizontal = 2 +grow_vertical = 2 + +[node name="CollisionShape2D" type="CollisionShape2D" parent="."] +position = Vector2(0, -0.5) +shape = SubResource("RectangleShape2D_ieyrm") diff --git a/scenes/wardrobe.tscn b/scenes/wardrobe.tscn index 8e45cc8..34dfedd 100644 --- a/scenes/wardrobe.tscn +++ b/scenes/wardrobe.tscn @@ -1,6 +1,6 @@ [gd_scene load_steps=3 format=3 uid="uid://crwoe1shep3qn"] -[ext_resource type="Script" path="res://scripts/clothing/clothing.gd" id="2_1si7t"] +[ext_resource type="Script" path="res://scripts/clothing.gd" id="2_1si7t"] [ext_resource type="Texture2D" uid="uid://405burxtvied" path="res://sprites/clothes/sweat_pants.svg" id="3_h6yd3"] [node name="Wordrobe" type="TabContainer"] diff --git a/scripts/clothing/clothing.gd b/scripts/clothing.gd similarity index 94% rename from scripts/clothing/clothing.gd rename to scripts/clothing.gd index 4e3dccb..2bfe0df 100644 --- a/scripts/clothing/clothing.gd +++ b/scripts/clothing.gd @@ -1,4 +1,4 @@ -# This project is licensed under the Artistic-2.0 license. +# This project is licensed under the GPL-3.0 license. # See the LICENSE file in the project root for more information. extends TextureRect diff --git a/scripts/global.gd b/scripts/global.gd new file mode 100644 index 0000000..22d4120 --- /dev/null +++ b/scripts/global.gd @@ -0,0 +1,5 @@ +# This project is licensed under the GPL-3.0 license. +# See the LICENSE file in the project root for more information. +extends Node + +var is_dragging = false diff --git a/scripts/interface.gd b/scripts/gui.gd similarity index 72% rename from scripts/interface.gd rename to scripts/gui.gd index c8305f3..8b2784a 100644 --- a/scripts/interface.gd +++ b/scripts/gui.gd @@ -1,4 +1,4 @@ -# This project is licensed under the Artistic-2.0 license. +# This project is licensed under the GPL-3.0 license. # See the LICENSE file in the project root for more information. extends Control @@ -6,5 +6,3 @@ func _ready(): var version = ProjectSettings.get_setting("application/config/version") var verLabel = $VersionLbl verLabel.text = "v" + version - GameData.version = version - diff --git a/scripts/news_window.gd b/scripts/news_window.gd deleted file mode 100644 index 69707f1..0000000 --- a/scripts/news_window.gd +++ /dev/null @@ -1,19 +0,0 @@ -extends Window - -@onready var news_list = $News -@onready var http_request = $NewsBtns/HTTPRequest - -func _on_HTTPRequest_request_completed(result, response_code, headers, body): - var test_json_conv = JSON.new() - test_json_conv.parse(body.get_string_from_utf8()) - var api_request = test_json_conv.get_data() - - if api_request["feed"] != null: - var news_items = api_request["feed"] - - for news in news_items: - news_list.add_item(news) - -func _on_SyncBtn_pressed(): - news_list.clear() - http_request.request(GameData.NEWS_API) diff --git a/scripts/object.gd b/scripts/object.gd new file mode 100644 index 0000000..8c270f1 --- /dev/null +++ b/scripts/object.gd @@ -0,0 +1,41 @@ +# This project is licensed under the GPL-3.0 license. +# See the LICENSE file in the project root for more information. +extends Node2D + +var is_draggable = false +var is_inside_dropable = false +var body_ref + +# Called every frame. 'delta' is the elapsed time since the previous frame. +func _process(delta): + if is_draggable: + if Input.is_action_just_pressed("click"): + global_position = get_global_mouse_position() + elif Input.is_action_just_released("click"): + is_draggable = false + var tween = get_tree().create_tween() + if is_inside_dropable: + tween.tween_property(self,"postion",body_ref.position,0.2).set_ease(Tween.EASE_OUT) + else: + tween.tween_property(self,"global_postion",body_ref.position,0.2).set_ease(Tween.EASE_OUT) + +func _on_area_2d_body_entered(body): + if body.is_in_group('dropable'): + is_inside_dropable = true + scale = Vector2(1.05, 1.05) + +func _on_area_2d_body_exited(body:StaticBody2D): + if body.is_in_group('dropable'): + is_inside_dropable = false + scale = Vector2(1.05, 1.05) + + +func _on_area_2d_mouse_entered(): + if not Global.is_dragging: + is_draggable = true + scale = Vector2(1.05, 1.05) + +func _on_area_2d_mouse_exited(): + if not Global.is_dragging: + is_draggable = false + scale = Vector2(1, 1) diff --git a/scripts/platform.gd b/scripts/platform.gd new file mode 100644 index 0000000..414ae85 --- /dev/null +++ b/scripts/platform.gd @@ -0,0 +1,12 @@ +# This project is licensed under the GPL-3.0 license. +# See the LICENSE file in the project root for more information. +extends StaticBody2D + +func _ready(): + modulate = Color(Color.MEDIUM_PURPLE, 0.7) + +func _process(delta): + if Global.is_dragging: + visible = true + else: + visible = false diff --git a/scripts/spinner.gd b/scripts/spinner.gd deleted file mode 100644 index 9665d8b..0000000 --- a/scripts/spinner.gd +++ /dev/null @@ -1,15 +0,0 @@ -# This project is licensed under the Artistic-2.0 license. -# See the LICENSE file in the project root for more information. -extends TextureRect - -@onready var timer = $Timer - -func _ready(): - GameEvents.connect("indicate",Callable(self,"_on_indicate")) - -func _on_indicate(): - show() - timer.start() - -func _on_Timer_timeout(): - hide() diff --git a/sprites/pawprint-logo.svg b/sprites/pawprint-logo.svg deleted file mode 100644 index 94024e5..0000000 --- a/sprites/pawprint-logo.svg +++ /dev/null @@ -1,165 +0,0 @@ - - - - - - - - image/svg+xml - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/sprites/world/stand.svg b/sprites/world/stand.svg new file mode 100644 index 0000000..cdcbc45 --- /dev/null +++ b/sprites/world/stand.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/sprites/pawprint-logo.svg.import b/sprites/world/stand.svg.import similarity index 71% rename from sprites/pawprint-logo.svg.import rename to sprites/world/stand.svg.import index 6ee89fa..204f139 100644 --- a/sprites/pawprint-logo.svg.import +++ b/sprites/world/stand.svg.import @@ -2,16 +2,16 @@ importer="texture" type="CompressedTexture2D" -uid="uid://puxix2j7nxuo" -path="res://.godot/imported/pawprint-logo.svg-01cd6ea8ad71ffb3d0348f6c08c67cda.ctex" +uid="uid://cmv58t1dfgsov" +path="res://.godot/imported/stand.svg-0de4e9ed6224f150f86cc1ed49481da1.ctex" metadata={ "vram_texture": false } [deps] -source_file="res://sprites/pawprint-logo.svg" -dest_files=["res://.godot/imported/pawprint-logo.svg-01cd6ea8ad71ffb3d0348f6c08c67cda.ctex"] +source_file="res://sprites/world/stand.svg" +dest_files=["res://.godot/imported/stand.svg-0de4e9ed6224f150f86cc1ed49481da1.ctex"] [params]