-
Notifications
You must be signed in to change notification settings - Fork 86
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
[Utility] and [New Bullet] weight system and better simulation of knockback #476
Closed
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cylic14790382
requested review from
LazyJazz,
sshockwave,
qinchuanhui and
huanchenz
as code owners
January 16, 2023 11:27
关于重力系统的更新,仅仅添加一个Unit类中的参数weight,通过调用可以得到推离应该有的距离, |
关于新的坦克类型,主要实现了技能反重力期间所有非自身单位重力减半,速度加倍,并向四周发射击退子弹(可能有点不平衡[doge]) Sample.mp4敌方单位是infernotank,weight是20,子弹是snowball,可以看到开启技能后明显能打动了(但是还是被吊打[doge]) |
qinchuanhui
approved these changes
Jan 16, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM,you can get the corresponding score
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
In this pull request, I might finish issue #421 and issue #239 .
首先,原有的队列正如 PR #435 中提到的那样, 对于位置的更新存在一点问题。
于是,在他的启发下更改了更新的逻辑:
所有的类似于
PushEventMoveUnit
的函数都在队列中只更改Unit::position_change_
最后所有的更改收集在
EndTick
函数中一并更新。(和本PR相关的仅仅是位移方向,所以伤害方向并没有更改)。其次,实现了一个简单的Effect效果:通过增加一个队列
AwaitingQueue
来实现。同时,位移雪球以前实现的其实类似于瞬移,通过上述实现将其真正模拟成位移:相当于一段时长的位移buff。
见下
Snowball.mp4
badsnowball.mp4