godot
Godot Engine patterns, Node tree architecture, Signals, Resources, and GDScript/C# conventions
What this skill does
# Godot Development Skill
## Engine Detection
Look for: `project.godot`, `.tscn`, `.tres`, `.gd`, `.gdshader`, `addons/`, `export_presets.cfg`
## Project Structure
```
my_game/
scenes/
player/
player.tscn
player.gd
enemies/
enemy_base.tscn
enemy_base.gd
ui/
hud.tscn
main_menu.tscn
levels/
level_01.tscn
scripts/
autoloads/
game_manager.gd
audio_manager.gd
resources/
weapon_data.gd
utilities/
state_machine.gd
assets/
sprites/
models/
audio/
fonts/
addons/ # Third-party plugins
project.godot
export_presets.cfg
```
## Node Tree Architecture
Everything in Godot is a Node. Scenes are reusable node trees:
```gdscript
# player.gd - attached to the root node of player.tscn
extends CharacterBody2D
@export var speed: float = 200.0
@export var jump_velocity: float = -400.0
@onready var animated_sprite = $AnimatedSprite2D
@onready var collision_shape = $CollisionShape2D
@onready var health_component = $HealthComponent
var gravity: float = ProjectSettings.get_setting("physics/2d/default_gravity")
func _ready() -> void:
# Called when node enters scene tree
health_component.health_depleted.connect(_on_health_depleted)
func _physics_process(delta: float) -> void:
# Called every physics frame (fixed timestep)
if not is_on_floor():
velocity.y += gravity * delta
if Input.is_action_just_pressed("jump") and is_on_floor():
velocity.y = jump_velocity
var direction = Input.get_axis("move_left", "move_right")
velocity.x = direction * speed
move_and_slide()
func _process(delta: float) -> void:
# Called every frame (variable timestep)
# Use for visual updates, input that doesn't affect physics
pass
func _on_health_depleted() -> void:
queue_free()
```
## Signals (Event System)
Signals are Godot's observer pattern for decoupled communication:
```gdscript
# Defining custom signals
signal health_changed(new_health: float)
signal died
# Emitting signals
func take_damage(amount: float) -> void:
current_health -= amount
health_changed.emit(current_health)
if current_health <= 0:
died.emit()
# Connecting signals (in code)
func _ready() -> void:
# Connect to child node's signal
$HealthComponent.health_changed.connect(_on_health_changed)
# Connect with bind for extra data
$Button.pressed.connect(_on_button_pressed.bind("confirm"))
# Connecting signals (in editor)
# Use the Node > Signals panel to connect visually
```
## Resources (Data-Driven Design)
Custom Resources are Godot's equivalent of ScriptableObjects:
```gdscript
# weapon_data.gd
class_name WeaponData
extends Resource
@export var weapon_name: String = ""
@export var damage: int = 10
@export var attack_speed: float = 1.0
@export var range: float = 100.0
@export var projectile_scene: PackedScene
@export var attack_sound: AudioStream
```
Usage:
```gdscript
# weapon_controller.gd
extends Node2D
@export var weapon_data: WeaponData
func attack() -> void:
var projectile = weapon_data.projectile_scene.instantiate()
projectile.damage = weapon_data.damage
get_tree().current_scene.add_child(projectile)
```
## State Machine Pattern
```gdscript
# state_machine.gd
class_name StateMachine
extends Node
@export var initial_state: State
var current_state: State
var states: Dictionary = {}
func _ready() -> void:
for child in get_children():
if child is State:
states[child.name.to_lower()] = child
child.transitioned.connect(_on_state_transitioned)
if initial_state:
initial_state.enter()
current_state = initial_state
func _process(delta: float) -> void:
if current_state:
current_state.update(delta)
func _physics_process(delta: float) -> void:
if current_state:
current_state.physics_update(delta)
func _on_state_transitioned(state: State, new_state_name: String) -> void:
if state != current_state:
return
var new_state = states.get(new_state_name.to_lower())
if new_state:
current_state.exit()
new_state.enter()
current_state = new_state
```
```gdscript
# state.gd
class_name State
extends Node
signal transitioned(state: State, new_state_name: String)
func enter() -> void:
pass
func exit() -> void:
pass
func update(delta: float) -> void:
pass
func physics_update(delta: float) -> void:
pass
```
## Autoloads (Singletons)
Register in Project > Project Settings > Autoload:
```gdscript
# game_manager.gd (autoload)
extends Node
signal game_paused
signal game_resumed
var score: int = 0
var is_paused: bool = false
func pause_game() -> void:
is_paused = true
get_tree().paused = true
game_paused.emit()
func resume_game() -> void:
is_paused = false
get_tree().paused = false
game_resumed.emit()
```
## Key Rules
1. **Use @onready for child node references** - `@onready var sprite = $Sprite2D`
2. **Use @export for inspector-exposed properties** - Type-safe, visible in editor
3. **Use signals for decoupled communication** - Never reach up the tree
4. **Use _physics_process for physics** - Fixed timestep, use for movement
5. **Use _process for visuals** - Variable timestep, use for animation/UI
6. **Use class_name for custom types** - Enables type hints and editor integration
7. **Use Resources for shared data** - Not nodes, lighter weight
8. **Use queue_free() to destroy nodes** - Safe deferred deletion
9. **Use groups for batch operations** - `get_tree().get_nodes_in_group("enemies")`
10. **Use Tweens for animations** - `create_tween().tween_property(self, "position", target, 0.5)`
## Common Anti-Patterns
- `get_node()` with long paths - use @onready or signals instead
- `find_child()` in _process - cache references
- Not using typed arrays and dictionaries - `var items: Array[Item] = []`
- Modifying node tree during iteration - use `call_deferred()`
- Using `get_tree().reload_current_scene()` without cleanup
## GDScript Style Guide
- `snake_case` for functions and variables
- `PascalCase` for classes and nodes
- `SCREAMING_SNAKE_CASE` for constants
- Prefix private members with underscore: `_private_var`
- Use type hints everywhere: `func attack(target: Enemy) -> int:`
- Use `StringName` for frequently compared strings: `&"idle"`
Related in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.