// Token: 0x06001961 RID: 6497 RVA: 0x000E5898 File Offset: 0x000E3A98 public static void ObjAction3dESTextureLoad(AppMain.OBS_ACTION3D_ES_WORK obj_3des, AppMain.OBS_DATA_WORK data_work, string filename, int index, AMS_AMB_HEADER archive, bool load_tex) { AMS_AMB_HEADER ams_AMB_HEADER = null; if (archive != null) { obj_3des.flag |= 131072U; } if (filename != null && filename != "") { ams_AMB_HEADER = AmFs.readAMBFile(AppMain.ObjDataLoad(data_work, filename, archive)); if (archive != null && ams_AMB_HEADER == null) { obj_3des.flag &= 4294836223U; ams_AMB_HEADER = AmFs.readAMBFile(AppMain.ObjDataLoad(data_work, filename, null)); } } else if (archive != null) { ams_AMB_HEADER = AmFs.readAMBFile(AppMain.ObjDataLoadAmbIndex(data_work, index, archive)); if (ams_AMB_HEADER == null) { obj_3des.flag &= 4294836223U; } } else if (data_work != null) { ams_AMB_HEADER = AmFs.readAMBFile(AppMain.ObjDataGetInc(data_work)); } if (ams_AMB_HEADER == null) { return; } obj_3des.ambtex = ams_AMB_HEADER; if (data_work != null) { obj_3des.ambtex_data_work = data_work; } if (load_tex) { AppMain.TXB_HEADER txb = AppMain.readTXBfile(AmBind.Get(ams_AMB_HEADER, 0)); uint num = AppMain.amTxbGetCount(txb); obj_3des.texlistbuf = null; AppMain.nnSetUpTexlist(out obj_3des.texlist, ( int )num, ref obj_3des.texlistbuf); if (AppMain.obj_load_initial_set_flag) { AppMain.OBS_LOAD_INITIAL_WORK obs_LOAD_INITIAL_WORK = AppMain.obj_load_initial_work; if (obs_LOAD_INITIAL_WORK.es_num < 255) { obs_LOAD_INITIAL_WORK.obj_3des[obs_LOAD_INITIAL_WORK.es_num] = obj_3des; obs_LOAD_INITIAL_WORK.es_num++; } } obj_3des.tex_reg_index = AppMain.amTextureLoad(obj_3des.texlist, AppMain.amTxbGetTexFileList(txb), filename, ams_AMB_HEADER); obj_3des.flag |= 1073741824U; } }
private static bool ObjLoadInitDraw() { AppMain.OBS_LOAD_INITIAL_WORK objLoadInitialWork = AppMain.obj_load_initial_work; for (int index = 0; index < objLoadInitialWork.obj_num; ++index) { uint?p_disp_flag = new uint?(); AppMain.ObjDrawAction3DNN(objLoadInitialWork.obj_3d[index], new AppMain.VecFx32?(), new AppMain.VecU16?(), new AppMain.VecFx32?(), ref p_disp_flag); } for (int index = 0; index < objLoadInitialWork.es_num; ++index) { uint?p_disp_flag = new uint?(); AppMain.ObjDrawAction3DES(objLoadInitialWork.obj_3des[index], new AppMain.VecFx32?(), new AppMain.VecU16?(), new AppMain.VecFx32?(), ref p_disp_flag); } return(true); }
// Token: 0x06001942 RID: 6466 RVA: 0x000E455C File Offset: 0x000E275C private static bool ObjLoadInitDraw() { AppMain.OBS_LOAD_INITIAL_WORK obs_LOAD_INITIAL_WORK = AppMain.obj_load_initial_work; for (int i = 0; i < obs_LOAD_INITIAL_WORK.obj_num; i++) { uint?num = default(uint?); AppMain.ObjDrawAction3DNN(obs_LOAD_INITIAL_WORK.obj_3d[i], default(AppMain.VecFx32? ), default(AppMain.VecU16? ), default(AppMain.VecFx32? ), ref num); } for (int i = 0; i < obs_LOAD_INITIAL_WORK.es_num; i++) { uint?num2 = default(uint?); AppMain.ObjDrawAction3DES(obs_LOAD_INITIAL_WORK.obj_3des[i], default(AppMain.VecFx32? ), default(AppMain.VecU16? ), default(AppMain.VecFx32? ), ref num2); } return(true); }
// Token: 0x0600194F RID: 6479 RVA: 0x000E4D98 File Offset: 0x000E2F98 public static void ObjAction3dNNModelLoadTxb(AppMain.OBS_ACTION3D_NN_WORK obj_3d, AppMain.OBS_DATA_WORK data_work, string filename, int index, AMS_AMB_HEADER archive, string filename_tex, AMS_AMB_HEADER amb_tex, uint drawflag, AppMain.TXB_HEADER txb) { object obj = null; string filepath = null; obj_3d.command_state = 0U; obj_3d.marge = 0f; obj_3d.per = 1f; obj_3d.use_light_flag = AppMain.g_obj.def_user_light_flag; AppMain.nnMakeUnitMatrix(obj_3d.user_obj_mtx); AppMain.nnMakeUnitMatrix(obj_3d.user_obj_mtx_r); for (int i = 0; i < 2; i++) { obj_3d.speed[i] = 1f; } obj_3d.blend_spd = 0.25f; obj_3d.drawflag = drawflag; obj_3d.draw_state.Assign(AppMain.g_obj_draw_3dnn_draw_state); if (archive != null) { obj_3d.flag |= 65536U; } if (filename != null) { obj = AppMain.ObjDataLoad(data_work, filename, archive); if (archive != null && obj == null) { obj_3d.flag &= 4294901759U; obj = AppMain.ObjDataLoad(data_work, filename, null); } } else if (archive != null) { obj = AppMain.ObjDataLoadAmbIndex(data_work, index, archive); if (obj == null) { obj_3d.flag &= 4294901759U; } } else if (data_work != null) { obj = AppMain.ObjDataGetInc(data_work); } if (obj == null) { return; } obj_3d.model = obj; if (data_work != null) { obj_3d.model_data_work = data_work; } if (filename_tex != null && filename_tex != "") { AppMain.sFile = filename_tex; filepath = AppMain.sFile; } else { AppMain.sFile = ""; } obj_3d.reg_index = AppMain.amObjectLoad(out obj_3d._object, AppMain.amTxbGetTexFileList(txb), out obj_3d.texlist, out obj_3d.texlistbuf, obj, drawflag | AppMain.g_obj.load_drawflag, filepath, amb_tex); if (AppMain.obj_load_initial_set_flag) { AppMain.OBS_LOAD_INITIAL_WORK obs_LOAD_INITIAL_WORK = AppMain.obj_load_initial_work; if (obs_LOAD_INITIAL_WORK.obj_num < 255) { obs_LOAD_INITIAL_WORK.obj_3d[obs_LOAD_INITIAL_WORK.obj_num] = obj_3d; obs_LOAD_INITIAL_WORK.obj_num++; } } obj_3d.flag |= 2147483648U; obj_3d.flag &= 3221225471U; }
private static void ObjAction3dESTextureLoad( AppMain.OBS_ACTION3D_ES_WORK obj_3des, AppMain.OBS_DATA_WORK data_work, string filename, int index, AppMain.AMS_AMB_HEADER archive, bool load_tex) { AppMain.AMS_AMB_HEADER amsAmbHeader = (AppMain.AMS_AMB_HEADER)null; if (archive != null) { obj_3des.flag |= 131072U; } if (filename != null && filename != "") { amsAmbHeader = AppMain.readAMBFile((object)AppMain.ObjDataLoad(data_work, filename, (object)archive)); if (archive != null && amsAmbHeader == null) { obj_3des.flag &= 4294836223U; amsAmbHeader = AppMain.readAMBFile((object)AppMain.ObjDataLoad(data_work, filename, (object)null)); } } else if (archive != null) { amsAmbHeader = AppMain.readAMBFile(AppMain.ObjDataLoadAmbIndex(data_work, index, archive)); if (amsAmbHeader == null) { obj_3des.flag &= 4294836223U; } } else if (data_work != null) { amsAmbHeader = AppMain.readAMBFile(AppMain.ObjDataGetInc(data_work)); } if (amsAmbHeader == null) { return; } obj_3des.ambtex = (object)amsAmbHeader; if (data_work != null) { obj_3des.ambtex_data_work = data_work; } if (!load_tex) { return; } AppMain.TXB_HEADER txb = AppMain.readTXBfile(AppMain.amBindGet(amsAmbHeader, 0)); uint count = AppMain.amTxbGetCount(txb); obj_3des.texlistbuf = (object)null; AppMain.nnSetUpTexlist(out obj_3des.texlist, (int)count, ref obj_3des.texlistbuf); if (AppMain.obj_load_initial_set_flag) { AppMain.OBS_LOAD_INITIAL_WORK objLoadInitialWork = AppMain.obj_load_initial_work; if (objLoadInitialWork.es_num < (int)byte.MaxValue) { objLoadInitialWork.obj_3des[objLoadInitialWork.es_num] = obj_3des; ++objLoadInitialWork.es_num; } } obj_3des.tex_reg_index = AppMain.amTextureLoad(obj_3des.texlist, AppMain.amTxbGetTexFileList(txb), filename, amsAmbHeader); obj_3des.flag |= 1073741824U; }
private static void ObjAction3dNNModelLoad( AppMain.OBS_ACTION3D_NN_WORK obj_3d, AppMain.OBS_DATA_WORK data_work, string filename, int index, AppMain.AMS_AMB_HEADER archive, string filename_tex, AppMain.AMS_AMB_HEADER amb_tex, uint drawflag) { object buf = (object)null; string filepath = (string)null; obj_3d.command_state = 0U; obj_3d.marge = 0.0f; obj_3d.per = 1f; obj_3d.use_light_flag = AppMain.g_obj.def_user_light_flag; AppMain.nnMakeUnitMatrix(obj_3d.user_obj_mtx); AppMain.nnMakeUnitMatrix(obj_3d.user_obj_mtx_r); for (int index1 = 0; index1 < 2; ++index1) { obj_3d.speed[index1] = 1f; } obj_3d.mat_speed = 1f; obj_3d.blend_spd = 0.25f; obj_3d.drawflag = drawflag; obj_3d.draw_state.Assign(AppMain.g_obj_draw_3dnn_draw_state); if (archive != null) { obj_3d.flag |= 65536U; } if (filename != null && filename != "") { buf = (object)AppMain.ObjDataLoad(data_work, filename, (object)archive); if (archive != null && buf == null) { obj_3d.flag &= 4294901759U; buf = (object)AppMain.ObjDataLoad(data_work, filename, (object)null); } } else if (archive != null) { buf = AppMain.ObjDataLoadAmbIndex(data_work, index, archive); if (buf == null) { obj_3d.flag &= 4294901759U; } } else if (data_work != null) { buf = AppMain.ObjDataGetInc(data_work); } if (buf == null) { return; } obj_3d.model = buf; if (data_work != null) { obj_3d.model_data_work = data_work; } if (filename_tex != null && filename_tex != "") { AppMain.sFile = filename_tex; filepath = AppMain.sFile; } else { AppMain.sFile = ""; } obj_3d.reg_index = AppMain.amObjectLoad(out obj_3d._object, out obj_3d.texlist, out obj_3d.texlistbuf, buf, drawflag | AppMain.g_obj.load_drawflag, filepath, amb_tex); if (AppMain.obj_load_initial_set_flag) { AppMain.OBS_LOAD_INITIAL_WORK objLoadInitialWork = AppMain.obj_load_initial_work; if (objLoadInitialWork.obj_num < (int)byte.MaxValue) { objLoadInitialWork.obj_3d[objLoadInitialWork.obj_num] = obj_3d; ++objLoadInitialWork.obj_num; } } obj_3d.flag |= 2147483648U; obj_3d.flag &= 3221225471U; }