update
parent
57b8810c61
commit
ef5fea8dca
|
@ -1,8 +1,11 @@
|
||||||
[GDScript reference — Godot Engine (stable) documentation in English](https://docs.godotengine.org/en/stable/tutorials/scripting/gdscript/gdscript_basics.html)
|
[GDScript reference — Godot Engine (stable) documentation in English](https://docs.godotengine.org/en/stable/tutorials/scripting/gdscript/gdscript_basics.html)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### 组合与继承
|
### 组合与继承
|
||||||
|
- extends 关键字就是继承的方式
|
||||||
|
- 子脚本中调用 super. 就是调用父类 类似C#中的parent.
|
||||||
|
- 子类方法与父类方法同名时, 会重写方法,
|
||||||
|
- 一般都会写一个空的方法作为 abstruct 方法
|
||||||
|
- 如果想搞一个 virtual 方法, 那么就在子类重写方法后, 调用super.原方法实现
|
||||||
|
|
||||||
### 用键盘代替鼠标来进行游戏操作(Vimlike)
|
### 用键盘代替鼠标来进行游戏操作(Vimlike)
|
||||||
- 关键点:Control.focus
|
- 关键点:Control.focus
|
||||||
|
|
Loading…
Reference in New Issue