Skip to content

Commit

Permalink
test square
Browse files Browse the repository at this point in the history
  • Loading branch information
Skydev0h committed Dec 30, 2023
1 parent 31565ee commit 393d1bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion contracts/task4.fc
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ const int infinity_price = (1 << infinity_shift) - 1;
repeat(lx) {
int c = t.t:(x);
if (c == "S"u) { Sx = x; Sy = y; }
int ctp = tile_prices.t:(c) + ((abs(Ex - x) + abs(Ey - y)) << astar_dist_shift);
int ctp = tile_prices.t:(c) + (((Ex - x) * (Ex - x) + (Ey - y) * (Ey - y)) << astar_dist_shift);
if (c == "E"u) { ctp = ctp | fin_bit;}
r~t:+( ctp );
x += 1;
Expand Down

0 comments on commit 393d1bc

Please sign in to comment.