1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162 |
- import ConfProxy, { ConfListProxy } from "./confProxy"
- import { XlsConfig, xlsAttrAttr, xlsAudioInfo, xlsChapterInfo, xlsChapterLayout, xlsEmitterInfo, xlsGuideInfo, xlsItemKind
- , xlsKaiqiInfo, xlsLanguageLang, xlsLanguageClientText, xlsLanguageSeverHouduan, xlsMathInfo, xlsMergePropInfo, xlsNameName, xlsPackageInfo, xlsPingbiciInfo
- } from "./xlsConfig"
- export default class Gamecfg {
- static attrAttr:ConfProxy<xlsAttrAttr>
- static audioInfo:ConfProxy<xlsAudioInfo>
- static chapterInfo:ConfProxy<xlsChapterInfo>
- static chapterLayoutList:ConfListProxy<xlsChapterLayout>
- static emitterInfo:ConfProxy<xlsEmitterInfo>
- static guideInfo:ConfProxy<xlsGuideInfo>
- static guideInfoList:ConfListProxy<xlsGuideInfo>
- static itemKind:ConfProxy<xlsItemKind>
- static kaiqiInfo:ConfProxy<xlsKaiqiInfo>
- static languageLang:ConfProxy<xlsLanguageLang>
- static languageClientText:ConfProxy<xlsLanguageClientText>
- static languageSeverHouduan:ConfProxy<xlsLanguageSeverHouduan>
- static mathInfo:ConfProxy<xlsMathInfo>
- static mergePropInfo:ConfProxy<xlsMergePropInfo>
- static nameName:ConfProxy<xlsNameName>
- static packageInfo:ConfProxy<xlsPackageInfo>
- static pingbiciInfo:ConfProxy<xlsPingbiciInfo>
- static initLoading(loadSuccess: Function) {
- try {
- new XlsConfig("loadJson",(xls: XlsConfig) => {
- Gamecfg.audioInfo = new ConfProxy("audioInfo",xls.xlsAudioInfo ,"id")
- Gamecfg.languageLang = new ConfProxy("languageLang",xls.xlsLanguageLang ,"key")
- Gamecfg.languageClientText = new ConfProxy("languageClientText",xls.xlsLanguageClientText ,"key")
- Gamecfg.mathInfo = new ConfProxy("mathInfo",xls.xlsMathInfo ,"key")
- Gamecfg.packageInfo = new ConfProxy("packageInfo",xls.xlsPackageInfo ,"id")
- loadSuccess(true)
- })
- } catch (error) {
- loadSuccess(false)
- }
- }
- static init(loadSuccess: Function, progressCallback: Function) {
- try {
- new XlsConfig("pzwj",(xls: XlsConfig) => {
- Gamecfg.attrAttr = new ConfProxy("attrAttr",xls.xlsAttrAttr ,"id")
- Gamecfg.chapterInfo = new ConfProxy("chapterInfo",xls.xlsChapterInfo ,"id")
- Gamecfg.chapterLayoutList = new ConfListProxy("chapterLayoutList",xls.xlsChapterLayout ,"infoId")
- Gamecfg.emitterInfo = new ConfProxy("emitterInfo",xls.xlsEmitterInfo ,"id")
- Gamecfg.guideInfo = new ConfProxy("guideInfo",xls.xlsGuideInfo ,"id")
- Gamecfg.guideInfoList = new ConfListProxy("guideInfoList",xls.xlsGuideInfo ,"event")
- Gamecfg.itemKind = new ConfProxy("itemKind",xls.xlsItemKind ,"kind")
- Gamecfg.kaiqiInfo = new ConfProxy("kaiqiInfo",xls.xlsKaiqiInfo ,"id")
- Gamecfg.languageSeverHouduan = new ConfProxy("languageSeverHouduan",xls.xlsLanguageSeverHouduan ,"key")
- Gamecfg.mergePropInfo = new ConfProxy("mergePropInfo",xls.xlsMergePropInfo ,"id")
- Gamecfg.nameName = new ConfProxy("nameName",xls.xlsNameName ,"frist")
- Gamecfg.pingbiciInfo = new ConfProxy("pingbiciInfo",xls.xlsPingbiciInfo ,"id")
- loadSuccess(true)
- }, progressCallback)
- } catch (error) {
- loadSuccess(false)
- }
- }
- }
|