More progress.
- AMBUSH flag on nodes makes them blind and untargetable when getting `startnode` and `goalnode` for `FindPath()`. This is useful for indicating a node should be skipped when tele/portaling, so the current path can be preserved. - Setup is simple: place nodes behind lines that tele/portal entities and mark them as AMBUSH. Other changes: - Restored global array since blockmap is not a viable option here. - Added MAPINFO `pathing` flag which enables pathing by default. - Added NOPATHING flag to disable pathing entirely, useful for maps that have pathing enabled. - Added `ReachedNode(Actor mo)` virtual, responsible for handling node traversal. - Nodes now make use of MeleeRange to limit their sight checking functions.
This commit is contained in:
parent
ad52e2cc1e
commit
81ebd8c8c4
14 changed files with 211 additions and 83 deletions
|
|
@ -592,7 +592,7 @@ bool P_TeleportMove(AActor* thing, const DVector3 &pos, bool telefrag, bool modi
|
|||
thing->CheckSectorTransition(oldsec);
|
||||
}
|
||||
}
|
||||
|
||||
thing->CallReachedNode(thing->goal);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -2613,6 +2613,7 @@ bool P_TryMove(AActor *thing, const DVector2 &pos,
|
|||
thing->LinkToWorld(&ctx);
|
||||
P_FindFloorCeiling(thing);
|
||||
thing->ClearInterpolation();
|
||||
thing->CallReachedNode(thing->goal);
|
||||
portalcrossed = true;
|
||||
tm.portalstep = false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue