import { respath } from "../../constants/respath"
import { ResourceManager } from "../../models/ResourceManager"
import { ScoreAdd } from "../ScoreAdd"

export function G_ShowScoreTips(text: string, parent: any): void {
  ResourceManager.getInstance().loadPrefab(respath.score_add_ui_res(), (go: any) => {
    const prefab = go.create()
    const score = parent.addChild(prefab).getComponent(ScoreAdd)
    score.onSetText(text)
  })
}
