Skip to content

Commit a1e344e

Browse files
Fix some small documentation issues (#75)
- fix #68 - fix dialogic-godot/dialogic/issues/2276 - fix dialogic-godot/dialogic/issues/2646 by mentioning that accessing variables before ready isn't supported
1 parent ed2e41c commit a1e344e

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

documentation/creating-extensions.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,8 @@ func _init() -> void:
101101
event_category = "Godot"
102102
```
103103

104+
You can change the events icon by putting an `icon.svg` or `icon.png` file next to it's script, or by overwriting the `_get_icon()` method and returning a Texture2D.
105+
104106
### 3.4 Saving & Loading (i.e. parsing, representation in timeline's text editor)
105107

106108
We will cover working with shortcodes now. They are pretty much the text view of an event inside the timeline.

documentation/text-modifiers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ func _get_text_modifiers() -> Array[Dictionary]:
7272
{
7373
"subsystem":"MySubsystem",
7474
# alternatively do
75-
#"node_path":"root/MyAutoload",
75+
#"node_path":"/root/MyAutoload",
7676
"method":"my_modifier_method",
7777
"mode": -1}, #-1 = Text&Choice, 0 = TextsOnly, 1 = ChoicesOnly
7878
]

documentation/variables.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ You can also access the Dialogic variables from outside scripts.*
99
To fully utilize these variables, this page contains all you need to know.
1010

1111
## 📜 Content
12+
1213
[toc]
1314

1415
## 1. The Dialogic variable editor
@@ -46,8 +47,8 @@ In the visual editor, you can simply select the variable from the dropdown and c
4647
In conditions, you can use all the same tricks as in text events and a couple more:
4748

4849
- Accessing autoloads: `Autoload.property`
49-
50-
- In these conditions, Autoloads don't have to be wrapped in `{}` brackets.*
50+
51+
- In these conditions, Autoloads don't have to be wrapped in `{}` brackets.*
5152

5253
- Using autoload methods: `Autoload.check_info("Argument", false)`
5354

@@ -135,6 +136,10 @@ Dialogic.VAR.set('my_variable', 20)
135136
print(Dialogic.VAR.get('Group').get('my_variable'))
136137
```
137138

139+
```admonish Warning
140+
Variables are only accessible after the Dialogic autoload is ready, so do not use them before your nodes are ready either!
141+
```
142+
138143
Folders (as well as the root "folder") have some methods that might be useful:
139144

140145
- `folders()` lists all folders in this folder (not strings but `FolderObjects`)

0 commit comments

Comments
 (0)