mirror of
https://gitee.com/jisol/jisol-game/
synced 2025-06-26 19:34:47 +00:00
40 lines
956 B
TypeScript
40 lines
956 B
TypeScript
import { _decorator, Component, Node } from 'cc';
|
|
import JNScrollViewItem from '../../../../extensions/ngame/assets/ngame/util/components/scrollview/JNScrollViewItem';
|
|
import { TB } from '../../config/data/schema';
|
|
import { Label } from 'cc';
|
|
import GBattleModeManager, { BattleMode } from '../../battle/GBattleModeManager';
|
|
import { app, TD } from '../../App';
|
|
import { GUI } from '../UIConfig';
|
|
const { ccclass, property } = _decorator;
|
|
|
|
@ccclass('DungeonShowItem')
|
|
export class DungeonShowItem extends JNScrollViewItem<TB.TbGSysDungeon> {
|
|
|
|
//副本名称
|
|
@property(Label)
|
|
title:Label;
|
|
|
|
onInit(){
|
|
|
|
this.onUpdateView();
|
|
|
|
}
|
|
|
|
onUpdateView(){
|
|
|
|
this.title.string = this.data.name;
|
|
|
|
}
|
|
|
|
//点击副本
|
|
onClickDungeon(){
|
|
|
|
GBattleModeManager.getIns().Open(BattleMode[`${this.data.type}`],true,TD[`${this.data.tigs}`].getDataList()[0].data);
|
|
app.layer.Close(GUI.DungeonView);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|