Godot
Community 社区
Tutorials 教程
Games 游戏
Fun 摸鱼
登录
注册
Godot
登录
注册
社区
教程
摸鱼
国内镜像
kong
喵Ta
脚本编程
大佬们可以帮我看看,这个错误怎么解决呢? extends Node @export var mob_scene:PackedScene var score func game_over(): $ScoreTimer.stop() $MobTimer.stop() $HUD.show_game_over() func new_game(): get_tree().call_group("mobs", "queue_free") score = 0 $Player.start($StartPosition.position) $StartTimer.start() $HUD.update_score(score) $HUD.show_message("Get Ready") func _on_MobTimer_timeout(): var mob = mob_scene.instantiate() var mob_spawn_location = get_node(^"MobPath/MobSpawnLocation") mob_spawn_location.progress = randi() var direction = mob_spawn_location.rotation + PI / 2 mob.position = mob_spawn_location.poisition direction += randf_range(-PI / 4,PI / 4) mob.rotation = direction var velocity = Vector2(randf_range(150.0,250.0),0) mob.linear_velocity = velocity.rotated(direction) add_child(mob) func _on_ScoreTimer_timeout(): score += 1 $HUD.update_score(score) func _on_StartTimer_timeout(): $MobTimer.start() $ScoreTimer.start() 错误是:Invalid get index 'poisition' (on base: 'PathFollow2D').
赞↑
0
踩↓
0
E0:00:02:0363Scene_cha
大佬们,为啥我写的代码人物不会跟随鼠标移动啊
搜索
>>>
Godot中文文档
<<<
[分类标签]
2D
3D
单机游戏
联网游戏
平台闯关
第三人称RPG
UI界面
脚本编程
Shader着色器
粒子特效
动画状态机
发布导出
Steam平台
物理系统
Godot4.X
VR/元宇宙
[投稿须知]
投稿邮箱:hareqj@163.com
教程投稿:可提供B站视频BV号,会直接生成视频播放页。
游戏投稿:须原创,请提供 作品web版文件、作者、简要操控说明。
内容举报邮箱:hareqj@163.com,请告知内容编号(右上角)及违规说明。
Copyright Godot社区 Godot2D.com All Rights Reserved.
京ICP备13032831号