First commit 🎉

This commit is contained in:
Tony Bark 2025-07-17 01:49:18 -04:00
commit 43ea213f9b
728 changed files with 37080 additions and 0 deletions

View file

@ -0,0 +1,94 @@
@tool
extends PopochiuCharacter
# You can use E.queue([]) to trigger a sequence of events.
# Use await E.queue([]) if you want to pause the execution of
# the function until the sequence of events finishes.
const Data := preload('character_max_casey_state.gd')
var state: Data = load("res://game/characters/max_casey/character_max_casey.tres")
#region Virtual ####################################################################################
# When the room in which this node is located finishes being added to the tree
func _on_room_set() -> void:
pass
# When the node is clicked
func _on_click() -> void:
# Replace the call to E.command_fallback() to implement your code.
# E.command_fallback()
# For example, you can make the player character walk to this character, gaze at it, and then
# say something:
# await C.player.walk_to_clicked()
# await C.player.face_clicked()
await C.player.say("Hi!")
func _on_double_click() -> void:
# Replace the call to E.command_fallback() with your code.
E.command_fallback()
# For example, you could make the player instantly do something instead of walking there first
# When the node is right clicked
func _on_right_click() -> void:
# Replace the call to E.command_fallback() to implement your code.
E.command_fallback()
# For example, you can make the player character gaze at this character and then say something:
# await C.player.face_clicked()
# await C.player.say("Is someone...")
# When the node is middle clicked
func _on_middle_click() -> void:
# Replace the call to E.command_fallback() to implement your code.
E.command_fallback()
# When the node is clicked and there is an inventory item selected
func _on_item_used(_item: PopochiuInventoryItem) -> void:
# Replace the call to E.command_fallback() to implement your code.
E.command_fallback()
# For example, you can make the player character say something when the Key item is used in this
# character. Note that you have to change the name of the `_item` parameter to `item`.
# if item == I.Key:
# await C.player.say("I don't want to give up my key")
# Use it to play the idle animation for the character
func _play_idle() -> void:
super()
# Use it to play the walk animation for the character
# target_pos can be used to know the movement direction
func _play_walk(target_pos: Vector2) -> void:
super(target_pos)
# Use it to play the talk animation for the character
func _play_talk() -> void:
super()
# Use it to play the grab animation for the character
func _play_grab() -> void:
super()
# Called when the character stops moving
func _on_move_ended() -> void:
pass
#endregion
#region Public #####################################################################################
# You can add here functions triggered by the GUI commands. For example, if your GUI has a command
# for look_at, you could have the function:
#func on_look_at() -> void:
#pass
#endregion

View file

@ -0,0 +1 @@
uid://bmoec1vo7mtv4

View file

@ -0,0 +1,9 @@
[gd_resource type="Resource" load_steps=2 format=3 uid="uid://333bndb8rxr6"]
[ext_resource type="Script" path="res://game/characters/max_casey/character_max_casey_state.gd" id="1_7gkay"]
[resource]
resource_name = "MaxCasey"
script = ExtResource("1_7gkay")
script_name = "MaxCasey"
scene = "res://game/characters/max_casey/character_max_casey.tscn"

View file

@ -0,0 +1,27 @@
[gd_scene load_steps=3 format=3 uid="uid://c3x0g1051m0tq"]
[ext_resource type="Script" path="res://game/characters/max_casey/character_max_casey.gd" id="1_dbiw3"]
[ext_resource type="Texture2D" uid="uid://si64wbbpxfwr" path="res://assets/pixel-max.png" id="2_fc5jj"]
[node name="CharacterMaxCasey" type="Area2D"]
script = ExtResource("1_dbiw3")
popochiu_placeholder = null
script_name = "MaxCasey"
description = "Max Casey"
cursor = 8
interaction_polygon = PackedVector2Array(-10, -10, 39, -10, 42, 107, -13, 111)
interaction_polygon_position = Vector2(-30, -39)
[node name="InteractionPolygon" type="CollisionPolygon2D" parent="."]
visible = false
position = Vector2(-30, -39)
polygon = PackedVector2Array(-10, -10, 39, -10, 42, 107, -13, 111)
[node name="ScalingPolygon" type="CollisionPolygon2D" parent="."]
polygon = PackedVector2Array(0, 0, 0, 0, 0, 0, 0, 0)
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
[node name="Sprite2D" type="Sprite2D" parent="."]
texture_filter = 1
texture = ExtResource("2_fc5jj")

View file

@ -0,0 +1,23 @@
extends PopochiuCharacterData
# Put here variables you want to save and load when saving and loading the game.
# By default only Godot's basic built-in types are automatically saved and loaded
# but you can use the save_custom and load_custom methods to implement your
# own.
# script_name and scene variables from the inherited class will not be saved.
#region Virtual ####################################################################################
# Use this to save custom data for this PopochiuCharacter when saving the game.
# The Dictionary must contain only JSON supported types: bool, int, float, String.
func _on_save() -> Dictionary:
return {}
# Called when the game is loaded.
# This Dictionary should has the same structure you defined for the returned
# one in on_save().
func _on_load(data: Dictionary) -> void:
prints(data)
#endregion

View file

@ -0,0 +1 @@
uid://b3uks6qjugt2b