Skip to content

Commit fb709e4

Browse files
committed
README 等修正
1 parent fe970a3 commit fb709e4

File tree

6 files changed

+37
-167
lines changed

6 files changed

+37
-167
lines changed

.github/workflows/builds.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,11 @@ name: Build GDExtension
22
on:
33
workflow_call:
44
push:
5-
branches: ['main']
5+
# branches: ['main']
6+
branches: []
67
pull_request:
7-
branches: ['main']
8+
# branches: ['main']
9+
branches: []
810
merge_group:
911

1012
jobs:

README.md

Lines changed: 0 additions & 149 deletions
This file was deleted.

demo/main.gd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
extends Control
22

3-
@export var resource : SimpleDSL
3+
@export var resource : ReDScribe
44

55

66
func _ready() -> void:

demo/main.tscn

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,8 @@
1-
[gd_scene load_steps=4 format=3 uid="uid://bk2ofed5aex75"]
1+
[gd_scene load_steps=3 format=3 uid="uid://bk2ofed5aex75"]
22

33
[ext_resource type="Script" uid="uid://57dhbuhscgsa" path="res://main.gd" id="1_ig7tw"]
44

5-
[sub_resource type="GDScript" id="GDScript_ig7tw"]
6-
script/source = "extends ReDScribe
7-
class_name SimpleDSL
8-
9-
func foo() -> String:
10-
print_debug('foo called gdscript')
11-
return 'foo called'
12-
"
13-
14-
[sub_resource type="ReDScribe" id="ReDScribe_h2yge"]
15-
script = SubResource("GDScript_ig7tw")
16-
metadata/_custom_type_script = "uid://q4xwd5idf33b"
5+
[sub_resource type="ReDScribe" id="ReDScribe_ig7tw"]
176

187
[node name="Main" type="Control"]
198
layout_mode = 3
@@ -23,4 +12,4 @@ anchor_bottom = 1.0
2312
grow_horizontal = 2
2413
grow_vertical = 2
2514
script = ExtResource("1_ig7tw")
26-
resource = SubResource("ReDScribe_h2yge")
15+
resource = SubResource("ReDScribe_ig7tw")

demo/src/example1/example_1.gd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ func _ready() -> void:
66
res.method_missing.connect(_method_missing)
77
res.perform("""
88
foo 1, 2.3, true, false, nil, 'bar', :piyo
9-
bar(piyo: 1, 'bar' => 2)
9+
bar piyo: 1, 'bar' => 2
1010
piyo [1, 2.3, :bar]
1111
""")
1212

memos/godot-cpp-template-README.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<img src="icon/icon_with_title.png" alt="logo">
2+
3+
# ReDScribe
4+
Re-describe your code better with ruby on Godot.
5+
6+
7+
## Usage
8+
```gdscript
9+
extends Control
10+
11+
@onready var res := ReDScribe.new()
12+
13+
func _ready() -> void:
14+
res.method_missing.connect(_method_missing)
15+
res.perform("""
16+
foo 1, 2.3, true, false, nil, 'bar', :piyo
17+
bar piyo: 1, 'bar' => 2
18+
piyo [1, 2.3, :bar]
19+
""")
20+
21+
func _method_missing(method_name: String, args: Array) -> void:
22+
print_debug(method_name, ': ', args)
23+
# outputs:
24+
# foo: [1, 2.3, true, false, <null>, "bar", "piyo"]
25+
# bar: [{ "piyo": 1, "bar": 2 }]
26+
# piyo: [[1, 2.3, "bar"]]
27+
28+
```

0 commit comments

Comments
 (0)