-
Notifications
You must be signed in to change notification settings - Fork 826
What is this Magic number? #43
Comments
Code is changed. Please edit your question or should we close this topic? |
It's now on PlayerCell.js line 89. The 5 is the amount that a cell is pushed when your own cells are colliding. I suppose a config/const value could be put in somewhere for it, I'll leave that up to vram, but you start seeing some weird behaviour if it's much higher than 5 (for a lot of fun, try 100)! |
A lot people on our forums hate the "pushing" feature of the game. People use it as an advantage on the teams mode allowing them to cheat for the other team. |
After playing around a little, I think part of the '5' being there was because without it, your cells squish together a little bit. |
@Ephemerality Were you using the client i gave you? That one doesnt have the movement smoothing that the default client has, hence the jiggly movement. |
Nope, vanilla. |
@Jackster35 : my colleagues hate that also (that was the reason I make TeamX mode). They also hate moving virus, they like splitting virus (so, I'll tweak TeamX mode so that moving virus can be configurable (by code, not ini file) in that mode). Thanks God! they love 'eating teammates' of that mode. 😹 Comeback about team cell collision, I think vanilla has changed lately. Weeks ago, I played on vanilla and also crazy about 'pushing thing'. Yesterday, it changed. The new cell will move to its target position. If that position is inside a team cell, it will be pushed to outside of that cell. Direction of second moving is vector AB where A is the center of bigger cell, B is the center of smaller cell. (If A is same to B, any direction makes sense). After the second moving, if it collides with other cell, then it starts pushing. Same situation if the new cell overlaps a smaller cell, but now, the small cell will be moved. In other word, smaller cell of a overlap case will be moved outside the bigger one. |
it is nowhere now. |
https://github.com/forairan/Ogar/blob/master/src/entity/Cell.js#L171
Why you use this 5?
The text was updated successfully, but these errors were encountered: