{"id":4062,"date":"2020-03-04T22:01:11","date_gmt":"2020-03-05T06:01:11","guid":{"rendered":"https:\/\/trikingo.com\/?post_type=product&#038;p=4062"},"modified":"2020-03-04T22:15:23","modified_gmt":"2020-03-05T06:15:23","slug":"mario-maker-for-maya","status":"publish","type":"product","link":"https:\/\/trikingo.com\/product\/mario-maker-for-maya\/","title":{"rendered":"Mario Maker for Maya"},"content":{"rendered":"<p>This is a demonstration of how Python can be used along Pyside to create very dynamic applications in Maya.<\/p>\n<p>Disclaimer: We don\u2019t own any Nintendo characters, and the purpose of this script is purely experimental and educational.<\/p>\n<p>It is by no means a perfect videogame engine as you will notice by the imperfect collisions, and there are some libraries that can be used such as pygame if you want to properly develop a game. However, this example does not use any external library and relies completely on standard python and math for collisions.<\/p>\n<p>The static sprites are QLabels, while the animated ones are a collection of QWidgets and QLabels, switching to give the appearance of animation.<\/p>\n<p>The current example contains only a few objects to play with, with no event happening if Mario drops down the edge. You will need to close the window and restart it.<\/p>\n<p><img loading=\"lazy\" class=\"size-medium wp-image-1035 aligncenter\" src=\"https:\/\/i1.wp.com\/cgdailies.com\/cgd\/wp-content\/uploads\/2019\/06\/mario1.png?resize=300%2C278&amp;ssl=1\" sizes=\"(max-width: 300px) 100vw, 300px\" srcset=\"https:\/\/i1.wp.com\/cgdailies.com\/cgd\/wp-content\/uploads\/2019\/06\/mario1.png?resize=300%2C278&amp;ssl=1 300w, https:\/\/i1.wp.com\/cgdailies.com\/cgd\/wp-content\/uploads\/2019\/06\/mario1.png?w=547&amp;ssl=1 547w\" alt=\"\" width=\"300\" height=\"278\" \/><\/p>\n<p>USAGE (Python build is for Maya 2017 and 2018 only):<\/p>\n<p>Unzip the contents into your maya\/scripts\/ folder. Then in a Maya script editor\u2019s python tab, type this:<\/p>\n<p>import MarioTribute<br \/>\nMarioTribute.run()<\/p>\n<p>This will open the window with the Mario game. Pressing the left key and right key moves Mario around (If Mario if invisible when you first run the game, just press the keys and Mario will appear).\u00a0 To jump around, use the Left Mouse Click.<br \/>\nClick on the left buttons on the sidebar to create new objects. These object will interact with Mario instantly!<\/p>\n<p>IMPORTANT!<\/p>\n<p>Use an exclusive Maya session for this example. Do not run in your current scene or project, or save before you open. If left running for a very long time, it will exhaust the QTimer and Maya can crash!<\/p>\n<p>Have fun\u00a0<img class=\"emoji\" role=\"img\" draggable=\"false\" src=\"https:\/\/s.w.org\/images\/core\/emoji\/12.0.0-1\/svg\/1f642.svg\" alt=\"\ud83d\ude42\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>This is a demonstration of how Python can be used along Pyside to create very dynamic applications in Maya.<\/p>\n<p>Disclaimer: We don\u2019t own any Nintendo characters, and the purpose of this script is purely experimental and educational.<\/p>\n","protected":false},"featured_media":4075,"template":"","meta":{"spay_email":""},"_links":{"self":[{"href":"https:\/\/trikingo.com\/api\/wp\/v2\/product\/4062"}],"collection":[{"href":"https:\/\/trikingo.com\/api\/wp\/v2\/product"}],"about":[{"href":"https:\/\/trikingo.com\/api\/wp\/v2\/types\/product"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/trikingo.com\/api\/wp\/v2\/media\/4075"}],"wp:attachment":[{"href":"https:\/\/trikingo.com\/api\/wp\/v2\/media?parent=4062"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}