SimplyMaya Forums

Welcome to the forum, feel free to ask questions here.

Home / forum / Lounges / Maya Basics & Newbie Lounge / Add Xray to Shelf
Register FAQ Members List Calendar Mark Forums Read

New Thread
 
Thread Tools
Old 02-06-2006, 05:58 PM   #1
Eldwick
Subscriber
 
Eldwick's Avatar
 
Join Date: Mar 2006
Location: Washington, DC
Posts: 195
Thanks: 0
Thanked 0 Times in 0 Posts
Default Add Xray to Shelf

How would I add Xray to my shelf or preferably to a hotkey?
Eldwick is offline   Reply With Quote
Old 02-06-2006, 08:59 PM   #2
pbman
Subscriber
 
pbman's Avatar
 
Join Date: Mar 2005
Location: London
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Default

download the mel script on this site and follow the instructions that come with it

go to 'download' to find it
__________________
Now at SMU doing BSc 3D Computer Animation so its hard to get on here
My wire render tut http://forum.simplymaya.com/showthre...threadid=20973
pbman is offline   Reply With Quote
Old 02-06-2006, 09:13 PM   #3
13th_resident
Subscriber
 
13th_resident's Avatar
 
Join Date: Feb 2006
Location: London
Posts: 703
Thanks: 0
Thanked 0 Times in 0 Posts
Default

actually i'll tell you right NOW!

open up your script editor in maya.
go to Edit > Clear All. then paste the following to the bottom section of the script editor (Its called Input work area)


// Toggle Xray
//

string $visPanel[]=`getPanel -vis`;
int $mode;
if (size($visPanel)>0)
{
for ($panel in $visPanel)
{
if (`match "^modelPanel" $panel`=="modelPanel")
{
$mode=`modelEditor -q -xray $panel`;
if ($mode>0)
modelEditor -e -xray 0 $panel;
else
modelEditor -e -xray 1 $panel;
}
}
print ("\nxray="+$mode+".");
} else
print ("\nNo model panels to modify.");


after pasting it. highlight the whole code (ctrl + A) then go to File > Save Selected to Shelf, give a name to it. then it'll add the mel script onto the shelf that is active.
__________________
A pint of example is worth a gallon of advice!!
13th_resident is offline   Reply With Quote
Old 02-06-2006, 09:15 PM   #4
MattTheMan
Registered User
 
MattTheMan's Avatar
 
Join Date: Apr 2005
Location: Fairfield, CT
Posts: 2,436
Thanks: 0
Thanked 18 Times in 18 Posts
Default

cool! Thanks for posting that 13th! Did you write it?
__________________
Live the life you love, love the life you live
MattTheMan is offline   Reply With Quote
Old 02-06-2006, 09:31 PM   #5
13th_resident
Subscriber
 
13th_resident's Avatar
 
Join Date: Feb 2006
Location: London
Posts: 703
Thanks: 0
Thanked 0 Times in 0 Posts
Default

i must confess, i didnt write it. i wish i had though. i did a few of the mel tutorials that come in with maya help files.
but i dont actually know it enough to start writing my own scripts.
iam planning on doing a few tutorials on it sometime in the near future.
__________________
A pint of example is worth a gallon of advice!!
13th_resident is offline   Reply With Quote
Old 03-06-2006, 03:25 PM   #6
Eldwick
Subscriber
 
Eldwick's Avatar
 
Join Date: Mar 2006
Location: Washington, DC
Posts: 195
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks!
Eldwick is offline   Reply With Quote
Old 05-08-2006, 07:07 PM   #7
Grev_Mivlos
Registered User
 
Grev_Mivlos's Avatar
 
Join Date: Mar 2006
Location: Denmark
Posts: 154
Thanks: 0
Thanked 0 Times in 0 Posts
Default Nice

Great thx, but i noticed that, in the Haunted house tutorial that

Kurt ( :bow: ) had an icon instead of the default icon it creates.

How Do you change that Icon ??
__________________
(__/)
(='.'=) This is bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination
Grev_Mivlos is offline   Reply With Quote
Old 07-08-2006, 05:17 PM   #8
portermalone
Subscriber
 
Join Date: May 2005
Posts: 56
Thanks: 0
Thanked 0 Times in 0 Posts
Default

go to Window- Preferences- Shelf Editor--

Once there, select the self that you have put the x-ray icon on, scroll down to the correct button( you should see in the line of shelf scripts the x-ray script that you inserted, also if your having trouble finding it, they're listed in the same order that you see them on the shelf.) Once selected, hit the change icon button and direct it to the path of the file you want to be your icon.

you can also make your own custom icons in photoshop, but make sure to save them as the right type of file or maya will not recognize it. Check the other icons to see what type of file, it's also a good idea to open one of the existing icons, edit it, and then save it as something else.

good luck
portermalone is offline   Reply With Quote
New Thread

« Previous Thread | Next Thread »

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

1 Month

$34

Month-to-month billing
$34/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
 
 

3 months

$87

Billing every 3 months
$29/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
Save $5 per month or $15 in total compared to monthly billing with this package.

12 months

$288

Billing every 12 months
$24/month
Unlimited access to all videos
Project files to download
Easy to cancel at anytime
Save $10 per month or $120 in total compared to monthly billing with this package.

Your plan will automatically renew. You can cancel at any time via your PayPal account to avoid being charged again.

You can view the FAQ on our video plans here. You can contact us directly here. By clicking one of the buttons above, you agree to our Terms and Privacy Policy.