BGE Material settings renaming Back Culling to Backface Culling and make it on by...
authorDalai Felinto <dfelinto@gmail.com>
Mon, 26 Sep 2011 06:39:19 +0000 (06:39 +0000)
committerDalai Felinto <dfelinto@gmail.com>
Mon, 26 Sep 2011 06:39:19 +0000 (06:39 +0000)
under suggestion of Mitchell Stokes (Moguri)

doc/python_api/rst/change_log.rst
release/scripts/startup/bl_ui/properties_material.py
source/blender/blenkernel/intern/material.c
source/blender/makesrna/intern/rna_material.c

index 8ed161a..b9c154b 100644 (file)
@@ -1396,7 +1396,7 @@ Moved
 * **hide** -> :class:`bpy.types.Material.game_settings.invisible`
 * **use_collision** -> :class:`bpy.types.Material.game_settings.physics`
 * **use_light** -> :class:`bpy.types.Material.game_settings.use_shadeless`
-* **use_twoside** -> :class:`bpy.types.Material.game_settings.back_culling`
+* **use_twoside** -> :class:`bpy.types.Material.game_settings.backface_culling`
 * **use_bitmap_text** -> :class:`bpy.types.Material.game_settings.text`
 * **blend_type** -> :class:`bpy.types.Material.game_settings.alpha_blend`
 * **use_alpha_sort** -> :class:`bpy.types.Material.game_settings.alpha_blend`
index 1c9ff6d..de527f9 100644 (file)
@@ -625,7 +625,7 @@ class MATERIAL_PT_game_settings(MaterialButtonsPanel, bpy.types.Panel):
         game = context.material.game_settings  # dont use node material
 
         row = layout.row()
-        row.prop(game, "back_culling")
+        row.prop(game, "backface_culling")
         row.prop(game, "invisible")
         row.prop(game, "text")
 
index f27046f..a25da56 100644 (file)
@@ -193,7 +193,7 @@ void init_material(Material *ma)
        ma->vol.ms_diff = 1.f;
        ma->vol.ms_intensity = 1.f;
        
-       ma->game.flag=0;
+       ma->game.flag = GEMAT_BACKCULL;
        ma->game.alpha_blend=0;
        ma->game.face_orientation=0;
        
index 6ed2147..54631da 100644 (file)
@@ -767,9 +767,9 @@ static void rna_def_material_gamesettings(BlenderRNA *brna)
        RNA_def_struct_nested(brna, srna, "Material");
        RNA_def_struct_ui_text(srna, "Material Game Settings", "Game Engine settings for a Material datablock");
        
-       prop= RNA_def_property(srna, "back_culling", PROP_BOOLEAN, PROP_NONE);
+       prop= RNA_def_property(srna, "backface_culling", PROP_BOOLEAN, PROP_NONE);
        RNA_def_property_boolean_sdna(prop, NULL, "flag", GEMAT_BACKCULL); /* use bitflags */
-       RNA_def_property_ui_text(prop, "Back Culling", "Hide Back of the face in Game Engine ");
+       RNA_def_property_ui_text(prop, "Backface Culling", "Hide Back of the face in Game Engine ");
        RNA_def_property_update(prop, 0, "rna_Material_draw_update");
 
        prop= RNA_def_property(srna, "text", PROP_BOOLEAN, PROP_NONE);