text
stringlengths
1
93.6k
heart_beat_task = HeartBeatTask(asyncio.get_event_loop(), SystemConstant.HEART_BEAT_INTERVAL)
Thread(target=heart_beat_task.run).start()
check_cookie_task = CheckCookieTask()
tornado.ioloop.PeriodicCallback(check_cookie_task.run, 3600 * 1000).start()
# clear_nonce_stak = ClearNonceTask()
# tornado.ioloop.PeriodicCallback(clear_nonce_stak.run, 1800 * 1000).start()
tornado.ioloop.IOLoop.current().start()
if __name__ == '__main__':
main()
# <FILESEP>
import bpy
from . import advanced_ik, armature_creation, constraint_symmetry, utils
class SAT_properties(bpy.types.PropertyGroup): #Defines global properties the plugin will use
#Thanks to Jeacom for this
def armature_poll(self, object):
#Generated armatures should not be part of the list
if object.name.endswith('.weight') or object.name.endswith('.anim') or object.name.endswith('.anim_setup'):
pass
else:
return object.type == 'ARMATURE'
#Retuns only meshes
def object_poll(self, object):
return object.type == 'MESH'
target_armature : bpy.props.PointerProperty(
type=bpy.types.Object,
name='Armature',
description="Armature that will be used to perform operations on",
poll=armature_poll,
update=utils.create_armature
)
target_object : bpy.props.PointerProperty(
type=bpy.types.Object,
name='Object',
description="Object linked to the armature that will be used for shapekeys",
poll=object_poll
)
affected_side : bpy.props.EnumProperty(
name="Affected side",
description="Side that will be used for applying symmetry constraints",
items=[
('LTR', "Left Side", "Left to Right"),
('RTL', "Right Side", "Right to Left")
]
)
symmetry_offset : bpy.props.BoolProperty(
name="Symmetry Offset",
description="If disabled, the location of bones will be the opposite of the location of its pair, else its initial locationn ill be unchanged",
default=False,
update=constraint_symmetry.update_constraint
)
symmetry_upperarm_rotation_fix : bpy.props.BoolProperty(
name="Opposite Arm Rotation Fix",
description="If the opposite arm rotates in the wrong direction, enable this",
default=False,
update=constraint_symmetry.update_constraint
)
retarget_constraints : bpy.props.BoolProperty(
name="Retarget Constraints",
description="Used to preview the animation for the armature after baking",
default=True,
update=advanced_ik.retarget_constraints
)
bake_helper_bones : bpy.props.BoolProperty(
name="Bake Helper Bones",
description="Only required for viewmodels",
default=False,
)
#Armature creation selection
game_armature_type : bpy.props.EnumProperty(
name="Type",
description="Armature type",
items=[
('PM', "Playermodel", "World armature"),
('VM', "Viewmodel", "View armature")
],
update=utils.update_armature
)
game_armature : bpy.props.EnumProperty(
name="Game Armature",
description="Create armature from the selected game",
items=[
('HL2', "Half Life 2/Garry's Mod", "Citizen armature"),