mirror of
https://github.com/Sheldan/canvas.git
synced 2026-04-19 21:17:42 +00:00
survivors: fixing build
This commit is contained in:
@@ -21,6 +21,7 @@ export class Player implements Drawable, Acting, Healthy {
|
|||||||
|
|
||||||
constructor(position: Vector) {
|
constructor(position: Vector) {
|
||||||
this._position = position;
|
this._position = position;
|
||||||
|
this._effectiveStats = new PlayerStats()
|
||||||
}
|
}
|
||||||
|
|
||||||
draw(ctx: CanvasRenderingContext2D) {
|
draw(ctx: CanvasRenderingContext2D) {
|
||||||
@@ -38,6 +39,7 @@ export class Player implements Drawable, Acting, Healthy {
|
|||||||
let tempStats = new PlayerStats();
|
let tempStats = new PlayerStats();
|
||||||
tempStats.resetToBasic()
|
tempStats.resetToBasic()
|
||||||
player._tempStats = tempStats;
|
player._tempStats = tempStats;
|
||||||
|
player.statsChanged()
|
||||||
player._speed = new Vector(0, 0)
|
player._speed = new Vector(0, 0)
|
||||||
player._status = new PlayerStatus(10, 0, 0);
|
player._status = new PlayerStatus(10, 0, 0);
|
||||||
return player;
|
return player;
|
||||||
|
|||||||
@@ -1,8 +1,9 @@
|
|||||||
import type {ChanceEntry, Item} from "./interfaces.ts";
|
import type {ChanceEntry, Item} from "./interfaces.ts";
|
||||||
import {Player, PlayerStats} from "./Player.ts";
|
import {Player} from "./Player.ts";
|
||||||
import {randomItem} from "./utils.ts";
|
import {randomItem} from "./utils.ts";
|
||||||
import {ChainBall, HomingPistol, Pistol, Spear, SpreadWeapon} from "./weapons.ts";
|
import {ChainBall, HomingPistol, Pistol, Spear, SpreadWeapon} from "./weapons.ts";
|
||||||
import type {World} from "./World.ts";
|
import type {World} from "./World.ts";
|
||||||
|
import {PlayerStats} from "./stats.ts";
|
||||||
|
|
||||||
export enum Rarity {
|
export enum Rarity {
|
||||||
GARBAGE= 'GARBAGE',
|
GARBAGE= 'GARBAGE',
|
||||||
|
|||||||
@@ -4,13 +4,13 @@ import {Player} from "./Player.ts";
|
|||||||
import {
|
import {
|
||||||
HomingProjectile,
|
HomingProjectile,
|
||||||
Projectile,
|
Projectile,
|
||||||
ProjectileStats,
|
|
||||||
StraightProjectile,
|
StraightProjectile,
|
||||||
ChainBallProjectile,
|
ChainBallProjectile,
|
||||||
StraightMeleeWeaponProjectile
|
StraightMeleeWeaponProjectile
|
||||||
} from "./projectile.ts";
|
} from "./projectile.ts";
|
||||||
import {World} from "./World.ts";
|
import {World} from "./World.ts";
|
||||||
import {Vector} from "./base.ts";
|
import {Vector} from "./base.ts";
|
||||||
|
import {ProjectileStats} from "./stats.ts";
|
||||||
|
|
||||||
export abstract class BasicWeapon implements Weapon {
|
export abstract class BasicWeapon implements Weapon {
|
||||||
protected offset: Vector;
|
protected offset: Vector;
|
||||||
|
|||||||
Reference in New Issue
Block a user