| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- /**
- * @description 互推界面
- * @author kaka
- */
- const { ccclass, property } = cc._decorator;
- @ccclass
- export default class MoreGame extends cc.Component {
- @property(cc.Node)
- node_sv: cc.Node = null;
- @property(cc.Prefab)
- moreGameNormalNode: cc.Prefab = null
- private normalDatas = null
- start() {
- this.node.setContentSize(cc.winSize)
- gData.moreGame.init();
- gData.gameData.popTableScreenADLogic(11);
- }
- update() {
- if (gData.moreGame.init_moreGameList) {
- this.initView();
- }
- }
- lateUpdate() {
- gData.moreGame.init_moreGameList = false;
- }
- initView() {
- this.normalDatas = gData.moreGame.moreGameList.normal;
- let data = [];
- let len = this.normalDatas.length;
- for (var i = 0; i < len; i++) {
- let pfbType = 0;
- let obj = {
- item_data: this.normalDatas[i],
- pfbType: pfbType
- }
- data.push(obj);
- if (i == 1) {
- pfbType = 1;
- let obj = {
- item_data: gData.moreGame.moreGameList.banner,
- pfbType: pfbType
- }
- data.push(obj);
- }
- }
- this.node_sv.emit('srollview-init', data)
- }
-
- onClickClose() {
- }
- }
|