Merge branch 'master' of https://git.frank-ebner.de/FHWS/Indoor
This commit is contained in:
@@ -81,7 +81,7 @@ namespace NM {
|
||||
// to-be-walked distance;
|
||||
const float toBeWalkedDist = params.getToBeWalkedDistance();
|
||||
const float toBeWalkedDistSafe = 0.75 + toBeWalkedDist * 1.1;
|
||||
const float toBeWalkedDistKld = (kld * qualityWifi);
|
||||
const float toBeWalkedDistKld = (kld * qualityWifi);
|
||||
|
||||
// construct reachable region
|
||||
NavMeshSub<Tria> reachable(params.start, toBeWalkedDistKld); //EDIT HERE: ADD TOBEWALKDISTKLD...
|
||||
|
||||
@@ -59,7 +59,7 @@ namespace NM {
|
||||
|
||||
// to-be-walked distance;
|
||||
const float toBeWalkedDist = params.getToBeWalkedDistance();
|
||||
const float toBeWalkedDistSafe = 0.75 + toBeWalkedDist * 1.1;
|
||||
const float toBeWalkedDistSafe = 0.75 + toBeWalkedDist * 1.1;
|
||||
|
||||
// construct reachable region
|
||||
NavMeshSub<Tria> reachable(params.start, toBeWalkedDistSafe);
|
||||
@@ -73,15 +73,15 @@ namespace NM {
|
||||
// is above destination reachable?
|
||||
if (dstTria) {
|
||||
|
||||
re.heading = params.heading; // heading was OK -> keep
|
||||
re.location.pos = dstTria->toPoint3(dst); // new destination position
|
||||
re.location.tria = dstTria; // new destination triangle
|
||||
re.heading = params.heading; // heading was OK -> keep
|
||||
re.location.pos = dstTria->toPoint3(dst); // new destination position
|
||||
re.location.tria = dstTria; // new destination triangle
|
||||
++hits;
|
||||
|
||||
} else {
|
||||
|
||||
NavMeshRandom<Tria> rnd = reachable.getRandom(); // random-helper
|
||||
re.location = rnd.draw(); // get a random destianation
|
||||
NavMeshRandom<Tria> rnd = reachable.getRandom(); // random-helper
|
||||
re.location = rnd.draw(); // get a random destianation
|
||||
re.heading = Heading(params.start.pos.xy(), re.location.pos.xy()); // update the heading
|
||||
++misses;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user