/dports/games/wesnoth/wesnoth-1.14.17/data/ai/micro_ais/cas/ |
H A D | ca_herding_attack_close_enemy.lua | 57 local rating = -M.distance_between(x, y, enemy.x, enemy.y) * 100. 60 rating = rating - M.distance_between(x, y, single_sheep.x, single_sheep.y) 63 rating = rating + M.distance_between(enemy.x, enemy.y, dog.x, dog.y) / 100. 96 local dist = M.distance_between(enemy.x, enemy.y, single_sheep.x, single_sheep.y) 111 M.distance_between(x, y, closest_sheep.x, closest_sheep.y) 112 - M.distance_between(x, y, closest_enemy.x, closest_enemy.y) 115 rating = rating - M.distance_between(x, y, closest_sheep.x, closest_sheep.y) 118 … rating = rating + M.distance_between(closest_enemy.x, closest_enemy.y, dog.x, dog.y) / 100.
|
H A D | ca_wolves_move.lua | 41 dist = dist + M.distance_between(wolf.x, wolf.y, prey_unit.x, prey_unit.y) 50 …return M.distance_between(a.x, a.y, target.x, target.y) > M.distance_between(b.x, b.y, target.x, t… 56 local dist_1t = M.distance_between(x, y, target.x, target.y) 83 local dst = M.distance_between(x, y, wolves[j].x, wolves[j].y) 88 local dist_t = M.distance_between(x, y, target.x, target.y) 89 local dist_1t = M.distance_between(wolf1[1], wolf1[2], target.x, target.y)
|
H A D | ca_herding_herd_sheep.lua | 49 local sheep_rating = M.distance_between(c_x, c_y, single_sheep.x, single_sheep.y) / 10. 56 local dist = M.distance_between(x, y, single_sheep.x, single_sheep.y) 59 …if (M.distance_between(x, y, c_x, c_y) <= M.distance_between(single_sheep.x, single_sheep.y, c_x, … 63 rating = rating - M.distance_between(x, y, dog.x, dog.y) / 100.
|
H A D | ca_swarm_move.lua | 42 … if (M.distance_between(unit.x, unit.y, unit_noMP.x, unit_noMP.y) <= vision_distance) then 49 rating = rating + M.distance_between(x, y, unit.x, unit.y) 52 rating = rating - M.distance_between(x, y, close_unit.x, close_unit.y) 58 local dist = M.distance_between(x, y, enemy.x, enemy.y)
|
H A D | ca_fast_move.lua | 57 local dist = M.distance_between(v1[1], v1[2], v2[1], v2[2]) 70 dist = M.distance_between(village[1], village[2], leader.x, leader.y) 96 * M.distance_between(x, y, village[1], village[2]) 108 local dist_a = M.distance_between(leader.x, leader.y, a.x, a.y) 109 local dist_b = M.distance_between(leader.x, leader.y, b.x, b.y) 126 local dist = M.distance_between(unit.x, unit.y, goal.x, goal.y) 204 local rating = -M.distance_between(loc[1], loc[2], short_goal[1], short_goal[2]) 205 local other_rating = -M.distance_between(loc[1], loc[2], goal.x, goal.y) / 10.
|
H A D | ca_herding_sheep_runs_dog.lua | 33 …if (M.distance_between(dog.x, dog.y, c_x, c_y) >= M.distance_between(sheep.x, sheep.y, c_x, c_y)) … 37 return M.distance_between(x, y, c_x, c_y) * sign
|
H A D | ca_forest_animals_tusker_attack.lua | 38 local dist = M.distance_between(tusker.x, tusker.y, enemy.x, enemy.y) 54 local rating = -M.distance_between(x, y, target.x, target.y) 56 if (M.distance_between(x, y, tusklet.x, tusklet.y) == 1) then rating = rating + 0.1 end
|
H A D | ca_wolves_multipacks_wander.lua | 88 rating = rating - M.distance_between(x, y, goal[1], goal[2]) 114 return -M.distance_between(x, y, cg[1], cg[2]) 124 local rating = -M.distance_between(x, y, goto_hex[1], goto_hex[2]) 125 rating = rating -M.distance_between(x, y, goal[1], goal[2]) / 100.
|
H A D | ca_forest_animals_move.lua | 68 if (M.distance_between(unit.x, unit.y, enemy.x, enemy.y) <= unit.max_moves+1) then 102 local dist = M.distance_between(loc[1], loc[2], unit.x, unit.y) 126 if (M.distance_between(unit.x, unit.y, enemy.x, enemy.y) <= unit.max_moves+1) then 140 local dist = M.distance_between(enemy.x, enemy.y, x, y)
|
H A D | ca_stationed_guardian.lua | 42 local dist_s = M.distance_between(cfg.station_x, cfg.station_y, enemy.x, enemy.y) 43 …local dist_g = M.distance_between(cfg.guard_x or cfg.station_x, cfg.guard_y or cfg.station_y, enem… 87 local dist = M.distance_between(hex[1], hex[2], target.x, target.y)
|
H A D | ca_herding_sheep_runs_enemy.lua | 20 …if (M.distance_between(single_sheep.x, single_sheep.y, enemy.x, enemy.y) <= attention_distance) th… 45 rating = rating + M.distance_between(x, y, enemy.x, enemy.y)
|
H A D | ca_swarm_scatter.lua | 36 if (M.distance_between(unit.x, unit.y, enemy.x, enemy.y) <= vision_distance) then 45 rating = rating + M.distance_between(x, y, enemy.x, enemy.y)
|
H A D | ca_forest_animals_tusklet_move.lua | 38 local dist = M.distance_between(tusker.x, tusker.y, tusklet.x, tusklet.y) 45 return - M.distance_between(x, y, goto_tusker.x, goto_tusker.y)
|
H A D | ca_herding_dog_move.lua | 30 av_dist = av_dist + M.distance_between(x, y, cfg.herd_x, cfg.herd_y) 42 - math.abs(M.distance_between(x, y, cfg.herd_x, cfg.herd_y) - av_dist)
|
H A D | ca_wolves_multipacks_functions.lua | 64 local dist1 = M.distance_between(wolf.x, wolf.y, pack[1].x, pack[1].y) 65 local dist2 = M.distance_between(wolf.x, wolf.y, pack[2].x, pack[2].y) 104 … dist = dist + M.distance_between(nopack_wolf.x, nopack_wolf.y, pack_wolf.x, pack_wolf.y)
|
H A D | ca_messenger_escort_move.lua | 56 local messenger_rating = 1. / (M.distance_between(x, y, m.x, m.y) + 2.) 70 base_rating = base_rating + 1. / (M.distance_between(x, y, e.x, e.y) + 2.)
|
H A D | ca_healer_move.lua | 46 if (M.distance_between(healee.x, healee.y, healer.x, healer.y) == 1) then 80 if (M.distance_between(healee.x, healee.y, loc[1], loc[2]) == 1) then
|
H A D | ca_zone_guardian.lua | 32 local dist = M.distance_between(guardian.x, guardian.y, enemy.x, enemy.y) 74 local dist = M.distance_between(hex[1], hex[2], target.x, target.y)
|
H A D | ca_hang_out.lua | 98 local rating = -M.distance_between(x, y, loc[1], loc[2]) 105 local rating = rating - M.distance_between(x, y, unit.x, unit.y) / 1000.
|
/dports/games/wesnoth/wesnoth-1.14.17/data/campaigns/Eastern_Invasion/ai/ |
H A D | ca_ogres_flee.lua | 46 local dist_top_left = M.distance_between(r[1], r[2], 4, 1) 47 local dist_top_right = M.distance_between(r[1], r[2], 40, 1) 61 local dist = M.distance_between(r[1], r[2], e.x, e.y) 71 local dist = M.distance_between(r[1], r[2], u_noMP.x, u_noMP.y)
|
/dports/games/wesnoth/wesnoth-1.14.17/data/campaigns/Son_Of_The_Black_Eye/ai/ |
H A D | ca_transport_S6.lua | 61 … if (not u.variables.landed) and (M.distance_between(u.x, u.y, dst[1], dst[2]) <= u.moves) then 68 local rating = -M.distance_between(r[1], r[2], dst[1], dst[2]) / 100. 140 local rating = -M.distance_between(r[1], r[2], dst[1], dst[2])
|
/dports/games/wesnoth/wesnoth-1.14.17/data/ai/formula/ |
H A D | patrol.fai | 6 -distance_between(me.loc, unit.loc) 28 if( distance_between( closest_unit(ai, me).loc, me.loc ) > me.moves-1,
|
/dports/math/minizinc-ide/MiniZincIDE-2.5.5/cp-profiler/src/cpprofiler/tree/cursors/ |
H A D | layout_cursor.cpp | 51 static int distance_between(const Shape &s1, const Shape &s2) in distance_between() function 77 const auto distance = distance_between(s1, s2); in combine_shapes() 126 const auto distance = distance_between(s1, s2); in merge_left() 240 distances[i] = distance_between(s1, s2); in compute_distances()
|
/dports/games/wesnoth/wesnoth-1.14.17/src/tests/ |
H A D | test_map_location.cpp | 92 std::cout << "(std::make_pair(" << distance_between(a,b) << ",\t\"" in characterization_distance_direction() 97 BOOST_CHECK_EQUAL( expected_dist, distance_between(a,b) ); in characterization_distance_direction() 98 BOOST_CHECK_EQUAL( expected_dist, distance_between(b,a) ); in characterization_distance_direction() 303 BOOST_CHECK_EQUAL(distance_between(loc,temp), 1); in reality_check_get_direction_helper()
|
/dports/www/osrm-backend/osrm-backend-5.26.0/src/extractor/intersection/ |
H A D | coordinate_extractor.cpp | 1056 const auto distance_between = util::coordinate_calculation::haversineDistance( in SampleCoordinates() local 1059 if (carry_length + distance_between >= rate) in SampleCoordinates() 1070 (std::min(max_sample_length - total_length, distance_between) + carry_length) / in SampleCoordinates() 1076 base_sampling + sample_value * rate, 0, distance_between); in SampleCoordinates() 1084 carry_length = (distance_between + carry_length) - (num_samples * rate); in SampleCoordinates() 1089 carry_length += distance_between; in SampleCoordinates() 1092 total_length += distance_between; in SampleCoordinates()
|