|-- addons
| |-- auto_lod
| | |-- art
| | |-- core
| | |-- binaries
| |-- spring_arm
|-- generic_shooter
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from PySide2 import QtWidgets, QtCore | |
| def _maya_main_window(): | |
| """Return Maya's main window""" | |
| for obj in QtWidgets.qApp.topLevelWidgets(): | |
| if obj.objectName() == 'MayaWindow': | |
| return obj | |
| raise RuntimeError('Could not find MayaWindow instance') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from PyQt4 import QtGui, QtCore, uic | |
| def p(x): | |
| print x | |
| class MainWindow(QtGui.QMainWindow): | |
| def __init__(self): | |
| QtGui.QWidget.__init__(self) | |
| uic.loadUi('redirect.ui', self) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*Complex Selector Example*/ | |
| QLineEdit { color: red } | |
| QLineEdit[readOnly="true"] { color: gray } | |
| QDialog QLineEdit { color: brown } | |
| /*Customizing QAbstractScrollArea*/ | |
| QTextEdit, QListView { | |
| background-color: white; | |
| background-image: url(draft.png); | |
| background-attachment: scroll; /*If the background-image is to be fixed with the viewport: scroll or fixed*/ | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python | |
| # coding: utf-8 | |
| class AttrDict(object): | |
| def __init__(self, init=None): | |
| if init is not None: | |
| self.__dict__.update(init) | |
| def __getitem__(self, key): | |
| return self.__dict__[key] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| local beginX | |
| local beginY | |
| local endX | |
| local endY | |
| local startTime | |
| local xDistance | |
| local yDistance |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## | |
| # Automatic versioning the code using GIT | |
| # need GIT instaled on OS | |
| func _dev_auto_commit(): | |
| if OS.is_debug_build(): | |
| var path = '/usr/bin/git' | |
| var finder = File.new() | |
| if not finder.file_exists(path): | |
| if finder.file_exists('/usr/sbin/git'): | |
| path = '/usr/sbin/git' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #Draw trails with lines | |
| #A NON-PERFECT SCRIPT FOR Godot v2.1.* *NOTE THIS SCRIPT STILL HAVE SOME REF ISSUES, CHECK FOR ERRORS IN THE DEBUGGER | |
| #This script has to be attached to scene with only a Control Node | |
| #This scene can be instanced as child of a moving node | |
| #after that the code can be initialized calling scia_setup() func: | |
| #arguments ( nuovo_oggetto = "the parent node reference goes here" | |
| num_step = "number of steps (50 by default) | |
| nuovo_colore = Color() (Opaque white by default) | |
| nuova_trasp = Initial alpha transparency (adjust the formula for other fading effects) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from maya import cmds, OpenMayaUi as omui | |
| from Qt import QtWidgets, QtCore, QtCompat | |
| def Dock(Widget, width=300, show=True): | |
| """Dock `Widget` into Maya | |
| Arguments: | |
| Widget (QWidget): Class | |
| show (bool, optional): Whether to show the resulting dock once created |
OlderNewer