Home Technical Talk

Script shortcut to button in Max

polycounter lvl 10
Offline / Send Message
Dakkon polycounter lvl 10
Hey guys. I was wondering how I could go about making a button that activates a script that I can place on my toolbar in Max? I did this awhile ago, but I've totally forgotten what I did.

Replies

  • JohnnyRaptor
    Offline / Send Message
    JohnnyRaptor polycounter lvl 15
    select your code in the code window and drag it to a bar


    edit, DAMN, ninja'd!
  • Dakkon
    Offline / Send Message
    Dakkon polycounter lvl 10
    Well, I'm trying to run a pre-existing script. It's the Polyboost program, and I'm trying to make a button to get it to launch over having to run the script every time. If I make a text button with Polyboost.mse in it, it gets a lot of error. I have little to no experience with this as I'm sure you can tell :).
  • Rob Galanakis
    You'll want to do something like:
    macroScript RunThisFile
    category:"MyScripts"
    (
    fileIn "C:\Program Files\Autodesk\Max 2008\Scripts\Polyboost\someFile.ms"
    )
    
    Replace the filename with whatever the path is of the script you are trying to run, make sure to use \\ instead of \.

    There are better ways to do this but this is simple and better than, say, opening the .ms file in question, selecting it all, and dragging it onto your toolbar.
  • Dakkon
    Offline / Send Message
    Dakkon polycounter lvl 10
    I figured out a different way of doing it since with making a new toolbar, and adding a shortcut in the customize menu. For some reason it wouldn't open properly since it was an mse file, and not an ms file.
  • butt_sahib
    Offline / Send Message
    butt_sahib polycounter lvl 11
    Custom UI to the rescue!
    imo, this is the best way to go about.
    2940,screenENCQZ.jpg
    Made this screenshot for a friend i made the UI for,so please ignore the tone of the "pitch"
  • Mark Dygert
    butt_sahib wrote: »
    Custom UI to the rescue!
    imo, this is the best way to go about.
    2940,screenENCQZ.jpg
    Made this screenshot for a friend i made the UI for,so please ignore the tone of the "pitch"

    Or CTRL-X... AKA Expert mode since its nearly identical, and gives you a quick way to cancel on the fly.

    And seriously how does anyone get anything done without the command panel. I have mine extended twice just to cut down on the constant scrolling.
  • Jeremy Wright
    Offline / Send Message
    Jeremy Wright polycounter lvl 17
    Dual monitors with command panel fully extended on the second monitor is working wonders for me.
  • Mark Dygert
    I end up using the second monitor for Motion Mixer, Layer Manager and a few custom UI scripts like Worker of Biped along with PhotoShop.
  • butt_sahib
    Offline / Send Message
    butt_sahib polycounter lvl 11
    oh hot digity....command panel completely extended is pure win.seriouslly.
    I do understand what you guys mean about the command panel.Not having it there is like having a chick without any tits.bare...and lonely.
    but i have a tiny monitor (around 15") so i need all the workspace i can get. The constant scrolling REALLY pissed me off to no end, so i had to put some stuff i use in the quad-menu. But yeah,when i said "no need for command panel at all"- i guess i mostly meant for minute operations (im trying to complete a whole project without the command panel,ofcourse, learning hotkeys helps out alot). but the good thing is...that theres a "show command panel" in the quad, you could change it in a go rather than using the menu bars :)
    mmmm.layer manager on a second monitor...sweeeet. Vig, LOVE the idea of having PS on the other monitor.you guys make me jealous :P

    EDIT:
    yeah what i use is definitely an extension of teh expert mode, but with the main toolbar,trackbar and timebar removed. they really pissed me off in expert mode :/
  • JohnnyRaptor
    Offline / Send Message
    JohnnyRaptor polycounter lvl 15
    i never use the command panel....what u guys use it for?



    EDIT: nm, a glitch in my brain caused a missunderstanding
  • Michael Knubben
    Vig: same here, doubled its size to make it actually workable.
    I wish I could reclaim that space though, since I have an absolutely tiny monitor at home. Well, in terms of screensize. It being a crt, you can never really call it tiny, can you?
  • Mark Dygert
    Outside of widescreen it is definitely more claustrophobic. When you make the switch to widescreen its going to be great. You'll have a lot more horizontal space, enough to keep the control panel extended and not have to deal with a tiny viewport.

    Here's a shot of the screen real estate I have set up at work. Left is 1680x1050 LCD, Right is 1152x864 CRT (the gap at the bottom is actually dead space. At home I have the same set up but 1680x1050 on both. A lot less crowded. After the first of the year we'll all have dual 1680x1050 at work.
    WorkSpace_thumb.jpg
    Photoshop sits behind all of the stuff on the right and over takes it when I'm using it. I also float the UV editor window over there.
  • Michael Knubben
    Vig: 15" crt. Feel my pain!
    I have a 19" crt somewhere in storage, but it's hard to carry it from room to room, so it was too much of a challenge to get it here, given that we moved everything (including pc) by travellers backpack.
    Don't worry though, I'll be getting a widescreen lcd eventually
  • Mark Dygert
    Ouch yea 15 CRT I hear that, I have 3 sitting in my garage. Those fuckers are HEAVY in comparison. I really didn't think it was going to be that liberating when I switched but holy crap it was awesome.
Sign In or Register to comment.