diff options
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/blenkernel/BKE_material.h | 4 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/material.c | 7 | ||||
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_logic/logic_ops.c | 32 |
4 files changed, 8 insertions, 37 deletions
diff --git a/source/blender/blenkernel/BKE_material.h b/source/blender/blenkernel/BKE_material.h index 91c1715cca6..e2d49aa51ff 100644 --- a/source/blender/blenkernel/BKE_material.h +++ b/source/blender/blenkernel/BKE_material.h @@ -111,8 +111,8 @@ void free_matcopybuf(void); void copy_matcopybuf(struct Material *ma); void paste_matcopybuf(struct Material *ma); -/* handle backward compatibility for tface/materials called from doversion (fileload=1) or Help Menu (fileload=0) */ -int do_version_tface(struct Main *main, int fileload); +/* handle backward compatibility for tface/materials called from doversion */ +int do_version_tface(struct Main *main); #ifdef __cplusplus } diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c index f3dc64a7279..a38fce9da6c 100644 --- a/source/blender/blenkernel/intern/material.c +++ b/source/blender/blenkernel/intern/material.c @@ -1919,7 +1919,7 @@ static void convert_tfacematerial(Main *main, Material *ma) #define MAT_BGE_DISPUTED -99999 -int do_version_tface(Main *main, int fileload) +int do_version_tface(Main *main) { Mesh *me; Material *ma; @@ -1929,6 +1929,9 @@ int do_version_tface(Main *main, int fileload) int a; int flag; int index; + + /* Operator in help menu has been removed for 2.7x */ + int fileload = 1; /* sometimes mesh has no materials but will need a new one. In those * cases we need to ignore the mf->mat_nr and only look at the face @@ -2072,7 +2075,7 @@ int do_version_tface(Main *main, int fileload) if (ma->game.flag == MAT_BGE_DISPUTED) { ma->game.flag = 0; if (fileload) { - printf("Warning: material \"%s\" skipped - to convert old game texface to material go to the Help menu.\n", ma->id.name + 2); + printf("Warning: material \"%s\" skipped.\n", ma->id.name + 2); nowarning = 0; } else { diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index 6e64dcc0560..e5304c7e9d8 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -7349,7 +7349,7 @@ static void convert_tface_mt(FileData *fd, Main *main) gmain = G.main; G.main = main; - if (!(do_version_tface(main, 1))) { + if (!(do_version_tface(main))) { BKE_report(fd->reports, RPT_WARNING, "Texface conversion problem (see error in console)"); } diff --git a/source/blender/editors/space_logic/logic_ops.c b/source/blender/editors/space_logic/logic_ops.c index fac564f33fb..dbbe87c3f1e 100644 --- a/source/blender/editors/space_logic/logic_ops.c +++ b/source/blender/editors/space_logic/logic_ops.c @@ -706,37 +706,6 @@ static void LOGIC_OT_actuator_move(wmOperatorType *ot) RNA_def_enum(ot->srna, "direction", logicbricks_move_direction, 1, "Direction", "Move Up or Down"); } -/* ************* TexFace Converter Operator ************* */ -static int texface_convert_exec(bContext *C, wmOperator *UNUSED(op)) -{ - Main *bmain = CTX_data_main(C); - do_version_tface(bmain, 0); - - return OPERATOR_FINISHED; -} - -static int texface_convert_invoke(bContext *C, wmOperator *op, const wmEvent *UNUSED(event)) -{ - return texface_convert_exec(C, op); -} - -static void LOGIC_OT_texface_convert(wmOperatorType *ot) -{ - /* identifiers */ - ot->name = "TexFace to Material Converter"; - ot->description = "Convert old texface settings into material. It may create new materials if needed"; - ot->idname = "LOGIC_OT_texface_convert"; - - /* api callbacks */ - ot->invoke = texface_convert_invoke; - ot->exec = texface_convert_exec; -// ot->poll = texface_convert_poll; - - /* flags */ - ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; -} - - /* ************************ view ********************* */ static int logic_view_all_exec(bContext *C, wmOperator *op) @@ -782,6 +751,5 @@ void ED_operatortypes_logic(void) WM_operatortype_append(LOGIC_OT_actuator_remove); WM_operatortype_append(LOGIC_OT_actuator_add); WM_operatortype_append(LOGIC_OT_actuator_move); - WM_operatortype_append(LOGIC_OT_texface_convert); WM_operatortype_append(LOGIC_OT_view_all); } |