import AppPlatform from "../../FrameWork/Util/AppPlatform"; import Common5 from "../../Platform/th/Common5"; import PrefabManage, { GameType } from "../PrefabManager/PrefabManage"; import JuQingTipView from "./JuQingTipView"; const {ccclass, property} = cc._decorator; let AllJuQingTipConfig = [ {id:0,tag:'钱总中毒',tipStr:'1.点击昏迷的钱总\n2.点击桌子上的手机\n3.点击桌子上的印章\n4.点击凳子上的空盒子'}, {id:1,tag:'妈妈被害',tipStr:'1.点击地上的脚印\n2.点击地上的针\n3.点击床上的母亲'}, {id:2,tag:'救援白诗诗',tipStr:'1.拖动碘酒到女生伤口处\n2.拖动止血粉到女生伤口处\n3.拖动纱布到女生伤口处\n4.拖动抗生素到女生伤口处'}, ] @ccclass export default class JuQingTipNode extends cc.Component { @property(cc.Node) tipBtn: cc.Node = null; @property(cc.Node) tipADBtn: cc.Node = null; @property({ displayName: '提示索引' }) tipIndex: number = 0; // LIFE-CYCLE CALLBACKS: // onLoad () {} start () { } juQingTipBtnClick(){ this.showTipView() } juQingTipADBtnClick(){ let tab = { onClose: (finish)=>{ if (finish) { Common5.ReportDY("inLevel", '剧情关卡'+this.tipIndex+'-AD-提示'); this.tipADBtn.active = false this.tipBtn.active = true this.showTipView() } else{ Common5.showTips_custom("广告未观看完"); } },onFailed:()=>{ } } AppPlatform.playVideo_custom(tab) } showTipView(){ let config = null for(let i=0;i{ prefabNode.getComponent(JuQingTipView).initView(config) }) } // update (dt) {} }