Slash-The-Hordes/assets/Scripts/Game/Player/PlayerUI/PlayerUI.ts
2022-11-08 19:45:57 +01:00

14 lines
410 B
TypeScript

import { Component, _decorator } from "cc";
import { UnitHealth } from "../UnitHealth";
import { PlayerHealthUI } from "./PlayerHealthUI";
const { ccclass, property } = _decorator;
@ccclass("PlayerUI")
export class PlayerUI extends Component {
@property(PlayerHealthUI) private healthUI: PlayerHealthUI;
public init(playerHealth: UnitHealth): void {
this.healthUI.init(playerHealth);
}
}