Missing gdscript functions
- 主要语言
- C++
- 星标
- 1.1k
- 派生
- 80
- PR 合并指标
- 30 天内没有已合并 PR
描述
I notice we're missing some print functions that are in gdscript. Namely [prints](https://docs.godotengine.org/en/stable/classes/class_@gdscript.html#class-gdscript-method-prints), [printt](https://docs.godotengine.org/en/stable/classes/class_@gdscript.html#class-gdscript-method-printt), [print_debug](https://docs.godotengine.org/en/stable/classes/class_@gdscript.html#class-gdscript-method-print-debug), and [print-stack](https://docs.godotengine.org/en/stable/classes/class_@gdscript.html#class-gdscript-method-print-stack).
When writing gdscript I use `prints` in every situation (as it inserts spaces between arguments, just like `console.log` in JavaScript), so I noticed it quickly when trying this project.
Also I'm not sure that `print` is working as expected. It is supposed to accept and print any number of arguments, but in my testing it only prints the first:
```typescript
// this prints: "a"
godot.print("a", "b", "c")
```
The typings for `print` seem correct though:
```typescript
function godot.print(...args: any[]): void
```
贡献指南
调研方向
从定位 godot.print 背后的绑定开始,并将其参数处理方式与 issue 中链接的 GDScript 函数进行比较。检查 print 当前如何处理多个参数,然后跟踪 print、printt、print_debug 和 print-stack 对应的 API 入口点。完成标准是这四个函数可用,并且 print 能够按描述接受所有提供的参数。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- godot, javascript, typescript
- 领域
- api
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 42/100