Spaces:
Running
Running
v1.33.29 — FOW 128 grid + model fog + flicker + damage + pathfinding + water fixes
Browse files- src/game/sim.js +9 -0
src/game/sim.js
CHANGED
|
@@ -4728,6 +4728,15 @@ function unitTick(dt){
|
|
| 4728 |
enter this branch because they have no overlap (`sepHits===0`). Long
|
| 4729 |
marches keep full speed and only fan out as the column arrives. */
|
| 4730 |
if(sepHits&&distGoal<60&&umarch[i]!==1){mvx*=0.12;mvy*=0.12;}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4731 |
mvx+=sepVX;mvy+=sepVY;
|
| 4732 |
if(!T.air){
|
| 4733 |
const bc=bGrid[clamp(uy[i]/BCS|0,0,BGW-1)*BGW+clamp(ux[i]/BCS|0,0,BGW-1)];
|
|
|
|
| 4728 |
enter this branch because they have no overlap (`sepHits===0`). Long
|
| 4729 |
marches keep full speed and only fan out as the column arrives. */
|
| 4730 |
if(sepHits&&distGoal<60&&umarch[i]!==1){mvx*=0.12;mvy*=0.12;}
|
| 4731 |
+
/* CROWD ARRIVAL. Forty units sent to one point steer down the same flow
|
| 4732 |
+
cells, meet, and keep pressing into each other forever — the blob
|
| 4733 |
+
shivers and the rear never routes around. Close to goal and physically
|
| 4734 |
+
wedged against two or more others IS arrival: stop, drop the field,
|
| 4735 |
+
idle-acquire. Formations, patrols, marches and the commander exempt. */
|
| 4736 |
+
if(sepHits>=2&&distGoal<46&&!engaging&&umarch[i]!==1&&(ustate[i]===1||ustate[i]===2)&&
|
| 4737 |
+
uPatrolRoute[i]<0&&uMoveCohort[i]<0&&i!==heroIdx&&!T.air){
|
| 4738 |
+
ustate[i]=0; utx[i]=ux[i]; uty[i]=uy[i]; ufield[i]=-1;
|
| 4739 |
+
}
|
| 4740 |
mvx+=sepVX;mvy+=sepVY;
|
| 4741 |
if(!T.air){
|
| 4742 |
const bc=bGrid[clamp(uy[i]/BCS|0,0,BGW-1)*BGW+clamp(ux[i]/BCS|0,0,BGW-1)];
|