-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
71 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
src/constants/research_abilities.sync-conflict-20240218-152143-56LAXKK.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import data from "./data.json" | ||
|
||
const RESEARCH_ABILITIES: { [name: number]: number } = {} | ||
|
||
data.Ability.forEach((ability) => { | ||
const target = ability.target | ||
if (typeof target !== "string") { | ||
const research = target.Research | ||
if (research !== undefined) { | ||
RESEARCH_ABILITIES[ability.id] = research.upgrade | ||
return | ||
} | ||
} | ||
}) | ||
|
||
// Returns object with keys as ability id and value as resulting unit id | ||
|
||
// COMMANDCENTERTRAIN_SCV: SCV | ||
// Exported: | ||
// {524, 45} | ||
|
||
console.assert( | ||
Object.keys(RESEARCH_ABILITIES).length === 118, | ||
`${Object.keys(RESEARCH_ABILITIES).length} is not 118` | ||
) | ||
|
||
export default RESEARCH_ABILITIES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters