diff --git a/bake.py b/bake.py index bbfa2dc..81fca8f 100644 --- a/bake.py +++ b/bake.py @@ -1438,20 +1438,20 @@ def bake_thug_lightmaps(meshes, context): scene.render.bake_margin = 2 # Used to be bake_margin if ob.thug_lightmap_quality != 'Custom': if ob.thug_lightmap_quality == 'Draft': - scene.cycles.samples = 16 + scene.cycles.samples = 32 scene.cycles.max_bounces = 2 if ob.thug_lightmap_quality == 'Preview': - scene.cycles.samples = 32 - scene.cycles.max_bounces = 4 + scene.cycles.samples = 64 + scene.cycles.max_bounces = 2 if ob.thug_lightmap_quality == 'Good': - scene.cycles.samples = 108 - scene.cycles.max_bounces = 5 + scene.cycles.samples = 128 + scene.cycles.max_bounces = 3 if ob.thug_lightmap_quality == 'High': - scene.cycles.samples = 225 - scene.cycles.max_bounces = 6 + scene.cycles.samples = 256 + scene.cycles.max_bounces = 3 if ob.thug_lightmap_quality == 'Ultra': - scene.cycles.samples = 450 - scene.cycles.max_bounces = 8 + scene.cycles.samples = 512 + scene.cycles.max_bounces = 3 print("Using {} bake quality. Samples: {}, bounces: {}".format(ob.thug_lightmap_quality, scene.cycles.samples, scene.cycles.max_bounces)) if scene.thug_bake_type == 'SHADOW': bpy.ops.object.bake(type='SHADOW') @@ -2827,6 +2827,8 @@ def draw(self, context): box.row().prop(ob, "thug_lightmap_resolution") box.row().prop(ob, "thug_lightmap_quality") box.row().prop(ob, "thug_lightmap_type", expand=True) + else: + box.row().prop(ob, "thug_lightmap_quality") tmp_row = box.row().split() tmp_row.column().operator(BakeLightmaps.bl_idname, text=BakeLightmaps.bl_label, icon='LIGHTPAINT') diff --git a/level_manifest.py b/level_manifest.py index 51934e7..ca0b562 100644 --- a/level_manifest.py +++ b/level_manifest.py @@ -57,6 +57,7 @@ def export_level_manifest_json(filename, directory, operator, level_info): outp.write("\t\"FLAG_DISABLE_GOALEDITOR\": {},\n".format(("true" if level_info.level_flag_nogoaleditor else "false"))) outp.write("\t\"FLAG_DISABLE_GOALATTACK\": {},\n".format(("true" if level_info.level_flag_nogoalattack else "false"))) outp.write("\t\"FLAG_NO_PRX\": {},\n".format(("true" if level_info.level_flag_noprx else "false"))) + outp.write("\t\"FLAG_IS_BIG_LEVEL\": {},\n".format(("true" if level_info.level_flag_biglevel else "false"))) outp.write("}\n") @@ -180,6 +181,7 @@ def draw(self, context): self.layout.row().label(text="Level Flags", icon='INFO') box = self.layout.box().column(True) box.row().prop(scene.thug_level_props, "level_flag_offline") + box.row().prop(scene.thug_level_props, "level_flag_biglevel") box.row().prop(scene.thug_level_props, "level_flag_noprx") box.row().prop(scene.thug_level_props, "level_flag_indoor") box.row().prop(scene.thug_level_props, "level_flag_nosun") diff --git a/scene_props.py b/scene_props.py index cf196fa..3b18107 100644 --- a/scene_props.py +++ b/scene_props.py @@ -1053,10 +1053,10 @@ class THUGTODProps(bpy.types.PropertyGroup): #- Properties for the entire level #---------------------------------------------------------------------------------- class THUGLevelProps(bpy.types.PropertyGroup): - level_name = StringProperty(name="Level Name", description="Name of your level, used for in-game menus.") - scene_name = StringProperty(name="Scene Name", description="Short name referenced by scripts.") - creator_name = StringProperty(name="Creator Name", description="Name of the person(s) who created this level.") - level_skybox = StringProperty(name="Skybox Name", description="Name of the skybox to be used with this level.") + level_name = StringProperty(name="Level Name", description="Name of your level, used for in-game menus") + scene_name = StringProperty(name="Scene Name", description="Short name referenced by scripts") + creator_name = StringProperty(name="Creator Name", description="Name of the person(s) who created this level") + level_skybox = StringProperty(name="Skybox Name", description="Name of the skybox to be used with this level") export_props = PointerProperty(type=THUGLevelExportProps) @@ -1081,32 +1081,33 @@ class THUGLevelProps(bpy.types.PropertyGroup): default=(0.5, 0.5, 0.5, 0.25), size=4, min=0.0, max=1.0, - description="Light color, with alpha used as the mod value.") + description="Light color, with alpha used as the mod value") level_light0_rgba = FloatVectorProperty(name="Light #1: Color/Mod", subtype='COLOR', default=(0.5, 0.5, 0.5, 0.25), size=4, min=0.0, max=1.0, - description="Light color, with alpha used as the mod value.") + description="Light color, with alpha used as the mod value") level_light0_headpitch = FloatVectorProperty(name="Heading/Pitch", size=2, soft_min=0, soft_max=360, default=(0, 0)) level_light1_rgba = FloatVectorProperty(name="Light #2: Color/Mod", subtype='COLOR', default=(0.5, 0.5, 0.5, 0.25), size=4, min=0.0, max=1.0, - description="Light color, with alpha used as the mod value.") + description="Light color, with alpha used as the mod value") level_light1_headpitch = FloatVectorProperty(name="Heading/Pitch", size=2, soft_min=0, soft_max=360, default=(0, 0)) - level_flag_offline = BoolProperty(name="Offline Only", description="This level is not enabled for online play.", default=False) - level_flag_indoor = BoolProperty(name="Indoor", description="(THUG PRO only) This level is indoor.", default=False) - level_flag_nosun = BoolProperty(name="No Sun", description="(THUG PRO only) Don't display the dynamic sun in this level.", default=False) - level_flag_defaultsky = BoolProperty(name="Default Sky", description="(THUG PRO only) Use the default skybox.", default=False) - level_flag_wallridehack = BoolProperty(name="Wallride Hack", description="(THUG PRO only) Automatically makes all walls wallridable.", default=False) + level_flag_offline = BoolProperty(name="Offline Only", description="This level is not enabled for online play", default=False) + level_flag_indoor = BoolProperty(name="Indoor", description="(THUG PRO only) This level is indoor", default=False) + level_flag_nosun = BoolProperty(name="No Sun", description="(THUG PRO only) Don't display the dynamic sun in this level", default=False) + level_flag_defaultsky = BoolProperty(name="Default Sky", description="(THUG PRO only) Use the default skybox", default=False) + level_flag_wallridehack = BoolProperty(name="Wallride Hack", description="(THUG PRO only) Automatically makes all walls wallridable", default=False) level_flag_nobackfacehack = BoolProperty(name="No Backface Hack", description="(THUG PRO only)", default=False) level_flag_modelsinprx = BoolProperty(name="Models in scripts .prx", description="(THUG PRO only)", default=False) level_flag_nogoaleditor = BoolProperty(name="Disable goal editor", description="(THUG PRO only)", default=False) level_flag_nogoalattack = BoolProperty(name="Disable goal attack", description="(THUG PRO only)", default=False) level_flag_noprx = BoolProperty(name="Don't use prx files", description="(THUG PRO only) This level uses uncompressed files, not packed in .prx files", default=False) + level_flag_biglevel = BoolProperty(name="Big Level", description="(THUG PRO only) Use extended online position broadcast limits", default=False) # METHODS ############################################# diff --git a/utils.py b/utils.py index dc68ef9..0cbe973 100644 --- a/utils.py +++ b/utils.py @@ -348,16 +348,6 @@ def draw(self, context): col.row().prop(self, "thug_lightgroup") col.row().prop(self, "thug_is_trickobject") col.row().prop(self, "thug_cluster_name") - col.row().prop(self, "triggerscript_type") - col.row().prop_search( - self, - "target_node", - context.window_manager, - "thug_all_restarts") - col.row().prop_search( - self, "custom_name", - bpy.data, - "texts") #---------------------------------------------------------------------------------- class THUGUtilBatchImport(bpy.types.Operator):