Removing Blender Game Engine from Blender 2.8
Folders removed entirely: * //extern/recastnavigation * //intern/decklink * //intern/moto * //source/blender/editors/space_logic * //source/blenderplayer * //source/gameengine This includes DNA data and any reference to the BGE code in Blender itself. We are bumping the subversion. Pending tasks: * Tile/clamp code in image editor draw code. * Viewport drawing code (so much of this will go away because of BI removal that we can wait until then to remove this.
This commit is contained in:
@@ -1492,54 +1492,6 @@ class WM_OT_copy_prev_settings(Operator):
|
||||
return {'CANCELLED'}
|
||||
|
||||
|
||||
class WM_OT_blenderplayer_start(Operator):
|
||||
"""Launch the blender-player with the current blend-file"""
|
||||
bl_idname = "wm.blenderplayer_start"
|
||||
bl_label = "Start Game In Player"
|
||||
|
||||
def execute(self, context):
|
||||
import os
|
||||
import sys
|
||||
import subprocess
|
||||
|
||||
gs = context.scene.game_settings
|
||||
|
||||
# these remain the same every execution
|
||||
blender_bin_path = bpy.app.binary_path
|
||||
blender_bin_dir = os.path.dirname(blender_bin_path)
|
||||
ext = os.path.splitext(blender_bin_path)[-1]
|
||||
player_path = os.path.join(blender_bin_dir, "blenderplayer" + ext)
|
||||
# done static vars
|
||||
|
||||
if sys.platform == "darwin":
|
||||
player_path = os.path.join(blender_bin_dir, "../../../blenderplayer.app/Contents/MacOS/blenderplayer")
|
||||
|
||||
if not os.path.exists(player_path):
|
||||
self.report({'ERROR'}, "Player path: %r not found" % player_path)
|
||||
return {'CANCELLED'}
|
||||
|
||||
filepath = bpy.data.filepath + '~' if bpy.data.is_saved else os.path.join(bpy.app.tempdir, "game.blend")
|
||||
bpy.ops.wm.save_as_mainfile('EXEC_DEFAULT', filepath=filepath, copy=True)
|
||||
|
||||
# start the command line call with the player path
|
||||
args = [player_path]
|
||||
|
||||
# handle some UI options as command line arguments
|
||||
args.extend([
|
||||
"-g", "show_framerate", "=", "%d" % gs.show_framerate_profile,
|
||||
"-g", "show_profile", "=", "%d" % gs.show_framerate_profile,
|
||||
"-g", "show_properties", "=", "%d" % gs.show_debug_properties,
|
||||
"-g", "ignore_deprecation_warnings", "=", "%d" % (not gs.use_deprecation_warnings),
|
||||
])
|
||||
|
||||
# finish the call with the path to the blend file
|
||||
args.append(filepath)
|
||||
|
||||
subprocess.call(args)
|
||||
os.remove(filepath)
|
||||
return {'FINISHED'}
|
||||
|
||||
|
||||
class WM_OT_keyconfig_test(Operator):
|
||||
"""Test key-config for conflicts"""
|
||||
bl_idname = "wm.keyconfig_test"
|
||||
@@ -2375,7 +2327,6 @@ classes = (
|
||||
WM_OT_app_template_install,
|
||||
WM_OT_appconfig_activate,
|
||||
WM_OT_appconfig_default,
|
||||
WM_OT_blenderplayer_start,
|
||||
WM_OT_context_collection_boolean_set,
|
||||
WM_OT_context_cycle_array,
|
||||
WM_OT_context_cycle_enum,
|
||||
|
||||
Reference in New Issue
Block a user