Skip to content

Commit

Permalink
packed quad coords removed potential circular dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
CarsonBurke committed Feb 15, 2024
1 parent b059dc3 commit 6f0c79e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
7 changes: 1 addition & 6 deletions src/constants/general.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { packCoord } from '../other/codec'
// This file should not have any imports to avoid circular dependencies

export enum PlayerRelationships {
ally,
Expand Down Expand Up @@ -1225,11 +1225,6 @@ export const quadAttackMemberOffsets = [
y: 0,
},
]
/**
* @deprecated
* should replace this with something that doesn't create a circular dependency
*/
export const packedQuadAttackMemberOffsets = quadAttackMemberOffsets.map(coord => packCoord(coord))

export enum Result {
fail,
Expand Down
5 changes: 4 additions & 1 deletion src/room/creeps/roleManagers/antifa/quad.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import {
RoomTypes,
WorkTypes,
customColors,
packedQuadAttackMemberOffsets,
quadAttackMemberOffsets,
} from '../../../../constants/general'
import {
Expand All @@ -31,6 +30,10 @@ import { RoomManager } from 'room/room'

const rangedFleeRange = 5
const meleeFleeRange = 3
/**
* should replace this with something that doesn't create a circular dependency
*/
const packedQuadAttackMemberOffsets = quadAttackMemberOffsets.map(coord => packCoord(coord))

interface EnemyThreatData {
coords: Uint8Array
Expand Down

0 comments on commit 6f0c79e

Please sign in to comment.