-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
可以给个联系方式吗? #1
Comments
想请问一下 台球杆子有时候蓄力发不出去是为什么呢?请问如何修复会比较好 |
我刚又看了下代码,初学的时候不懂乱写的,直接用的 |
感谢您的回复!
经过排查,发现问题在于fixedupdate,将其改为update以后就运行正常了。
初学者的你,能写出这样的作品,令我很佩服。
祝你天天开心,如意
…------------------ 原始邮件 ------------------
发件人: "bogroot/Unity_BallsGo" ***@***.***>;
发送时间: 2021年12月17日(星期五) 凌晨1:05
***@***.***>;
***@***.******@***.***>;
主题: Re: [bogroot/Unity_BallsGo] 可以给个联系方式吗? (#1)
想请问一下 台球杆子有时候蓄力发不出去是为什么呢?请问如何修复会比较好
我刚又看了下代码,初学的时候不懂乱写的,直接用的Input.GetMouseButton几个方法来判断的是否开始/结束蓄力。我猜测是这几个检测方法用杂了,导致有时候没有识别到或者识别错了鼠标的点击事件。
问题应该出在ballcontroller.cs这个脚本的void moveandhit()方法里,建议加几个bool变量和输入检测方法来判断是否进入蓄力或结束蓄力,比如开始蓄力的时候设为true,抬起鼠标并且为true时再执行结束蓄力的操作。然后可以在官网看看Input.GetMouseButton等几个相关方法的解释,了解他们详细的用法。
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you commented.Message ID: ***@***.***>
|
谢谢~ |
No description provided.
The text was updated successfully, but these errors were encountered: