mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-07-12 21:36:05 +00:00
Changed consolex to console logging (#1036)
## Description: Changed from consolex to console ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced - [x] I understand that submitting code with bugs that could have been caught through manual testing blocks releases and new features for all contributors ## Please put your Discord username so you can be contacted if a bug or regression is found: @qqkedsi
This commit is contained in:
@@ -1,4 +1,3 @@
|
||||
import { consolex } from "../Consolex";
|
||||
import { Game } from "../game/Game";
|
||||
import { GameMap, TileRef } from "../game/GameMap";
|
||||
import { PseudoRandom } from "../PseudoRandom";
|
||||
@@ -117,11 +116,11 @@ export class PathFinder {
|
||||
dist: number = 1,
|
||||
): TileResult {
|
||||
if (curr === null) {
|
||||
consolex.error("curr is null");
|
||||
console.error("curr is null");
|
||||
return { type: PathFindResultType.PathNotFound };
|
||||
}
|
||||
if (dst === null) {
|
||||
consolex.error("dst is null");
|
||||
console.error("dst is null");
|
||||
return { type: PathFindResultType.PathNotFound };
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
import { PriorityQueue } from "@datastructures-js/priority-queue";
|
||||
import { consolex } from "../Consolex";
|
||||
import { GameMap, TileRef } from "../game/GameMap";
|
||||
import { AStar, PathFindResultType } from "./AStar";
|
||||
|
||||
@@ -154,7 +153,7 @@ export class SerialAStar implements AStar {
|
||||
Math.abs(this.gameMap.y(a) - this.gameMap.y(b)))
|
||||
);
|
||||
} catch {
|
||||
consolex.log("uh oh");
|
||||
console.log("uh oh");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user