Install any skill in seconds. Free to start, no credit card required.
Get Started Free →jame581/csharp-godot
Use when working with C# in Godot — conventions, GodotSharp API differences from GDScript, project setup, and interop
Passed 23 of 23 test cases with the skill, and 21 of 23 without it.
2 fixed21 passed either way0 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
This benchmark measured an earlier version of the skill.
A newer attempt on gemini-3.8-flash on 10/20/2026 did not produce a publishable comparison (not comparable). The snapshot above is the previously measured run.
One of 2 test cases the skill fixed. Same model, same prompt, with and without the skill.
When upgrading to Godot 4.7, my C# code setting 'control.AccessibilityLive = DisplayServer.AccessibilityLiveMode.Polite' failed to compile. Where did the AccessibilityLiveMode enum move in Godot 4.7?
| Checked | Without skill | With skill |
|---|---|---|
| Uses AccessibilityServer.AccessibilityLiveMode instead of DisplayServer. | Missed | Passed |
The instructions your model reads when the skill loads.
This skill covers C#-specific conventions, API differences from GDScript, project setup, and interop patterns. All examples are C# only. Target Godot 4.3+ with the GodotSharp NuGet package.
Related skills: csharp-signals for C# signal patterns, godot-project-setup for C# project scaffolding, godot-testing for C# testing with gdUnit4, gdextension for native C++ when C# is not enough, multithreading for C# concurrency.
| GDScript | C# Equivalent | Notes |
|---|---|---|
var x = 5 | var x = 5; or typed int x = 5; | C# var infers type at compile time |
func MyMethod() -> void: | public void MyMethod() { } | Methods are PascalCase in C# |
signal health_changed(amount: int) | [Signal] delegate void HealthChangedEventHandler(int amount); | Must use EventHandler suffix |
@export var speed: float = 100.0 | [Export] public float Speed { get; set; } = 100f; | PascalCase, property syntax |
@onready var label = $Label | private Label _label; + _label = GetNode<Label>("Label"); in _Ready() | No @onready equivalent; use _Ready() |
match value: | switch (value) { case X: break; } | C# switch also supports pattern matching |
class_name MyClass | [GlobalClass] public partial class MyClass : GodotObject { } | Requires [GlobalClass] attribute |
extends Node | public partial class MyScript : Node { } | Inheritance via : |
preload("res://scene.tscn") | GD.Load<PackedScene>("res://scene.tscn") | Loaded at runtime, not compile time |
push_error("msg") | GD.PushError("msg"); | Prints to Godot error log |
print("msg") | GD.Print("msg"); | Also: GD.PrintS(), GD.PrintT() |
node is CharacterBody2D | node is CharacterBody2D | Same keyword, same semantics |
node as CharacterBody2D | node as CharacterBody2D | Returns null on failure in both |
await signal_name | await ToSignal(source, SignalName.X); | Must use ToSignal() wrapper |
Array | Godot.Collections.Array | Not System.Collections.Generic.List<T> |
Dictionary | Godot.Collections.Dictionary | Not System.Collections.Generic.Dictionary<K,V> |
Godot auto-generates the .csproj when you create the first C# script via Script > New Script > C#. Do not edit the generated file structure manually — let the editor manage it.
MyProject/
├── MyProject.csproj # Auto-generated, edit only for NuGet packages
test cases passed, vs 21 / 23 without
Published skills whose descriptions closely match this one, with their headline benchmark lift.
More skills from the same source and nearby in the registry, with their headline benchmark lift.