Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
34 changes: 34 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/capa.png.import
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://o8yio6hun0y"
path="res://.godot/imported/capa.png-cf3a22f11469a5bf8a64e104de28568e.ctex"
metadata={
"vram_texture": false
}

[deps]

source_file="res://microjogos/2023S1/projeto_luiscolosimo/capa.png"
dest_files=["res://.godot/imported/capa.png-cf3a22f11469a5bf8a64e104de28568e.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
1 change: 1 addition & 0 deletions microjogos/2023S1/projeto_luiscolosimo/cenas/cenas.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Coloque suas cenas aqui! A cena que vai rodar no jogo deve necessariamente ser a Main.tscn
96 changes: 96 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/cenas/main.tscn
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
[gd_scene load_steps=14 format=3 uid="uid://byy1uildj3qlc"]

[ext_resource type="Script" uid="uid://dmwmle1cf2c8b" path="res://microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/main.gd" id="1"]
[ext_resource type="Script" uid="uid://cxqdy2h0a8wof" path="res://microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/child.gd" id="4_pr0bi"]
[ext_resource type="Script" uid="uid://b1cmsggk4uyc" path="res://microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/Mira.gd" id="4_r5nct"]
[ext_resource type="Texture2D" uid="uid://cpg8tbco0w1vu" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/character/child-feliz.png" id="5_oga73"]
[ext_resource type="Texture2D" uid="uid://cpmtgkkxxq46d" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/character/child1.png" id="5_xappj"]
[ext_resource type="Texture2D" uid="uid://bbifbfygrl3ck" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/dedo.png" id="6_rsfoc"]
[ext_resource type="Texture2D" uid="uid://bt3ua0mlh0uei" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/pedra1.png" id="8_8ymq0"]
[ext_resource type="Texture2D" uid="uid://dk40vxf34co6l" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/background.png" id="8_l8pfv"]
[ext_resource type="Texture2D" uid="uid://dtae61v0j12cy" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/planta1.png" id="9_npe7l"]
[ext_resource type="Texture2D" uid="uid://cvrwgkoawfjct" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/cerca1.png" id="10_3isog"]
[ext_resource type="AudioStream" uid="uid://bkjq1nj3l6fuj" path="res://microjogos/2023S1/projeto_luiscolosimo/recursos/musica/bgm.wav" id="11_oga73"]

[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_4i6xm"]
radius = 31.0
height = 92.0

[sub_resource type="CircleShape2D" id="CircleShape2D_u5dvy"]
radius = 11.0

[node name="Main" type="Node2D"]
script = ExtResource("1")

[node name="Background" type="Sprite2D" parent="."]
position = Vector2(448, 608)
scale = Vector2(2.55438, 2.55438)
texture = ExtResource("8_l8pfv")

[node name="Cria" type="Area2D" parent="."]
script = ExtResource("4_pr0bi")

[node name="Hide" type="Sprite2D" parent="Cria"]
scale = Vector2(0.28, 0.28)
texture = ExtResource("5_xappj")

[node name="Show" type="Sprite2D" parent="Cria"]
visible = false
z_index = 1
scale = Vector2(0.28, 0.28)
texture = ExtResource("5_oga73")

[node name="CollisionShape2D" type="CollisionShape2D" parent="Cria"]
shape = SubResource("CapsuleShape2D_4i6xm")

[node name="Mira" type="CharacterBody2D" parent="."]
z_index = 1
position = Vector2(960, 540)
script = ExtResource("4_r5nct")

[node name="Sprite2D" type="Sprite2D" parent="Mira"]
position = Vector2(24, -27.9999)
scale = Vector2(0.4, 0.4)
texture = ExtResource("6_rsfoc")

[node name="Hitbox" type="CollisionShape2D" parent="Mira"]
position = Vector2(3, -2)
shape = SubResource("CircleShape2D_u5dvy")

[node name="locais" type="Node2D" parent="."]

[node name="loc1" type="Marker2D" parent="locais"]
z_index = 1
position = Vector2(477, 913)

[node name="loc2" type="Marker2D" parent="locais"]
z_index = 1
position = Vector2(1067, 982)

[node name="loc3" type="Marker2D" parent="locais"]
z_index = 1
position = Vector2(1142, 770)

[node name="mundo" type="Node2D" parent="."]

[node name="Sprite2D" type="Sprite2D" parent="mundo"]
position = Vector2(475.5, 926.5)
scale = Vector2(2.57407, 2.56667)
texture = ExtResource("8_8ymq0")

[node name="Sprite2D2" type="Sprite2D" parent="mundo"]
position = Vector2(1039, 1021)
scale = Vector2(2.57407, 2.56667)
texture = ExtResource("9_npe7l")

[node name="Sprite2D3" type="Sprite2D" parent="mundo"]
position = Vector2(1110, 787)
scale = Vector2(2.57407, 2.56667)
texture = ExtResource("10_3isog")

[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."]
stream = ExtResource("11_oga73")
autoplay = true

[connection signal="body_entered" from="Cria" to="Cria" method="_on_cursor_entered"]
[connection signal="body_exited" from="Cria" to="Cria" method="_on_cursor_exited"]
20 changes: 20 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/Mira.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
extends CharacterBody2D

const SPEED = 600
const ACCEL = 0.15
const SPRITE_LERP_WEIGHT = 0.2
const RECOIL = Vector2(0, -64)

func _physics_process(delta):
var dir = (
Vector2(1, 0) *
(Input.get_action_strength("direita") - Input.get_action_strength("esquerda"))
+ Vector2(0, 1) *
(Input.get_action_strength("baixo") - Input.get_action_strength("cima"))
).normalized()
velocity = velocity.lerp(dir * SPEED, ACCEL)
position += velocity * delta

# Limita a posição da mira para não sair da tela
position[0] = clamp(position[0], 0, 1920)
position[1] = clamp(position[1], 0, 1080)
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://b1cmsggk4uyc
22 changes: 22 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/child.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
extends Area2D

var dentro = false
@onready var possis = [$"../locais/loc1",$"../locais/loc2",$"../locais/loc3"]
# Called when the node enters the scene tree for the first time.
func _ready():
var random = RandomNumberGenerator.new()
random.randomize()
var local = (randi()%3)
self.set_position(possis[local].position)

func _on_cursor_entered(body: Node2D) -> void:
dentro = true

func _on_cursor_exited(body: Node2D) -> void:
dentro = false

func _process(delta: float) -> void:
if Input.is_action_just_pressed("acao") and dentro:
$"Hide".hide()
$"Show".show()
get_parent().register_win()
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://cxqdy2h0a8wof
31 changes: 31 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/cenas/scripts/main.gd
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
extends Node2D

# Declaração dos sinais win e lose
signal win
signal lose

# Estas constantes são usadas para determinar o tamanho da tela do seu jogo. Por padrão, definem uma
# tela 1920x1080, que é padrão para monitores full HD. Caso você queira uma resolução menor para
# atingir uma estética mais pixelada, você pode mudar estes números para qualquer outra resolução
# 16:9
const WIDTH = 1920
const HEIGHT = 1080

# --------------------------------------------------------------------------------------------------
# CONDIÇÕES DE VITÓRIA
# --------------------------------------------------------------------------------------------------
# Quando o jogo começa, ela assume que o jogador não conseguiu vencer o jogo ainda, ou seja, se não
# acontecer nada, o jogador vai perder o jogo. A verificação se o jogador venceu o minigame é feita
# com base na emissão dos sinais "win" e "lose". Se "win" foi o último sinal emitido, o jogador
# vencerá o jogo, e se "lose" foi o último sinal emitido ou nenhum sinal foi emitido, o jogador
# perderá o jogo


# Chame esta função para registrar que o jogador venceu o jogo
func register_win():
emit_signal("win")


# Chame esta função para registrar que o jogador perdeu o jogo
func register_lose():
emit_signal("lose")
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://dmwmle1cf2c8b
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Coloque seus scripts aqui!
28 changes: 28 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/creditos.gd
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

creditos.gd deprecated, use microgame.tres instead

Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
extends Resource


# Este arquivo vai ser usado diretamente nos créditos do jogo! Dê crédito a todas as pessoaas que
# participaram da criação do jogo e a todos os recursos externos utilizados. Lembre que a fonte que
# será utilizada não suporte caracteres latinos como ~ ou ´


# Título do seu jogo
var title_pt = "Esconde Esconde"
var title_en = "Hide and seek"

# Detalhes dos créditos do seu jogo
var credits_pt = """
Criado por: Luís Felipe Colosimo

GitHub: https://github.com/luisfelipecolosimo

Background: https://hello-tazzina.itch.io/green-woods
"""
var credits_en = """
Made by: Luís Felipe Colosimo

GitHub: https://github.com/luisfelipecolosimo

Background: https://hello-tazzina.itch.io/green-woods

"""
1 change: 1 addition & 0 deletions microjogos/2023S1/projeto_luiscolosimo/creditos.gd.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://wntdea2ug2i8
25 changes: 25 additions & 0 deletions microjogos/2023S1/projeto_luiscolosimo/microgame.tres
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing credits for the BGM, character sprite and hand

Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
[gd_resource type="Resource" script_class="MicrogameAsset" load_steps=4 format=3 uid="uid://l1t8cmdsnjh7"]

[ext_resource type="Texture2D" uid="uid://o8yio6hun0y" path="res://microjogos/2023S1/projeto_luiscolosimo/capa.png" id="1_ri1br"]
[ext_resource type="PackedScene" uid="uid://byy1uildj3qlc" path="res://microjogos/2023S1/projeto_luiscolosimo/cenas/main.tscn" id="2_ri1br"]
[ext_resource type="Script" uid="uid://bus1nknp6xsc0" path="res://principal/microgame_asset.gd" id="3_lu6fi"]

[resource]
script = ExtResource("3_lu6fi")
cover = ExtResource("1_ri1br")
title_pt = &"Esconde Esconde"
title_en = &"Hide and seek"
credits_pt = "Criado por: Luís Felipe Colosimo

GitHub: https://github.com/luisfelipecolosimo

Background: https://hello-tazzina.itch.io/green-woods"
credits_en = "Made by: Luís Felipe Colosimo

GitHub: https://github.com/luisfelipecolosimo

Background: https://hello-tazzina.itch.io/green-woods"
start_message_pt = &"Encontre!"
start_message_en = &"Seek!"
main_scene = ExtResource("2_ri1br")
difficulty = 0
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://dk40vxf34co6l"
path="res://.godot/imported/background.png-2544364f6dcf47c17c2f8cc7c8a4ea1d.ctex"
metadata={
"vram_texture": false
}

[deps]

source_file="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/background.png"
dest_files=["res://.godot/imported/background.png-2544364f6dcf47c17c2f8cc7c8a4ea1d.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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://cvrwgkoawfjct"
path="res://.godot/imported/cerca1.png-2a8f531aa4839dfa196b38940f7a16d9.ctex"
metadata={
"vram_texture": false
}

[deps]

source_file="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/cerca1.png"
dest_files=["res://.godot/imported/cerca1.png-2a8f531aa4839dfa196b38940f7a16d9.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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[remap]

importer="texture"
type="CompressedTexture2D"
uid="uid://bt3ua0mlh0uei"
path="res://.godot/imported/pedra1.png-942148c115485ed90383ee39a0628880.ctex"
metadata={
"vram_texture": false
}

[deps]

source_file="res://microjogos/2023S1/projeto_luiscolosimo/recursos/casa/pedra1.png"
dest_files=["res://.godot/imported/pedra1.png-942148c115485ed90383ee39a0628880.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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading