Skip to content

Commit

Permalink
✨ season beta definitions/main.mjs
Browse files Browse the repository at this point in the history
  • Loading branch information
o4kapuk committed Dec 19, 2024
1 parent 771a91b commit 3f1f33e
Show file tree
Hide file tree
Showing 12 changed files with 106 additions and 2 deletions.
2 changes: 1 addition & 1 deletion 6545074f7ab4df5263b02563/main.mjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { } from 'game/utils';
import { } from 'game/prototypes';
import { } from 'game/constants';
import { } from 'arena/season_beta/capture_the_flag/basic';

export function loop() {
// Your code goes here
console.log('season_beta basic');
}
2 changes: 1 addition & 1 deletion 6545074f7ab4df5263b02564/main.mjs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { } from 'game/utils';
import { } from 'game/prototypes';
import { } from 'game/constants';
import { } from 'arena/season_beta/capture_the_flag/advanced';

export function loop() {
// Your code goes here
console.log('season_beta');
}
8 changes: 8 additions & 0 deletions 6545074f7ab4df5263b02567/main.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { } from 'game/utils';
import { } from 'game/prototypes';
import { } from 'game/constants';
import { } from 'arena/season_beta/collect_and_control/basic';

export function loop() {
// Your code goes here
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
declare module "arena/season_beta/collect_and_control/basic" {
export * from "arena/season_beta/collect_and_control/basic/prototypes";
export * from "arena/season_beta/collect_and_control/basic/constants";
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
declare module "arena/season_beta/collect_and_control/basic/constants" {
export const RESOURCE_SCORE = 'score';
export const EFFECT_FREEZE = 'freeze';
export const EFFECT_HEAL = 'heal';
export const EFFECT_DAMAGE = 'damage';
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
declare module "arena/season_beta/collect_and_control/basic/prototypes" {
import { GameObject } from "game/prototypes";
import { EFFECT_FREEZE, EFFECT_DAMAGE, EFFECT_HEAL } from "arena/season_beta/collect_and_control/basic/constants";

type AreaEffectType =
typeof EFFECT_FREEZE |
typeof EFFECT_DAMAGE |
typeof EFFECT_HEAL;

/** An object that applies an effect of the specified type to all creeps at the same time */
export class AreaEffect extends GameObject {
/** The effect type */
readonly effect: AreaEffectType;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
declare module "arena/season_beta/collect_and_control/basic/prototypes" {
import {GameObject, ResourceType} from "game/prototypes";

/** Key game object for this arena. Transfer the corresponding resource to the collector to win the game */
export class ScoreCollector extends GameObject {
/** Whether you have control over this collector */
my?: boolean;

/**The type of the resource this collector accepts */
resourceType: ResourceType;

/** Current collected score number of the owner */
score: number;

/** Total number of score needed to win instantly */
scoreTotal: number;
}
}
8 changes: 8 additions & 0 deletions 6545074f7ab4df5263b02568/main.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { } from 'game/utils';
import { } from 'game/prototypes';
import { } from 'game/constants';
import { } from 'arena/season_beta/collect_and_control/advanced';

export function loop() {
// Your code goes here
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
declare module "arena/season_beta/collect_and_control/advanced" {
export * from "arena/season_beta/collect_and_control/advanced/prototypes";
export * from "arena/season_beta/collect_and_control/advanced/constants";
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
declare module "arena/season_beta/collect_and_control/advanced/constants" {
export const RESOURCE_SCORE_X = 'score_x';
export const RESOURCE_SCORE_Y = 'score_y';
export const RESOURCE_SCORE_Z = 'score_z';
export const EFFECT_FREEZE = 'freeze';
export const EFFECT_HEAL = 'heal';
export const EFFECT_DAMAGE = 'damage';
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
declare module "arena/season_beta/collect_and_control/advanced/prototypes" {
import { GameObject } from "game/prototypes";
import { EFFECT_FREEZE, EFFECT_DAMAGE, EFFECT_HEAL } from "arena/season_beta/collect_and_control/advanced/constants";

type AreaEffectType =
typeof EFFECT_FREEZE |
typeof EFFECT_DAMAGE |
typeof EFFECT_HEAL;

/** An object that applies an effect of the specified type to all creeps at the same time */
export class AreaEffect extends GameObject {
/** The effect type */
readonly effect: AreaEffectType;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
declare module "arena/season_beta/collect_and_control/advanced/prototypes" {
import {GameObject, ResourceType} from "game/prototypes";

/** Key game object for this arena. Transfer the corresponding resource to the collector to win the game */
export class ScoreCollector extends GameObject {
/** Whether you have control over this collector */
my?: boolean;

/**The type of the resource this collector accepts */
resourceType: ResourceType;

/** Current collected score number of the owner */
score: number;

/** Total number of score needed to win instantly */
scoreTotal: number;
}
}

0 comments on commit 3f1f33e

Please sign in to comment.