Skip to content

Commit 0624e9b

Browse files
authored
Update several references to v0.10 or latest docs.rs (#67)
1 parent 9e8dfab commit 0624e9b

File tree

6 files changed

+10
-10
lines changed

6 files changed

+10
-10
lines changed

src/faq/code.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ impl StaticUtil {
205205
}
206206
```
207207

208-
[`Aether`](https://docs.rs/gdnative/0.9/gdnative/prelude/struct.Aether.html) is a special user-data wrapper intended for zero-sized types, that does not perform any allocation or synchronization at runtime.
208+
[`Aether`](https://docs.rs/gdnative/latest/gdnative/export/user_data/struct.Aether.html) is a special user-data wrapper intended for zero-sized types, that does not perform any allocation or synchronization at runtime.
209209

210210
The type needs to be instantiated somewhere on GDScript level.
211211
Good places for instantiation are for instance:
@@ -456,4 +456,4 @@ If you require insight into Rust code that is not exported to Godot or would lik
456456

457457
**Note:** There are many more profilers than the ones listed and you should do your own research before selecting which one you wish to use.
458458

459-
For more information about profiling and other rust performance tips, please check out the [Rust performance book](https://nnethercote.github.io/perf-book/profiling.html).
459+
For more information about profiling and other rust performance tips, please check out the [Rust performance book](https://nnethercote.github.io/perf-book/profiling.html).

src/gdnative-overview/data-representations.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ _See `GodotObject`, the Rust trait implemented for all Godot classes, in [godot-
4242

4343
Since GDScript is a dynamic language, you often deal with variants implicitly. Variables which are not type-annotated can have values of multiple types throughout their lifetime. In static languages like Rust, every value must have a defined type, thus untyped values in GDScript correspond to `Variant` in Rust. Godot APIs which accept any type as parameter are declared as `Variant` in the GDNative bindings (and thus godot-rust library). Sometimes, godot-rust also provides transparent mapping from/to concrete types behind the scenes.
4444

45-
Variants also have a second role as a serialization format between Godot and Rust. It is possible to extend this beyond the built-in Godot types. To make your own types convertible from and to variants, implement the traits [`FromVariant`](https://docs.rs/gdnative/latest/gdnative/core_types/trait.FromVariant.html) and [`ToVariant`](https://docs.rs/gdnative/latest/gdnative/core_types/trait.ToVariant.html). Types that can only be safely converted to variants by giving up ownership can use [OwnedToVariant](https://docs.rs/gdnative/0.9.3/gdnative/core_types/trait.OwnedToVariant.html), which is similar to the Rust `Into` trait.
45+
Variants also have a second role as a serialization format between Godot and Rust. It is possible to extend this beyond the built-in Godot types. To make your own types convertible from and to variants, implement the traits [`FromVariant`](https://docs.rs/gdnative/latest/gdnative/core_types/trait.FromVariant.html) and [`ToVariant`](https://docs.rs/gdnative/latest/gdnative/core_types/trait.ToVariant.html). Types that can only be safely converted to variants by giving up ownership can use [OwnedToVariant](https://docs.rs/gdnative/latest/gdnative/core_types/trait.OwnedToVariant.html), which is similar to the Rust `Into` trait.
4646

4747
_See `Variant` in
4848
[godot-rust docs](https://docs.rs/gdnative/latest/gdnative/core_types/struct.Variant.html),

src/getting-started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,4 @@ This tutorial assumes some experience with Godot's GUI and GDScript. It assumes
66

77
## Work-in-progress
88

9-
**The Getting Started tutorial is a work-in-progress, and currently it only covers up to the hello-world example!** To learn more about the API after the tutorial, you'll have to dive into the [documentation on docs.rs](https://docs.rs/gdnative/0.9), and the [other examples in the main repo]( https://github.com/godot-rust/godot-rust/tree/master/examples/). If you have any questions using the bindings, ask away in the `#gdnative_dev` channel on the [Godot Engine community Discord server](https://godotengine.org/community)!
9+
**The Getting Started tutorial is a work-in-progress, and currently it only covers up to the hello-world example!** To learn more about the API after the tutorial, you'll have to dive into the [documentation on docs.rs](https://docs.rs/gdnative/latest), and the [other examples in the main repo](https://github.com/godot-rust/godot-rust/tree/master/examples/). If you have any questions using the bindings, ask away in the `#gdnative_dev` channel on the [Godot Engine community Discord server](https://godotengine.org/community)!

src/getting-started/hello-world.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Once the project is created, open `Cargo.toml`, change the crate type to `cdylib
3636
crate-type = ["cdylib"]
3737

3838
[dependencies]
39-
gdnative = "0.9"
39+
gdnative = "0.10"
4040
```
4141

4242
> ### Organization of Rust code
@@ -187,4 +187,4 @@ You can find the full code for this example in the main repo: [https://github.co
187187

188188
## Work-in-progress
189189

190-
**The Getting Started tutorial is a work-in-progress, and unfortunately it ends here for now!** To learn more about the API, you'll have to dive into the [documentation on docs.rs](https://docs.rs/gdnative/0.9), and the [other examples in the main repo]( https://github.com/godot-rust/godot-rust/tree/master/examples/). If you have any questions using the bindings, ask away in the `#gdnative_dev` channel on the [Godot Engine community Discord server](https://godotengine.org/community)!
190+
**The Getting Started tutorial is a work-in-progress, and unfortunately it ends here for now!** To learn more about the API, you'll have to dive into the [documentation on docs.rs](https://docs.rs/gdnative/latest), and the [other examples in the main repo]( https://github.com/godot-rust/godot-rust/tree/master/examples/). If you have any questions using the bindings, ask away in the `#gdnative_dev` channel on the [Godot Engine community Discord server](https://godotengine.org/community)!

src/rust-binding/properties.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ For cases not covered by the `#[property]` attribute, it may be necessary to man
9393

9494
This is often the case where custom hint behavior is desired for primitive types, such as an Integer value including an `IntEnum` hint.
9595

96-
To do so, you can use the [`ClassBuilder`](https://docs.rs/gdnative/0.9.3/gdnative/prelude/struct.ClassBuilder.html) -- such as in the following examples -- to manually register each property and customize how they interface in the editor.
96+
To do so, you can use the [`ClassBuilder`](https://docs.rs/gdnative/latest/gdnative/prelude/struct.ClassBuilder.html) -- such as in the following examples -- to manually register each property and customize how they interface in the editor.
9797

9898
```rust
9999
#[derive(NativeClass)]
@@ -153,4 +153,4 @@ impl MyNode {
153153
self.number = new_value
154154
}
155155
}
156-
```
156+
```

src/rust-binding/to-variant-from-variant-export.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ For more information about how you can customize the behavior of the dervive mac
3131

3232
## Export Trait
3333

34-
The Godot editor retrieves property information from [Object::get_property_list](https://docs.godotengine.org/en/stable/classes/class_object.html#id2). To populate this data, `godot-rust` requires that the [`Export`](https://docs.rs/gdnative/0.9.3/gdnative/nativescript/trait.Export.html) trait be implemented for each type Rust struct.
34+
The Godot editor retrieves property information from [Object::get_property_list](https://docs.godotengine.org/en/stable/classes/class_object.html#id2). To populate this data, `godot-rust` requires that the [`Export`](https://docs.rs/gdnative/latest/gdnative/nativescript/trait.Export.html) trait be implemented for each type Rust struct.
3535

3636
There are no derive macros that can be used for `Export` but many of the primitive types have it implemented by default.
3737

@@ -47,7 +47,7 @@ struct Foo {
4747
}
4848

4949
impl Export for Foo {
50-
// This type should normally be one of the types defined in [gdnative::nativescript::hint](https://docs.rs/gdnative/0.9.3/gdnative/nativescript/init/property/hint/index.html).
50+
// This type should normally be one of the types defined in [gdnative::export::hint](https://docs.rs/gdnative/latest/gdnative/export/hint/index.html).
5151
// Or it can be any custom type for differentiating the hint types.
5252
// In this case it is unused, so it is left as ()
5353
type Hint = ();

0 commit comments

Comments
 (0)