X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=blender_export.py;h=52f674f73ba4042a0b308ce01822e23daeb42bb5;hb=c2b59441df0383807ba093295af2e4400e552f39;hp=8d202983d765851a3f14164de6ddefe3bd6656ab;hpb=188685bc8454ff40b733d9e9df8da45e3c2e2c39;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/blender_export.py b/blender_export.py index 8d20298..52f674f 100644 --- a/blender_export.py +++ b/blender_export.py @@ -476,7 +476,8 @@ class ent_challenge(Structure):#{ #} class ent_unlock(Structure):#{ - _fields_ = [("pstr_alias",c_uint32), + _fields_ = [("transform",mdl_transform), + ("pstr_alias",c_uint32), ("target",c_uint32), ("target_event",c_uint32), ("status",c_uint32)] @@ -794,6 +795,7 @@ def sr_compile_material( mat ):#{ #} if mat.SR_data.shader == 'invisible': flags |= 0x10 if mat.SR_data.shader == 'boundary': flags |= (0x10|0x20) + if mat.SR_data.shader == 'walking': flags |= (0x10|0x80) #} m.flags = flags @@ -856,6 +858,10 @@ def sr_compile_material( mat ):#{ m.colour[2] = pow( mat.SR_data.tint[2], 1.0/2.2 ) m.colour[3] = pow( mat.SR_data.tint[3], 1.0/2.2 ) #} + + if mat.SR_data.shader == 'walking':#{ + m.shader = 9 + #} if mat.SR_data.shader in ['standard', 'standard_cutout', 'terrain_blend', \ 'vertex_blend', 'fxglow', 'cubemap' ]: #{ @@ -1869,6 +1875,7 @@ def sr_compile( collection ): elif ent_type == 'ent_unlock':#{ unlock = ent_unlock() obj_data = obj.SR_data.ent_unlock[0] + compile_obj_transform( obj, unlock.transform ) unlock.pstr_alias = sr_compile_string( obj_data.alias ) unlock.target = sr_entity_id( obj_data.target ) unlock.target_event = obj_data.target_event @@ -2419,7 +2426,8 @@ class SR_MATERIAL_PANEL(bpy.types.Panel): row = box.row() if (active_mat.SR_data.shader != 'invisible') and \ - (active_mat.SR_data.shader != 'boundary'):#{ + (active_mat.SR_data.shader != 'boundary') and \ + (active_mat.SR_data.shader != 'walking'):#{ row.prop( active_mat.SR_data, "skate_surface" ) row.prop( active_mat.SR_data, "grind_surface" ) row.prop( active_mat.SR_data, "grow_grass" ) @@ -3360,7 +3368,8 @@ class SR_MATERIAL_PROPERTIES(bpy.types.PropertyGroup): ('invisible','Invisible',''), ('boundary','Boundary',''), ('fxglow','FX Glow',''), - ('cubemap','Cubemap','') + ('cubemap','Cubemap',''), + ('walking','Walking','') ]) surface_prop: bpy.props.EnumProperty(